Neuron®
The Neuron® is the basis for the creation of open and secure federated networks for smart societies.
Loading...
Searching...
No Matches
XmlFileTokenizer.cs
1using System.Threading.Tasks;
2using System.Xml;
5
7{
12 {
17 {
18 }
19
25 public Grade Supports(string Extension)
26 {
27 if (Extension == "xml")
28 return Grade.Ok;
29 else
30 return Grade.NotAtAll;
31 }
32
38 public async Task Tokenize(FileReference Reference, TokenizationProcess Process)
39 {
40 string Text = await Runtime.IO.Files.ReadAllTextAsync(Reference.FileName);
41 XmlDocument Doc = new XmlDocument();
42 Doc.LoadXml(Text);
43
44 XmlTokenizer.Tokenize(Doc, Process);
45 }
46 }
47}
Contains a reference to an indexed file.
CaseInsensitiveString FileName
Name of collection hosting object.
async Task Tokenize(FileReference Reference, TokenizationProcess Process)
Tokenizes an object.
Grade Supports(string Extension)
How well the file tokenizer supports files of a given extension.
Contains information about a tokenization process.
Tokenizes an XML Document or XML Fragment.
Definition: XmlTokenizer.cs:15
Task Tokenize(object Value, TokenizationProcess Process)
Tokenizes an object.
Definition: XmlTokenizer.cs:43
Interface for file tokenizers. Best tokenizer is selected
Grade
Grade enumeration
Definition: Grade.cs:7