C# Класс Beagrep.Daemon.Filter

Показать файл Открыть проект Примеры использования класса

Открытые методы

Метод Описание
AddLink ( string link ) : void
AddProperty ( System.Property prop ) : void
AppendChars ( char buffer, int index, int count ) : bool

Does not check for structural breaks

AppendLine ( string line ) : bool

Add a line followed by a newline.

AppendStructuralBreak ( ) : bool

Creates a new paragraph. Mainly useful for storing cached contents.

AppendText ( string str ) : bool

Append text to the textpool. If IsHot is true, then also add to the hottext pool. Handles null str.

AppendText ( string str, string strHot ) : bool
AppendWhiteSpace ( ) : bool

Adds whitespace to the textpool.

AppendWord ( string word ) : bool

Add a word followed by a whitespace. word may not be whitespace or newline.

AttachSnippetWriter ( TextWriter writer ) : void
CleanGeneratedIndexables ( ) : void
Cleanup ( ) : void
Filter ( ) : System
FreezeDown ( ) : void
FreezeUp ( ) : void
GenerateNextIndexable ( Indexable &indexable ) : bool

Good filters should replace this by an IEnumerable that does not require generating all the indexables beforehand

GetHotTextReader ( ) : TextReader
GetTextReader ( ) : TextReader
HotDown ( ) : void
HotUp ( ) : void
Open ( FileSystemInfo info ) : bool
Open ( Stream stream ) : bool
Open ( Stream stream, bool store_tempfile ) : bool

This will throw an exception; callers should catch it and appropriately display the error message showing the filename etc.

Open ( TextReader reader ) : bool
Open ( string path ) : bool

Защищенные методы

Метод Описание
AddIndexable ( Indexable indexable ) : void
AddIndexables ( ICollection indexables ) : void
AddSupportedFlavor ( Beagrep.Daemon.FilterFlavor flavor ) : void
DoClose ( ) : void
DoOpen ( DirectoryInfo info ) : void
DoOpen ( FileInfo info ) : void
DoOpen ( FileSystemInfo info ) : void
DoPull ( ) : void
DoPullProperties ( ) : void
DoPullSetup ( ) : void
Error ( ) : void
Finished ( ) : void
RegisterSupportedTypes ( ) : void
SetFileType ( string file_type ) : void

Filter may set the filetype to document, source, music etc. Use lower case for file_type

SetVersion ( int v ) : void

Приватные методы

Метод Описание
AppendWords ( string words, bool is_line ) : bool
Close ( ) : void
Pull ( ) : bool
PullFromArray ( ArrayList array, StringBuilder sb, bool is_hot ) : bool
PullHotText ( StringBuilder sb, int chars_to_pull ) : bool
PullText ( StringBuilder sb, int chars_to_pull ) : bool
PullTextCarefully ( ArrayList array, StringBuilder sb, int chars_to_pull, bool is_hot ) : bool
ReallyAddText ( char buffer, int index, int count ) : void
ReallyAddText ( string str ) : void
UpdateCharsAdded ( int append_chars_added ) : bool

Описание методов

AddIndexable() защищенный Метод

protected AddIndexable ( Indexable indexable ) : void
indexable Indexable
Результат void

AddIndexables() защищенный Метод

protected AddIndexables ( ICollection indexables ) : void
indexables ICollection
Результат void

AddLink() публичный Метод

public AddLink ( string link ) : void
link string
Результат void

AddProperty() публичный Метод

public AddProperty ( System.Property prop ) : void
prop System.Property
Результат void

AddSupportedFlavor() защищенный Метод

protected AddSupportedFlavor ( Beagrep.Daemon.FilterFlavor flavor ) : void
flavor Beagrep.Daemon.FilterFlavor
Результат void

AppendChars() публичный Метод

Does not check for structural breaks
public AppendChars ( char buffer, int index, int count ) : bool
buffer char /// A ///
index int /// A ///
count int /// A ///
Результат bool

AppendLine() публичный Метод

