Skip to content

Commit ba1df75

Browse files
committed
YdbType declaration fix
1 parent 33ef345 commit ba1df75

File tree

8 files changed

+42
-0
lines changed

8 files changed

+42
-0
lines changed

src/Types/AbstractType.php

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -78,6 +78,14 @@ public function toYdbValue()
7878
return new Value([$this->getYdbKeyName() => $this->getYdbValue()]);
7979
}
8080

81+
/**
82+
* @return string
83+
*/
84+
public function getType()
85+
{
86+
return $this->ydb_type;
87+
}
88+
8189
/**
8290
* @return int|mixed
8391
*/

src/Types/Int16Type.php

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,4 +8,9 @@ class Int16Type extends IntType
88
* @inherit
99
*/
1010
protected $bits = 16;
11+
12+
/**
13+
* @inherit
14+
*/
15+
protected $ydb_type = 'INT16';
1116
}

src/Types/Int64Type.php

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,4 +13,9 @@ class Int64Type extends IntType
1313
* @inherit
1414
*/
1515
protected $ydb_key_name = 'int64_value';
16+
17+
/**
18+
* @inherit
19+
*/
20+
protected $ydb_type = 'INT64';
1621
}

src/Types/Int8Type.php

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,4 +8,9 @@ class Int8Type extends IntType
88
* @inherit
99
*/
1010
protected $bits = 8;
11+
12+
/**
13+
* @inherit
14+
*/
15+
protected $ydb_type = 'INT8';
1116
}

src/Types/Uint16Type.php

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,4 +8,9 @@ class Uint16Type extends Int16Type
88
* @inherit
99
*/
1010
protected $unsigned = true;
11+
12+
/**
13+
* @inherit
14+
*/
15+
protected $ydb_type = 'UINT16';
1116
}

src/Types/Uint32Type.php

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,4 +4,8 @@
44

55
class Uint32Type extends UintType
66
{
7+
/**
8+
* @inherit
9+
*/
10+
protected $ydb_type = 'UINT32';
711
}

src/Types/Uint64Type.php

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,4 +8,9 @@ class Uint64Type extends Int64Type
88
* @inherit
99
*/
1010
protected $unsigned = true;
11+
12+
/**
13+
* @inherit
14+
*/
15+
protected $ydb_type = 'UINT64';
1116
}

src/Types/Uint8Type.php

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,4 +8,9 @@ class Uint8Type extends Int8Type
88
* @inherit
99
*/
1010
protected $unsigned = true;
11+
12+
/**
13+
* @inherit
14+
*/
15+
protected $ydb_type = 'UINT8';
1116
}

0 commit comments

Comments
 (0)