Java Doc for JFlexParser.java in  » Wiki-Engine » JAMWiki » org » jamwiki » parser » jflex » Java Source Code / Java DocumentationJava Source Code and Java Documentation

Java Source Code / Java Documentation
1. 6.0 JDK Core
2. 6.0 JDK Modules
3. 6.0 JDK Modules com.sun
4. 6.0 JDK Modules com.sun.java
5. 6.0 JDK Modules sun
6. 6.0 JDK Platform
7. Ajax
8. Apache Harmony Java SE
9. Aspect oriented
10. Authentication Authorization
11. Blogger System
12. Build
13. Byte Code
14. Cache
15. Chart
16. Chat
17. Code Analyzer
18. Collaboration
19. Content Management System
20. Database Client
21. Database DBMS
22. Database JDBC Connection Pool
23. Database ORM
24. Development
25. EJB Server geronimo
26. EJB Server GlassFish
27. EJB Server JBoss 4.2.1
28. EJB Server resin 3.1.5
29. ERP CRM Financial
30. ESB
31. Forum
32. GIS
33. Graphic Library
34. Groupware
35. HTML Parser
36. IDE
37. IDE Eclipse
38. IDE Netbeans
39. Installer
40. Internationalization Localization
41. Inversion of Control
42. Issue Tracking
43. J2EE
44. JBoss
45. JMS
46. JMX
47. Library
48. Mail Clients
49. Net
50. Parser
51. PDF
52. Portal
53. Profiler
54. Project Management
55. Report
56. RSS RDF
57. Rule Engine
58. Science
59. Scripting
60. Search Engine
61. Security
62. Sevlet Container
63. Source Control
64. Swing Library
65. Template Engine
66. Test Coverage
67. Testing
68. UML
69. Web Crawler
70. Web Framework
71. Web Mail
72. Web Server
73. Web Services
74. Web Services apache cxf 2.0.1
75. Web Services AXIS2
76. Wiki Engine
77. Workflow Engines
78. XML
79. XML UI
Java
Java Tutorial
Java Open Source
Jar File Download
Java Articles
Java Products
Java by API
Photoshop Tutorials
Maya Tutorials
Flash Tutorials
3ds-Max Tutorials
Illustrator Tutorials
GIMP Tutorials
C# / C Sharp
C# / CSharp Tutorial
C# / CSharp Open Source
ASP.Net
ASP.NET Tutorial
JavaScript DHTML
JavaScript Tutorial
JavaScript Reference
HTML / CSS
HTML CSS Reference
C / ANSI-C
C Tutorial
C++
C++ Tutorial
Ruby
PHP
Python
Python Tutorial
Python Open Source
SQL Server / T-SQL
SQL Server / T-SQL Tutorial
Oracle PL / SQL
Oracle PL/SQL Tutorial
PostgreSQL
SQL / MySQL
MySQL Tutorial
VB.Net
VB.Net Tutorial
Flash / Flex / ActionScript
VBA / Excel / Access / Word
XML
XML Tutorial
Microsoft Office PowerPoint 2007 Tutorial
Microsoft Office Excel 2007 Tutorial
Microsoft Office Word 2007 Tutorial
Java Source Code / Java Documentation » Wiki Engine » JAMWiki » org.jamwiki.parser.jflex 
Source Cross Reference  Class Diagram Java Document (Java Doc) 


java.lang.Object
   org.jamwiki.parser.AbstractParser
      org.jamwiki.parser.jflex.JFlexParser

All known Subclasses:   org.jamwiki.parser.bliki.BlikiParser,
JFlexParser
public class JFlexParser extends AbstractParser (Code)
Implementation of org.jamwiki.parser.AbstractParser that uses JFlex as a lexer to convert Wiki syntax into HTML or other formats.


Field Summary
final protected static  intMODE_LAYOUT
     Layout mode indicates that the pre-processor, processor and post-processor should be run in full, parsing all Wiki syntax into formatted output and adding layout tags such as paragraphs.
final protected static  intMODE_MINIMAL
     Minimal mode is used to do a bare minimum of parsing, usually just converting signature tags, prior to saving to the database.
