Apache Arrow (C++)
A columnar in-memory analytics layer designed to accelerate big data.
type_fwd.h
Go to the documentation of this file.
1 // Licensed to the Apache Software Foundation (ASF) under one
2 // or more contributor license agreements. See the NOTICE file
3 // distributed with this work for additional information
4 // regarding copyright ownership. The ASF licenses this file
5 // to you under the Apache License, Version 2.0 (the
6 // "License"); you may not use this file except in compliance
7 // with the License. You may obtain a copy of the License at
8 //
9 // http://www.apache.org/licenses/LICENSE-2.0
10 //
11 // Unless required by applicable law or agreed to in writing,
12 // software distributed under the License is distributed on an
13 // "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
14 // KIND, either express or implied. See the License for the
15 // specific language governing permissions and limitations
16 // under the License.
17 
18 #ifndef ARROW_TYPE_FWD_H
19 #define ARROW_TYPE_FWD_H
20 
21 #include <memory>
22 
23 #include "arrow/util/visibility.h"
24 
25 namespace arrow {
26 
27 class Status;
28 
29 class DataType;
30 class Array;
31 struct ArrayData;
32 class ArrayBuilder;
33 class Field;
34 class Tensor;
35 
36 class ChunkedArray;
37 class Column;
38 class RecordBatch;
39 class Table;
40 
41 class Buffer;
42 class MemoryPool;
43 class RecordBatch;
44 class Schema;
45 
46 class DictionaryType;
47 class DictionaryArray;
48 
49 class NullType;
50 class NullArray;
51 class NullBuilder;
52 
53 class BooleanType;
54 class BooleanArray;
55 class BooleanBuilder;
56 
57 class BinaryType;
58 class BinaryArray;
59 class BinaryBuilder;
60 
61 class FixedSizeBinaryType;
62 class FixedSizeBinaryArray;
63 class FixedSizeBinaryBuilder;
64 
65 class StringType;
66 class StringArray;
67 class StringBuilder;
68 
69 class ListType;
70 class ListArray;
71 class ListBuilder;
72 
73 class StructType;
74 class StructArray;
75 class StructBuilder;
76 
77 class Decimal128Type;
78 class Decimal128Array;
79 class Decimal128Builder;
80 
81 class UnionType;
82 class UnionArray;
83 
84 template <typename TypeClass>
85 class NumericArray;
86 
87 template <typename TypeClass>
88 class NumericBuilder;
89 
90 template <typename TypeClass>
92 
93 #define _NUMERIC_TYPE_DECL(KLASS) \
94  class KLASS##Type; \
95  using KLASS##Array = NumericArray<KLASS##Type>; \
96  using KLASS##Builder = NumericBuilder<KLASS##Type>; \
97  using KLASS##Tensor = NumericTensor<KLASS##Type>;
98 
99 _NUMERIC_TYPE_DECL(Int8);
100 _NUMERIC_TYPE_DECL(Int16);
101 _NUMERIC_TYPE_DECL(Int32);
102 _NUMERIC_TYPE_DECL(Int64);
103 _NUMERIC_TYPE_DECL(UInt8);
104 _NUMERIC_TYPE_DECL(UInt16);
105 _NUMERIC_TYPE_DECL(UInt32);
106 _NUMERIC_TYPE_DECL(UInt64);
107 _NUMERIC_TYPE_DECL(HalfFloat);
108 _NUMERIC_TYPE_DECL(Float);
109 _NUMERIC_TYPE_DECL(Double);
110 
111 #undef _NUMERIC_TYPE_DECL
112 
113 class Date64Type;
116 
117 class Date32Type;
120 
121 class Time32Type;
124 
125 class Time64Type;
128 
129 class TimestampType;
132 
133 class IntervalType;
135 
136 // ----------------------------------------------------------------------
137 // (parameter-free) Factory functions
138 // Other factory functions are in type.h
139 
141 std::shared_ptr<DataType> ARROW_EXPORT null();
143 std::shared_ptr<DataType> ARROW_EXPORT boolean();
145 std::shared_ptr<DataType> ARROW_EXPORT int8();
147 std::shared_ptr<DataType> ARROW_EXPORT int16();
149 std::shared_ptr<DataType> ARROW_EXPORT int32();
151 std::shared_ptr<DataType> ARROW_EXPORT int64();
153 std::shared_ptr<DataType> ARROW_EXPORT uint8();
155 std::shared_ptr<DataType> ARROW_EXPORT uint16();
157 std::shared_ptr<DataType> ARROW_EXPORT uint32();
159 std::shared_ptr<DataType> ARROW_EXPORT uint64();
161 std::shared_ptr<DataType> ARROW_EXPORT float16();
163 std::shared_ptr<DataType> ARROW_EXPORT float32();
165 std::shared_ptr<DataType> ARROW_EXPORT float64();
167 std::shared_ptr<DataType> ARROW_EXPORT utf8();
169 std::shared_ptr<DataType> ARROW_EXPORT binary();
171 std::shared_ptr<DataType> ARROW_EXPORT date32();
173 std::shared_ptr<DataType> ARROW_EXPORT date64();
174 
175 } // namespace arrow
176 
177 #endif // ARROW_TYPE_FWD_H
Definition: array.h:370
std::shared_ptr< DataType > date64()
Return a Date64Type instance.
std::shared_ptr< DataType > int16()
Return a Int16Type instance.
std::shared_ptr< DataType > uint8()
Return a UInt8Type instance.
std::shared_ptr< DataType > binary()
Return a BinaryType instance.
Definition: type_fwd.h:91
Concrete type class for 64-bit date data (as number of milliseconds since UNIX epoch) ...
Definition: type.h:610
std::shared_ptr< DataType > uint16()
Return a UInt16Type instance.
std::shared_ptr< DataType > int32()
Return a Int32Type instance.
std::shared_ptr< DataType > uint32()
Return a UInt32Type instance.
Base class for all Builders that emit an Array of a scalar numerical type.
Definition: builder.h:360
std::shared_ptr< DataType > uint64()
Return a UInt64Type instance.
std::shared_ptr< DataType > int8()
Return a Int8Type instance.
Definition: type.h:688
std::shared_ptr< DataType > float32()
Return a FloatType instance.
std::shared_ptr< DataType > null()
Return a NullType instance.
Definition: type.h:715
std::shared_ptr< DataType > date32()
Return a Date32Type instance.
std::shared_ptr< DataType > int64()
Return a Int64Type instance.
DataType< Type::BOOLEAN > BooleanType
Definition: types.h:276
Top-level namespace for Apache Arrow C++ API.
Definition: adapter.h:32
std::shared_ptr< DataType > boolean()
Return a BooleanType instance.
Concrete type class for 32-bit date data (as number of days since UNIX epoch)
Definition: type.h:593
std::shared_ptr< DataType > float64()
Return a DoubleType instance.
std::shared_ptr< DataType > utf8()
Return a StringType instance.
std::shared_ptr< DataType > float16()
Return a HalfFloatType instance.
Definition: type.h:673
Definition: type.h:658
::arrow::Buffer Buffer
Definition: memory.h:54