DeveelDB  20151217
complete SQL database system, primarly developed for .NET/Mono frameworks
Public Member Functions | Static Public Member Functions | Properties | List of all members
Deveel.Data.Spatial.SpatialType Class Reference
Inheritance diagram for Deveel.Data.Spatial.SpatialType:
Deveel.Data.Types.SqlType Deveel.Data.Serialization.ISerializable

Public Member Functions

 SpatialType ()
 
 SpatialType (int srid)
 
override bool IsComparable (SqlType type)
 Verifies if a given SqlType is comparable to this data-type. More...
 
bool IsComparable (SpatialType other)
 
- Public Member Functions inherited from Deveel.Data.Types.SqlType
virtual bool CanCastTo (SqlType destType)
 Verifies if this type can cast any value to the given SqlType. More...
 
virtual DataObject CastTo (DataObject value, SqlType destType)
 Converts the given object value to a SqlType specified. More...
 
virtual object ConvertTo (ISqlObject obj, Type destType)
 
virtual ISqlObject Add (ISqlObject a, ISqlObject b)
 
virtual ISqlObject Subtract (ISqlObject a, ISqlObject b)
 
virtual ISqlObject Multiply (ISqlObject a, ISqlObject b)
 
virtual ISqlObject Divide (ISqlObject a, ISqlObject b)
 
virtual ISqlObject Modulus (ISqlObject a, ISqlObject b)
 
virtual ISqlObject Negate (ISqlObject value)
 
virtual SqlBoolean IsEqualTo (ISqlObject a, ISqlObject b)
 
virtual SqlBoolean IsNotEqualTo (ISqlObject a, ISqlObject b)
 
virtual SqlBoolean IsGreatherThan (ISqlObject a, ISqlObject b)
 
virtual SqlBoolean IsSmallerThan (ISqlObject a, ISqlObject b)
 
virtual SqlBoolean IsGreaterOrEqualThan (ISqlObject a, ISqlObject b)
 
virtual SqlBoolean IsSmallerOrEqualThan (ISqlObject a, ISqlObject b)
 
virtual ISqlObject And (ISqlObject a, ISqlObject b)
 
virtual ISqlObject Or (ISqlObject a, ISqlObject b)
 
virtual ISqlObject XOr (ISqlObject x, ISqlObject y)
 
virtual ISqlObject UnaryPlus (ISqlObject value)
 
virtual ISqlObject Reverse (ISqlObject value)
 
virtual SqlType Wider (SqlType otherType)
 Gets the one data-type between this and the other one given that handles the wider range of values. More...
 
virtual int Compare (ISqlObject x, ISqlObject y)
 
override bool Equals (object obj)
 
override int GetHashCode ()
 
virtual bool Equals (SqlType other)
 
override string ToString ()
 
virtual void SerializeObject (Stream stream, ISqlObject obj)
 
virtual ISqlObject DeserializeObject (Stream stream)
 
virtual bool IsCacheable (ISqlObject value)
 
virtual Type GetRuntimeType ()
 
virtual Type GetObjectType ()
 
virtual ISqlObject CreateFromLargeObject (ILargeObject objRef)
 
virtual ISqlObject CreateFrom (object value)
 

Static Public Member Functions

static SpatialType Geometry (int srid)
 
static SpatialType Geometry ()
 
- Static Public Member Functions inherited from Deveel.Data.Types.SqlType
static SqlType Parse (string s)
 Parses a SQL formatted string that defines a data-type into a constructed SqlType object equivalent. More...
 
static SqlType Parse (IContext context, string s)
 Parses a SQL formatted string that defines a data-type into a constructed SqlType object equivalent. More...
 
static bool IsPrimitiveType (SqlTypeCode typeCode)
 
static SqlType Resolve (SqlTypeCode typeCode)
 
static SqlType Resolve (SqlTypeCode typeCode, DataTypeMeta[] meta)
 
static SqlType Resolve (SqlTypeCode typeCode, DataTypeMeta[] meta, ITypeResolver resolver)
 
static SqlType Resolve (SqlTypeCode typeCode, string name)
 
