Building parsers with java

Building Parsers with Java

Parser building is a powerful programming technique that opens a world of opportunity for designing how users interact with applications. By creating mini-languages, you can precisely address the requirements of your application development domain. Writing your own parsers empowers you to access a database more effectively than SQL to efficiently control the movement of an order through its workflow, to command the actions of a robot, and to control access privileges to transactions in a system. The repertoire of today’s professional programmer should include the know-how to create custom languages.

Building Parsers with Java(TM) shows how to create parsers that recognize custom programming languages. This book and its accompanying CD provide an in-depth explanation and clearly written tutorial on writing parsers, following the Interpreter Design Pattern. An easy-to-follow demonstration on how to apply parsers to vital development tasks is included, using more than a hundred short examples, numerous UML diagrams, and a pure Java parser toolkit to illustrate key points.

  • How to design, code, and test a working parser
  • How to create a parser to read a data language, and how to create new computer languages with XML
  • How to translate the design of a language into code
  • How to accept an arithmetic formula and compute its result
  • How to accept and apply matching expressions like th* one
  • How to use tokenizers to define a parser in terms of logical nuggets instead of individual characters
  • How to build parsers for a custom logic language like Prolog
  • How to build parsers for a custom query language that goes beyond SQL
  • How to construct an imperative language that translates text into commands that direct a sequence of actions
Читайте также:  Business24 lurv index php

Источник

Building Parsers with Java

BPWJ is Java package that allows users to quickly develop parsers for application specific mini-languages. New languages are created incrumentally from generic tokenizer and parser classes.

Project Activity

Categories

License

Follow Building Parsers with Java

Open LMS is Open Source at its core. Migrating to Open LMS is simple and easy.

As the largest commercial provider of hosting and support services for the open-source Moodle™ learning platform, we help organizations and institutions deliver great learning experiences without complexities

User Reviews

Additional Project Details

Languages

Intended Audience

Programming Language

Registered

Highcharts is a JavaScript charting library that allows developers to create interactive and visually appealing charts for web applications. It offers a wide range of chart types, including line charts, bar charts, pie charts, scatter plots, and more. It also supports different types of data.

Userback is a user feedback platform that automates the feedback lifecycle for websites and applications to improve product fit and speed development cycles. Userback empowers more than 20,000 software teams to collect, manage, and resolve visual feedback directly from their users. Built.

Kissflow is a low-code application development platform that brings business users and IT closer to simplify work management and dramatically accelerate digital transformation. With Kissflow, enterprise applications can be built in weeks. It’s the only platform built for multiple personas.

Источник

Building Parsers with Java™

Building Parsers with Java™

Read it now on the O’Reilly learning platform with a 10-day free trial.

O’Reilly members get unlimited access to books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.

Book description

Parser building is a powerful programming technique that opens a world of opportunity for designing how users interact with applications. By creating mini-languages, you can precisely address the requirements of your application development domain. Writing your own parsers empowers you to access a database more effectively than SQL to efficiently control the movement of an order through its workflow, to command the actions of a robot, and to control access privileges to transactions in a system. The repertoire of today’s professional programmer should include the know-how to create custom languages.

Building Parsers with Java™ shows how to create parsers that recognize custom programming languages. This book and its accompanying CD provide an in-depth explanation and clearly written tutorial on writing parsers, following the Interpreter Design Pattern. An easy-to-follow demonstration on how to apply parsers to vital development tasks is included, using more than a hundred short examples, numerous UML diagrams, and a pure Java parser toolkit to illustrate key points.

