DeveelDB  20151217
complete SQL database system, primarly developed for .NET/Mono frameworks
Classes | Public Member Functions | Static Public Member Functions | Static Public Attributes | Properties | Private Member Functions | Private Attributes | List of all members
Deveel.Data.Sql.Objects.SqlLongString Class Reference
Inheritance diagram for Deveel.Data.Sql.Objects.SqlLongString:
Deveel.Data.Sql.Objects.ISqlString Deveel.Data.Sql.Objects.IObjectRef Deveel.Data.Sql.Objects.ISqlObject

Classes

class  Enumerator
 

Public Member Functions

 SqlLongString (ILargeObject largeObject, Encoding encoding)
 
void Dispose ()
 
IEnumerator< char > GetEnumerator ()
 
TextReader GetInput (Encoding encoding)
 

Static Public Member Functions

static SqlLongString Unicode (ILargeObject largeObject)
 
static SqlLongString Ascii (ILargeObject largeObject)
 

Static Public Attributes

static readonly SqlLongString Null = new SqlLongString(null, null, true)
 

Properties

Encoding Encoding [get, private set]
 
ObjectId ObjectId [get]
 
bool IsNull [get, private set]
 
char this[long offset] [get]
 
long Length [get, private set]
 
- Properties inherited from Deveel.Data.Sql.Objects.ISqlString
Encoding Encoding [get]
 
long Length [get]
 
char this[long offset] [get]
 
- Properties inherited from Deveel.Data.Sql.Objects.ISqlObject
bool IsNull [get]
 Gets a boolean value indicating if the object is NULL. More...
 
- Properties inherited from Deveel.Data.Sql.Objects.IObjectRef
ObjectId ObjectId [get]
 

Private Member Functions

 SqlLongString (ILargeObject largeObject, Encoding encoding, bool isNull)
 
 ~SqlLongString ()
 
void Dispose (bool disposing)
 
int IComparable. CompareTo (object obj)
 
int IComparable< ISqlObject >. CompareTo (ISqlObject other)
 
bool ISqlObject. IsComparableTo (ISqlObject other)
 Checks if the current object is comparable with the given one. More...
 
int IComparable< ISqlString >. CompareTo (ISqlString other)
 
IEnumerator IEnumerable. GetEnumerator ()
 

Private Attributes

ILargeObject largeObject
 

Detailed Description

Definition at line 26 of file SqlLongString.cs.

Constructor & Destructor Documentation

Deveel.Data.Sql.Objects.SqlLongString.SqlLongString ( ILargeObject  largeObject,
Encoding  encoding,
bool  isNull 
)
inlineprivate

Definition at line 31 of file SqlLongString.cs.

31  {
32  if (!isNull && largeObject == null)
33  throw new ArgumentNullException("largeObject");
34 
35  this.largeObject = largeObject;
36  Encoding = encoding;
37  IsNull = isNull;
38 
39  if (!isNull) {
40  Length = largeObject.RawSize;
41  }
42  }
long RawSize
Gets the raw byte size of the object.
Definition: ILargeObject.cs:56
Deveel.Data.Sql.Objects.SqlLongString.SqlLongString ( ILargeObject  largeObject,
Encoding  encoding 
)
inline

Definition at line 44 of file SqlLongString.cs.

45  : this(largeObject, encoding, false) {
46  }
Deveel.Data.Sql.Objects.SqlLongString.~SqlLongString ( )
inlineprivate

Definition at line 48 of file SqlLongString.cs.

48  {
49  Dispose(false);
50  }

Member Function Documentation

static SqlLongString Deveel.Data.Sql.Objects.SqlLongString.Ascii ( ILargeObject  largeObject)
inlinestatic

Definition at line 124 of file SqlLongString.cs.

124  {
125  return new SqlLongString(largeObject, Encoding.ASCII);
126  }
SqlLongString(ILargeObject largeObject, Encoding encoding, bool isNull)
int IComparable. Deveel.Data.Sql.Objects.SqlLongString.CompareTo ( object  obj)
inlineprivate

