Namespaces

Types

Type SqlString

Namespace NHibernate.SqlCommand

Methods

Properties

Fields

Public instance methods

SqlString Append(string rhs)

Appends the string parameter to the end of the current SqlString to create a new SqlString object.
A SqlString object is immutable so this returns a new SqlString. If multiple Appends are called it is better to use the SqlStringBuilder.
Parameters
return SqlString A new SqlString object.
string rhs The string to append.

SqlString Append(SqlString rhs)

Appends the SqlString parameter to the end of the current SqlString to create a new SqlString object.
A SqlString object is immutable so this returns a new SqlString. If multiple Appends are called it is better to use the SqlStringBuilder.
Parameters
return SqlString A new SqlString object.
SqlString rhs The SqlString to append.

bool EndsWith(string value)

Determines whether the end of this instance matches the specified String.
Parameters
return bool ${WriteSummary(content)}
string value A string to seek at the end.

bool Equals(object obj)

Parameters
return bool
object obj

int GetHashCode()

Parameters
return int

int GetParameterCount()

Parameters
return int

SqlString GetSubselectString()

Parameters
return SqlString

Type GetType()

Parameters
return Type

int IndexOfCaseInsensitive(string text)

Returns the index of the first occurence of , case-insensitive.
The text must be located entirely in a string part of the SqlString . Searching for "a ? b" in an SqlString consisting of "a ", Parameter, " b" will result in no matches.
Parameters
return int The index of the first occurence of , or -1 if not found.
string text Text to look for in the SqlString . Must be in lower case.

SqlString Insert(int index, string text)

Parameters
return SqlString
int index
string text

int LastIndexOfCaseInsensitive(string text)

Parameters
return int
string text

SqlString Replace(string oldValue, string newValue)

Replaces all occurrences of a specified String in this instance, with another specified String .
Parameters
return SqlString A new SqlString with oldValue replaced by the newValue. The new SqlString is in the compacted form.
string oldValue A String to be replaced.
string newValue A String to replace all occurrences of oldValue.

bool StartsWithCaseInsensitive(string value)

Determines whether the beginning of this SqlString matches the specified System.String, using case-insensitive comparison.
Parameters
return bool true if the SqlString starts with the value.
string value The System.String to seek

SqlString Substring(int startIndex)

Retrieves a substring from this instance. The substring starts at a specified character position.
If the startIndex is greater than the length of the SqlString then Empty is returned.
Parameters
return SqlString A new SqlString to the substring that begins at startIndex in this instance.
int startIndex The starting character position of a substring in this instance.

SqlString Substring(int startIndex, int length)

Parameters
return SqlString
int startIndex
int length

SqlString SubstringStartingWithLast(string text)

Returns substring of this SqlString starting with the specified . If the text is not found, returns an empty, not-null SqlString.
The method performs case-insensitive comparison, so the passed should be in lower case.
Parameters
return SqlString
string text

string ToString()

Returns the SqlString in a string where it looks like SELECT col1, col2 FROM table WHERE col1 = ?
The question mark is used as the indicator of a parameter because at this point we are not using the specific provider so we don't know how that provider wants our parameters formatted.
Parameters
return string A provider-neutral version of the CommandText

SqlString Trim()

Removes all occurrences of white space characters from the beginning and end of this instance.
Parameters
return SqlString A new SqlString equivalent to this instance after white space characters are removed from the beginning and end.

void Visit(ISqlStringVisitor visitor)

Parameters
ISqlStringVisitor visitor

Public static methods

SqlString Parse(string sql)

Parse SQL in and create a SqlString representing it.
Parameter marks in single quotes will be correctly skipped, but otherwise the lexer is very simple and will not parse double quotes or escape sequences correctly, for example.
Parameters
return SqlString
string sql

Public properties

int Count get;

Gets the number of SqlParts contained in this SqlString.
return int

int Length get;

return int

ICollection Parts get;

return ICollection

Public fields

SqlString Empty

return SqlString

SqlString Parameter

return SqlString