final protected static  intMODE_PREPROCESS
     Pre-process mode is currently equivalent to metadata mode and indicates that that the JFlex pre-processor parser should be run in full.
final protected static  intMODE_PROCESS
     Processing mode indicates that the pre-processor and processor should be run in full, parsing all Wiki syntax into formatted output.
final protected static  intMODE_SLICE
     Slice mode is used when retrieving a section of a topic for editing.
final protected static  intMODE_SPLICE
     Splice mode is used when inserting an edited topic section back into the full topic content.

Constructor Summary
public  JFlexParser(ParserInput parserInput)
     The constructor creates a parser instance, initialized with the specified parser input settings.

Method Summary
public  StringbuildRedirectContent(String topicName)
     Return a parser-specific value that can be used as the content of a topic representing a redirect.
public  StringparseFragment(ParserOutput parserOutput, String raw, int mode)
     This method parses content, performing all transformations except for layout changes such as adding paragraph tags.
public  StringparseHTML(ParserOutput parserOutput, String raw)
     Returns a HTML representation of the given wiki raw text for online representation.
Parameters:
  parserOutput - A ParserOutput object containing parsermetadata output.
Parameters:
  raw - The raw Wiki syntax to be converted into HTML.
public  voidparseMetadata(ParserOutput parserOutput, String raw)
     This method provides a way to parse content and set all output metadata, such as link values used by the search engine.
public  StringparseMinimal(String raw)
     Perform a bare minimum of parsing as required prior to saving a topic to the database.
public  StringparseSlice(ParserOutput parserOutput, String raw, int targetSection)
     This method provides the capability for retrieving a section of Wiki markup from an existing document.
public  StringparseSplice(ParserOutput parserOutput, String raw, int targetSection, String replacementText)
     This method provides the capability for splicing a section of new content back into a document.

Field Detail
MODE_LAYOUT
final protected static int MODE_LAYOUT(Code)
Layout mode indicates that the pre-processor, processor and post-processor should be run in full, parsing all Wiki syntax into formatted output and adding layout tags such as paragraphs.



MODE_MINIMAL
final protected static int MODE_MINIMAL(Code)
Minimal mode is used to do a bare minimum of parsing, usually just converting signature tags, prior to saving to the database.



MODE_PREPROCESS
final protected static int MODE_PREPROCESS(Code)
Pre-process mode is currently equivalent to metadata mode and indicates that that the JFlex pre-processor parser should be run in full.



MODE_PROCESS
final protected static int MODE_PROCESS(Code)
Processing mode indicates that the pre-processor and processor should be run in full, parsing all Wiki syntax into formatted output.



MODE_SLICE
final protected static int MODE_SLICE(Code)
Slice mode is used when retrieving a section of a topic for editing.



MODE_SPLICE
final protected static int MODE_SPLICE(Code)
Splice mode is used when inserting an edited topic section back into the full topic content.




Constructor Detail
JFlexParser
public JFlexParser(ParserInput parserInput)(Code)
The constructor creates a parser instance, initialized with the specified parser input settings.
Parameters:
  parserInput - Input configuration settings for this parserinstance.




Method Detail
buildRedirectContent
public String buildRedirectContent(String topicName)(Code)
Return a parser-specific value that can be used as the content of a topic representing a redirect. For the Mediawiki syntax parser the value returned would be of the form "#REDIRECT [[Topic]]".
Parameters:
  topicName - The name of the topic to redirect to. A parser-specific value that can be used as the content of atopic representing a redirect.



parseFragment
public String parseFragment(ParserOutput parserOutput, String raw, int mode) throws Exception(Code)
This method parses content, performing all transformations except for layout changes such as adding paragraph tags. It is suitable to be used when parsing the contents of a link or performing similar internal manipulation.
Parameters:
  parserOutput - A ParserOutput object containing parsermetadata output.
Parameters:
  raw - The raw Wiki syntax to be converted into HTML.
Parameters:
  mode - The parser mode to use when parsing. Mode affects whattype of parsing actions are taken when processing raw text. The parsed content.
throws:
  Exception - Thrown if any error occurs during parsing.



parseHTML
public String parseHTML(ParserOutput parserOutput, String raw) throws Exception(Code)
Returns a HTML representation of the given wiki raw text for online representation.
Parameters:
  parserOutput - A ParserOutput object containing parsermetadata output.