Table of contents

  1. Copyright
  2. Foreword
  3. Preface
  4. Introduction
    1. The Role of Parsers
    2. What Is a Language?
    3. The Organization of This Book
    4. Summary
    1. What Is a Parser?
    2. Parser Collaborations
    3. Assemblies
    4. The Parser Hierarchy
    5. Terminal Parsers
    6. Composite Parsers
    7. Assemblers
    8. Summary
    1. Design Overview
    2. Deciding to Tokenize
    3. Designing Assemblers
    4. Grammars: A Shorthand for Parsers
    5. Example: Designing a Grammar for a Track Robot
    6. Translating a Grammar to Code
    7. Completing a Parser
    8. Summary
    1. Feature Testing
    2. Random Testing
    3. Special Tokenizers and Targets
    4. Summary
    1. The Role of Data Languages
    2. A Data Language Example
    3. A Coffee Grammar
    4. A Tokenizing Problem
    5. Coffee Assemblers
    6. Translating the Coffee Grammar to Code
    7. Data Language Parser Summary
    8. Parsers with XML
    9. Helpers
    10. Summary
    1. The Role of Grammar Transformation
    2. Ensuring Correct Associativity
    3. Eliminating Left Recursion
    4. Ensuring Proper Precedence
    5. Eliminating Parser Class Loops
    6. Summary
    1. Building an Arithmetic Parser
    2. An Arithmetic Grammar
    3. Arithmetic Assemblers
    4. An Arithmetic Grammar Parser
    5. Summary
    1. The Role of Regular Expressions
    2. Building a Regular Expression Parser
    3. A Regular Expression Grammar
    4. Regular Expression Assemblers
    5. A Regular Expression Parser
    6. Summary
    1. The Role of a Tokenizer
    2. Acquiring a Tokenizer
    3. Tokenizers in Standard Java
    4. A Token Class
    5. A Tokenizer Class
    6. Tokenizer Lookup Tables
    7. Tokenizer States
    8. Setting a Tokenizer’s Source
    9. Customizing a Tokenizer
    10. The TokenStringSource Utility
    11. Token Strings
    12. Summary
    1. Introduction
    2. Parser Matching
    3. Repetition Matching
    4. Collection Parsers
    5. Sequence Matching
    6. Alternation Matching
    7. Empty Matching
    8. Terminal Matching
    9. Parser Matching Utilities
    10. Summary
    1. The Role of New Types of Parsers
    2. New Terminals
    3. New Token Types
    4. New Parser Features
    5. Summary
    1. Engines versus Interpreters
    2. The Role of Engines
    3. Building Blocks
    4. Unification
    5. Facts
    6. Programs and Queries
    7. Proofs
    8. Rules
    9. Additional Features of the Engine
    10. Summary
    1. The Role of Logic Languages
    2. Building Blocks
    3. A Logikus Interactive Development Environment
    4. Unification
    5. Comparisons
    6. Rules, Axioms, and Programs
    7. Proofs
    8. Additional Features of Logikus
    9. Lists
    10. List Applications
    11. Modeling Transitive and Symmetric Relations
    12. Example Applications
    13. Summary
    1. Building a Logic Language Environment
    2. A Logikus Grammar
    3. Logikus Assemblers
    4. The Logikus Interactive Development Environment
    5. Summary
    1. The Role of Query Languages
    2. A Sample Database
    3. Jaql
    4. Building a Query Language Environment
    5. Translating User Queries to Engine Queries
    6. A Query Builder
    7. A Speller
    8. Jaql Grammar
    9. Creating the Jaql Parser
    10. Jaql Assemblers
    11. The Jaql User Environment
    12. Summary
    1. The Role of Imperative Languages
    2. Sling
    3. Sling Programming
    4. Building the Sling Environment
    5. Building Commands
    6. Sling Commands
    7. Building Runtime Functions
    8. Sling Functions
    9. Sling Target
    10. A Sling Grammar
    11. Sling Assemblers
    12. A Sling Parser
    13. Summary
    1. Get Started
    2. Keep Going
    1. Classes
    2. Class Relationships
    3. Interfaces
    4. Objects

    Product information

    • Title: Building Parsers with Java™
    • Author(s): Steven John Metsker
    • Release date: March 2001
    • Publisher(s): Addison-Wesley Professional
    • ISBN: 9780201719628

    You might also like

    Check it out now on O’Reilly

    Dive in for free with a 10-day trial of the O’Reilly learning platform—then explore all the other resources our members count on to build skills and solve problems every day.

    Источник

    Building Parsers with Java

    Parser building is a powerful programming technique that opens a world of opportunity for designing how users interact with applications. By creating mini-languages, you can precisely address the requirements of your application development domain. Writing your own parsers empowers you to access a database more effectively than SQL to efficiently control the movement of an order through its workflow, to command the actions of a robot, and to control access privileges to transactions in a system. The repertoire of today’s professional programmer should include the know-how to create custom languages.

    Building Parsers with Java(TM) shows how to create parsers that recognize custom programming languages. This book and its accompanying CD provide an in-depth explanation and clearly written tutorial on writing parsers, following the Interpreter Design Pattern. An easy-to-follow demonstration on how to apply parsers to vital development tasks is included, using more than a hundred short examples, numerous UML diagrams, and a pure Java parser toolkit to illustrate key points.

    • How to design, code, and test a working parser
    • How to create a parser to read a data language, and how to create new computer languages with XML
    • How to translate the design of a language into code
    • How to accept an arithmetic formula and compute its result
    • How to accept and apply matching expressions like th* one
    • How to use tokenizers to define a parser in terms of logical nuggets instead of individual characters
    • How to build parsers for a custom logic language like Prolog
    • How to build parsers for a custom query language that goes beyond SQL
    • How to construct an imperative language that translates text into commands that direct a sequence of actions

    Источник

Оцените статью