Add a line followed by a newline.
public AppendLine ( string line ) : bool
line string /// A ///
Результат bool

AppendStructuralBreak() публичный Метод

Creates a new paragraph. Mainly useful for storing cached contents.
public AppendStructuralBreak ( ) : bool
Результат bool

AppendText() публичный Метод

Append text to the textpool. If IsHot is true, then also add to the hottext pool. Handles null str.
public AppendText ( string str ) : bool
str string
Результат bool

AppendText() публичный Метод

public AppendText ( string str, string strHot ) : bool
str string
strHot string
Результат bool

AppendWhiteSpace() публичный Метод

Adds whitespace to the textpool.
public AppendWhiteSpace ( ) : bool
Результат bool

AppendWord() публичный Метод

Add a word followed by a whitespace. word may not be whitespace or newline.
public AppendWord ( string word ) : bool
word string /// A ///
Результат bool

AttachSnippetWriter() публичный Метод

public AttachSnippetWriter ( TextWriter writer ) : void
writer System.IO.TextWriter
Результат void

CleanGeneratedIndexables() публичный Метод

public CleanGeneratedIndexables ( ) : void
Результат void

Cleanup() публичный Метод

public Cleanup ( ) : void
Результат void

DoClose() защищенный Метод

protected DoClose ( ) : void
Результат void

DoOpen() защищенный Метод

protected DoOpen ( DirectoryInfo info ) : void
info System.IO.DirectoryInfo
Результат void

DoOpen() защищенный Метод

protected DoOpen ( FileInfo info ) : void
info System.IO.FileInfo
Результат void

DoOpen() защищенный Метод

protected DoOpen ( FileSystemInfo info ) : void
info System.IO.FileSystemInfo
Результат void

DoPull() защищенный Метод

protected DoPull ( ) : void
Результат void

DoPullProperties() защищенный Метод

protected DoPullProperties ( ) : void
Результат void

DoPullSetup() защищенный Метод

protected DoPullSetup ( ) : void
Результат void

Error() защищенный Метод

protected Error ( ) : void
Результат void

Filter() публичный Метод

public Filter ( ) : System
Результат System

Finished() защищенный Метод

protected Finished ( ) : void
Результат void

FreezeDown() публичный Метод

public FreezeDown ( ) : void
Результат void

FreezeUp() публичный Метод

public FreezeUp ( ) : void
Результат void

GenerateNextIndexable() публичный Метод

Good filters should replace this by an IEnumerable that does not require generating all the indexables beforehand
public GenerateNextIndexable ( Indexable &indexable ) : bool
indexable Indexable /// A ///
Результат bool

GetHotTextReader() публичный Метод

public GetHotTextReader ( ) : TextReader
Результат TextReader

GetTextReader() публичный Метод

public GetTextReader ( ) : TextReader
Результат TextReader

HotDown() публичный Метод

public HotDown ( ) : void
Результат void

HotUp() публичный Метод

public HotUp ( ) : void
Результат void

Open() публичный Метод

public Open ( FileSystemInfo info ) : bool
info System.IO.FileSystemInfo
Результат bool

Open() публичный Метод

public Open ( Stream stream ) : bool
stream Stream
Результат bool

Open() публичный Метод

This will throw an exception; callers should catch it and appropriately display the error message showing the filename etc.
public Open ( Stream stream, bool store_tempfile ) : bool
stream Stream /// A ///
store_tempfile bool /// A ///
Результат bool

Open() публичный Метод

public Open ( TextReader reader ) : bool
reader TextReader
Результат bool

Open() публичный Метод

public Open ( string path ) : bool
path string
Результат bool

RegisterSupportedTypes() защищенный Метод

protected RegisterSupportedTypes ( ) : void
Результат void

SetFileType() защищенный Метод

Filter may set the filetype to document, source, music etc. Use lower case for file_type
protected SetFileType ( string file_type ) : void
file_type string /// A ///
Результат void

SetVersion() защищенный Метод

protected SetVersion ( int v ) : void
v int
Результат void