static SqlType Resolve (SqlTypeCode typeCode, string name, DataTypeMeta[] meta)
 
static SqlType Resolve (string name)
 
static SqlType Resolve (string name, DataTypeMeta[] meta)
 
static SqlType Resolve (string name, DataTypeMeta[] meta, ITypeResolver resolver)
 
static SqlType Resolve (SqlTypeCode typeCode, string name, DataTypeMeta[] meta, ITypeResolver resolver)
 

Properties

int Srid [get, private set]
 
- Properties inherited from Deveel.Data.Types.SqlType
string Name [get, private set]
 Gets the name of the data-type that is used to resolve it within the context. More...
 
SqlTypeCode TypeCode [get, private set]
 Gets the kind of SQL type this data-type handles. More...
 
virtual bool IsIndexable [get]
 Indicates if the values handled by the type can be part of an index. More...
 
bool IsPrimitive [get]
 Gets a value indicating if this data-type is primitive. More...
 
bool IsNull [get]
 
virtual bool IsStorable [get]
 

Additional Inherited Members

- Protected Member Functions inherited from Deveel.Data.Types.SqlType
 SqlType (SqlTypeCode sqlType)
 Constructs the SqlType for the given specific SQL TYPE. More...
 
 SqlType (string name, SqlTypeCode typeCode)
 Constructs the SqlType for the given specific SQL TYPE and a given name. More...
 
 SqlType (ObjectData data)
 
virtual void GetData (SerializeData data)
 
- Package Functions inherited from Deveel.Data.Types.SqlType
virtual int GetCacheUsage (ISqlObject value)
 
virtual int ColumnSizeOf (ISqlObject obj)
 

Detailed Description

Definition at line 6 of file SpatialType.cs.

Constructor & Destructor Documentation

Deveel.Data.Spatial.SpatialType.SpatialType ( )
inline

Definition at line 7 of file SpatialType.cs.

8  : this(-1) {
9  }
Deveel.Data.Spatial.SpatialType.SpatialType ( int  srid)
inline

Definition at line 11 of file SpatialType.cs.

12  : base("GEOMETRY", SqlTypeCode.Type) {
13  Srid = srid;
14  }
SqlTypeCode
Enumerates the codes of all SQL types handled by the system.
Definition: SqlTypeCode.cs:23

Member Function Documentation

static SpatialType Deveel.Data.Spatial.SpatialType.Geometry ( int  srid)
inlinestatic

Definition at line 31 of file SpatialType.cs.

31  {
32  return new SpatialType(srid);
33  }
static SpatialType Deveel.Data.Spatial.SpatialType.Geometry ( )
inlinestatic

Definition at line 35 of file SpatialType.cs.

35  {
36  return Geometry(-1);
37  }
static SpatialType Geometry()
Definition: SpatialType.cs:35
override bool Deveel.Data.Spatial.SpatialType.IsComparable ( SqlType  type)
inlinevirtual

Verifies if a given SqlType is comparable to this data-type.

Parameters
typeThe other data-type to verify the compatibility.

It is not required two SqlType to be identical to be compared: when overridden by a derived class, this methods verifies the properties of the argument type, to see if values handled by the types can be compared.

By default, this method compares the values returned by TypeCode to see if they are identical.

Returns
Returns true if the values handled by this data-type can be compared to ones handled by the given type , or false otherwise.

Reimplemented from Deveel.Data.Types.SqlType.

Definition at line 18 of file SpatialType.cs.

18  {
19  var otherType = type as SpatialType;
20  if (otherType == null)
21  return false;
22 
23  return IsComparable(otherType);
24  }
override bool IsComparable(SqlType type)
Verifies if a given SqlType is comparable to this data-type.
Definition: SpatialType.cs:18
bool Deveel.Data.Spatial.SpatialType.IsComparable ( SpatialType  other)
inline

Definition at line 26 of file SpatialType.cs.

26  {
27  // TODO: Is this a good assumption?
28  return Srid.Equals(other.Srid);
29  }

Property Documentation

int Deveel.Data.Spatial.SpatialType.Srid
getprivate set

Definition at line 16 of file SpatialType.cs.


The documentation for this class was generated from the following file: