Lucene.Net  3.0.3
Lucene.Net is a .NET port of the Java Lucene Indexing Library
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Properties
Static Public Member Functions | Static Public Attributes | List of all members
Lucene.Net.Util.StringHelper Class Reference

Methods for manipulating strings. More...

Static Public Member Functions

static System.String Intern (System.String s)
 Return the same string object for all equal strings
 
static int BytesDifference (byte[] bytes1, int len1, byte[] bytes2, int len2)
 Compares two byte[] arrays, element by element, and returns the number of elements common to both arrays.
 
static int StringDifference (System.String s1, System.String s2)
 Compares two strings, character by character, and returns the first position where the two strings differ from one another.
 

Static Public Attributes

static StringInterner interner = new SimpleStringInterner(1024, 8)
 Expert: The StringInterner implementation used by Lucene. This shouldn't be changed to an incompatible implementation after other Lucene APIs have been used.
 

Detailed Description

Methods for manipulating strings.

Definition at line 25 of file StringHelper.cs.

Member Function Documentation

static int Lucene.Net.Util.StringHelper.BytesDifference ( byte[]  bytes1,
int  len1,
byte[]  bytes2,
int  len2 
)
static

Compares two byte[] arrays, element by element, and returns the number of elements common to both arrays.

Parameters
bytes1The first byte[] to compare
len1
bytes2The second byte[] to compare
len2
Returns
The number of common elements.

Definition at line 51 of file StringHelper.cs.

static System.String Lucene.Net.Util.StringHelper.Intern ( System.String  s)
static

Return the same string object for all equal strings

Definition at line 34 of file StringHelper.cs.

static int Lucene.Net.Util.StringHelper.StringDifference ( System.String  s1,
System.String  s2 
)
static

Compares two strings, character by character, and returns the first position where the two strings differ from one another.

Parameters
s1The first string to compare
s2The second string to compare
Returns
The first position where the two strings differ.

Definition at line 70 of file StringHelper.cs.

Member Data Documentation

StringInterner Lucene.Net.Util.StringHelper.interner = new SimpleStringInterner(1024, 8)
static

Expert: The StringInterner implementation used by Lucene. This shouldn't be changed to an incompatible implementation after other Lucene APIs have been used.

Definition at line 31 of file StringHelper.cs.


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