Definition at line 69 of file SqlLongString.cs.

69  {
70  throw new NotSupportedException();
71  }
int IComparable<ISqlObject>. Deveel.Data.Sql.Objects.SqlLongString.CompareTo ( ISqlObject  other)
inlineprivate

Definition at line 73 of file SqlLongString.cs.

73  {
74  throw new NotSupportedException();
75  }
int IComparable<ISqlString>. Deveel.Data.Sql.Objects.SqlLongString.CompareTo ( ISqlString  other)
inlineprivate

Definition at line 98 of file SqlLongString.cs.

98  {
99  throw new NotSupportedException();
100  }
void Deveel.Data.Sql.Objects.SqlLongString.Dispose ( )
inline

Definition at line 54 of file SqlLongString.cs.

54  {
55  Dispose(true);
56  GC.SuppressFinalize(this);
57  }
void Deveel.Data.Sql.Objects.SqlLongString.Dispose ( bool  disposing)
inlineprivate

Definition at line 59 of file SqlLongString.cs.

59  {
60  if (disposing) {
61  if (largeObject != null)
62  largeObject.Dispose();
63  }
64 
65  Encoding = null;
66  largeObject = null;
67  }
IEnumerator<char> Deveel.Data.Sql.Objects.SqlLongString.GetEnumerator ( )
inline

Definition at line 102 of file SqlLongString.cs.

102  {
103  return new Enumerator(this);
104  }
IEnumerator IEnumerable. Deveel.Data.Sql.Objects.SqlLongString.GetEnumerator ( )
inlineprivate

Definition at line 106 of file SqlLongString.cs.

106  {
107  return GetEnumerator();
108  }
TextReader Deveel.Data.Sql.Objects.SqlLongString.GetInput ( Encoding  encoding)
inline

Implements Deveel.Data.Sql.Objects.ISqlString.

Definition at line 112 of file SqlLongString.cs.

112  {
113  if (largeObject == null)
114  return TextReader.Null;
115 
116  return new StreamReader(new ObjectStream(largeObject), encoding);
117  }
bool ISqlObject. Deveel.Data.Sql.Objects.SqlLongString.IsComparableTo ( ISqlObject  other)
inlineprivate

Checks if the current object is comparable with the given one.

Parameters
otherThe other ISqlObject to compare.
Returns
Returns true if the current object is comparable with the given one, false otherwise.

Implements Deveel.Data.Sql.Objects.ISqlObject.

Definition at line 83 of file SqlLongString.cs.

83  {
84  return false;
85  }
static SqlLongString Deveel.Data.Sql.Objects.SqlLongString.Unicode ( ILargeObject  largeObject)
inlinestatic

Definition at line 119 of file SqlLongString.cs.

119  {
120  return new SqlLongString(largeObject, Encoding.Unicode);
121  }
SqlLongString(ILargeObject largeObject, Encoding encoding, bool isNull)

Member Data Documentation

ILargeObject Deveel.Data.Sql.Objects.SqlLongString.largeObject
private

Definition at line 27 of file SqlLongString.cs.

readonly SqlLongString Deveel.Data.Sql.Objects.SqlLongString.Null = new SqlLongString(null, null, true)
static

Definition at line 29 of file SqlLongString.cs.

Property Documentation

Encoding Deveel.Data.Sql.Objects.SqlLongString.Encoding
getprivate set

Definition at line 52 of file SqlLongString.cs.

bool Deveel.Data.Sql.Objects.SqlLongString.IsNull
getprivate set

Definition at line 81 of file SqlLongString.cs.

long Deveel.Data.Sql.Objects.SqlLongString.Length
getprivate set

Definition at line 110 of file SqlLongString.cs.

ObjectId Deveel.Data.Sql.Objects.SqlLongString.ObjectId
get

Definition at line 77 of file SqlLongString.cs.

char Deveel.Data.Sql.Objects.SqlLongString.this[long offset]
get

Definition at line 87 of file SqlLongString.cs.


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