Parameters:
  raw - The raw Wiki syntax to be converted into HTML. The parsed content.
throws:
  Exception - Thrown if any error occurs during parsing.



parseMetadata
public void parseMetadata(ParserOutput parserOutput, String raw) throws Exception(Code)
This method provides a way to parse content and set all output metadata, such as link values used by the search engine. A ParserOutput object containing results of the parsing process.
Parameters:
  raw - The raw Wiki syntax to be converted into HTML.



parseMinimal
public String parseMinimal(String raw) throws Exception(Code)
Perform a bare minimum of parsing as required prior to saving a topic to the database. In general this method will simply parse signature tags are return.
Parameters:
  raw - The raw Wiki syntax to be converted into HTML. The parsed content.
throws:
  Exception - Thrown if any error occurs during parsing.



parseSlice
public String parseSlice(ParserOutput parserOutput, String raw, int targetSection) throws Exception(Code)
This method provides the capability for retrieving a section of Wiki markup from an existing document. It is used primarily when editing a section of a topic. This method will return all content from the specified section, up to the either the next section of the same or greater level or the end of the document. For example, if the specified section is an <h3>, all content up to the next <h1>, <h2>, <h3> or the end of the document will be returned.
Parameters:
  parserOutput - A ParserOutput object containing parsermetadata output.
Parameters:
  raw - The raw Wiki text that is to be parsed.
Parameters:
  targetSection - The section (counted from zero) that is to be returned. Returns the raw topic content for the target section.
throws:
  Exception - Thrown if any error occurs during parsing.



parseSplice
public String parseSplice(ParserOutput parserOutput, String raw, int targetSection, String replacementText) throws Exception(Code)
This method provides the capability for splicing a section of new content back into a document. It is used primarily when editing a section of a topic. This method will replace all content in a specified section, up to the either the next section of the same or greater level or the end of the document. For example, if the specified section is an <h3>, all content up to the next <h1>, <h2>, <h3> or the end of the document will be replaced with the specified text.
Parameters:
  parserOutput - A ParserOutput object containing parsermetadata output.
Parameters:
  raw - The raw Wiki text that is to be parsed.
Parameters:
  targetSection - The section (counted from zero) that is to be returned.
Parameters:
  replacementText - The text to replace the target section text with. The raw topic content including the new replacement text.
throws:
  Exception - Thrown if any error occurs during parsing.



Fields inherited from org.jamwiki.parser.AbstractParser
protected ParserInput parserInput(Code)(Java Doc)

Methods inherited from org.jamwiki.parser.AbstractParser
abstract public String buildRedirectContent(String topicName)(Code)(Java Doc)
abstract public String parseFragment(ParserOutput parserOutput, String raw, int mode) throws Exception(Code)(Java Doc)
abstract public String parseHTML(ParserOutput parserOutput, String raw) throws Exception(Code)(Java Doc)
abstract public void parseMetadata(ParserOutput parserOutput, String raw) throws Exception(Code)(Java Doc)
abstract public String parseMinimal(String raw) throws Exception(Code)(Java Doc)
abstract public String parseSlice(ParserOutput parserOutput, String raw, int targetSection) throws Exception(Code)(Java Doc)
abstract public String parseSplice(ParserOutput parserOutput, String raw, int targetSection, String replacementText) throws Exception(Code)(Java Doc)

Methods inherited from java.lang.Object
native protected Object clone() throws CloneNotSupportedException(Code)(Java Doc)
public boolean equals(Object obj)(Code)(Java Doc)
protected void finalize() throws Throwable(Code)(Java Doc)
final native public Class getClass()(Code)(Java Doc)
native public int hashCode()(Code)(Java Doc)
final native public void notify()(Code)(Java Doc)
final native public void notifyAll()(Code)(Java Doc)
public String toString()(Code)(Java Doc)
final native public void wait(long timeout) throws InterruptedException(Code)(Java Doc)
final public void wait(long timeout, int nanos) throws InterruptedException(Code)(Java Doc)
final public void wait() throws InterruptedException(Code)(Java Doc)

www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.