Okapi .NET Library

IFilter.OpenInputString Method 

 [This is preliminary documentation and subject to change.]

Set a given string as the input to process.

[Visual Basic]
Function OpenInputString( _ 
   ByVal p_sInput As String, _ 
   ByVal p_sLanguage As String, _ 
   ByVal p_sEncoding As String, _ 
   ByVal p_lOffsetInFile As Long _ 
) As Boolean
[C#]
bool OpenInputString(
   string p_sInput,
   string p_sLanguage,
   string p_sEncoding,
   long p_lOffsetInFile
);
[C++]
bool OpenInputString(
   String* p_sInput,
   String* p_sLanguage,
   String* p_sEncoding,
   __int64 p_lOffsetInFile
);
[JScript]
function OpenInputString(
   String p_sInput,
   String p_sLanguage,
   String p_sEncoding,
   long p_lOffsetInFile
): bool;

Parameters

p_sInput
String to process.
p_sLanguage
The code of the language to process. The code must be an RFC3066 tag.
p_sEncoding
The name of the encoding of the file. The name must be an IANA charset name. This parameter is used only if the filter cannot detect automatically the encoding of the file.
p_lOffsetInFile
Position in an input file where the string starts.

Return Value

True if the string to set sucessfully, false if an error occurs.

Remarks

Use this method to set the string to process. Call CloseOutput after the string has been processed. To process a file, use the OpenInputFile method.

The p_lOffsetInFile parameter is to be used if the string is coming from a file, to allow the filter to provide a more accurate location along with any error or warning. Set p_lOffsetInFile to 0 if the input string has no context.

See Also

IFilter Interface | Okapi.Library.Filter Namespace | CloseInput | OpenInputFile | ResetInput | ReadItem