doctoral consortium@ruleml2015: seamless cooperation of java and prolog for rule-based software...
TRANSCRIPT
![Page 1: Doctoral Consortium@RuleML2015: Seamless Cooperation of JAVA and PROLOG for Rule-Based Software Development](https://reader031.vdocuments.net/reader031/viewer/2022032513/55d28754bb61eb9e618b45b4/html5/thumbnails/1.jpg)
Seamless Cooperationof Java and Prolog
for Rule-Based Software Development
Ludwig Ostermayer
University of Wurzburg, Department of Computer Science,Efficient Algorithms and Knowledge-Based Systems
04.08.2015
Ludwig Ostermayer (University of Wurzburg) Seamless Cooperation of Java and Prolog 04.08.2015
![Page 2: Doctoral Consortium@RuleML2015: Seamless Cooperation of JAVA and PROLOG for Rule-Based Software Development](https://reader031.vdocuments.net/reader031/viewer/2022032513/55d28754bb61eb9e618b45b4/html5/thumbnails/2.jpg)
Agenda
Ludwig Ostermayer (University of Wurzburg) Seamless Cooperation of Java and Prolog 04.08.2015
![Page 3: Doctoral Consortium@RuleML2015: Seamless Cooperation of JAVA and PROLOG for Rule-Based Software Development](https://reader031.vdocuments.net/reader031/viewer/2022032513/55d28754bb61eb9e618b45b4/html5/thumbnails/3.jpg)
Modern Software Systems
Modern Software Systems often consist of dynamically linked Subsystems.
Subsystems
modular
solve problems of a certain problem domain
evolve continually and often independently
are implemented with different programming/scripting languages
follow different programming paradigms
Pfeil mit Text Interoperability Problems
Ludwig Ostermayer (University of Wurzburg) Seamless Cooperation of Java and Prolog 04.08.2015
![Page 4: Doctoral Consortium@RuleML2015: Seamless Cooperation of JAVA and PROLOG for Rule-Based Software Development](https://reader031.vdocuments.net/reader031/viewer/2022032513/55d28754bb61eb9e618b45b4/html5/thumbnails/4.jpg)
Modern Software Systems
Modern Software Systems often consist of dynamically linked Subsystems.
Subsystems
modular
solve problems of a certain problem domain
evolve continually and often independently
are implemented with different programming/scripting languages
follow different programming paradigms
Pfeil mit Text Interoperability Problems
Ludwig Ostermayer (University of Wurzburg) Seamless Cooperation of Java and Prolog 04.08.2015
![Page 5: Doctoral Consortium@RuleML2015: Seamless Cooperation of JAVA and PROLOG for Rule-Based Software Development](https://reader031.vdocuments.net/reader031/viewer/2022032513/55d28754bb61eb9e618b45b4/html5/thumbnails/5.jpg)
Modern Software Systems
Modern Software Systems often consist of dynamically linked Subsystems.
Subsystems
modular
solve problems of a certain problem domain
evolve continually and often independently
are implemented with different programming/scripting languages
follow different programming paradigms
Pfeil mit Text Interoperability Problems
Ludwig Ostermayer (University of Wurzburg) Seamless Cooperation of Java and Prolog 04.08.2015
![Page 6: Doctoral Consortium@RuleML2015: Seamless Cooperation of JAVA and PROLOG for Rule-Based Software Development](https://reader031.vdocuments.net/reader031/viewer/2022032513/55d28754bb61eb9e618b45b4/html5/thumbnails/6.jpg)
Modern Software Systems
Modern Software Systems often consist of dynamically linked Subsystems.
Subsystems
modular
solve problems of a certain problem domain
evolve continually and often independently
are implemented with different programming/scripting languages
follow different programming paradigms
Pfeil mit Text Interoperability Problems
Ludwig Ostermayer (University of Wurzburg) Seamless Cooperation of Java and Prolog 04.08.2015
![Page 7: Doctoral Consortium@RuleML2015: Seamless Cooperation of JAVA and PROLOG for Rule-Based Software Development](https://reader031.vdocuments.net/reader031/viewer/2022032513/55d28754bb61eb9e618b45b4/html5/thumbnails/7.jpg)
Modern Software Systems
Modern Software Systems often consist of dynamically linked Subsystems.
Subsystems
modular
solve problems of a certain problem domain
evolve continually and often independently
are implemented with different programming/scripting languages
follow different programming paradigms
Pfeil mit Text Interoperability Problems
Ludwig Ostermayer (University of Wurzburg) Seamless Cooperation of Java and Prolog 04.08.2015
![Page 8: Doctoral Consortium@RuleML2015: Seamless Cooperation of JAVA and PROLOG for Rule-Based Software Development](https://reader031.vdocuments.net/reader031/viewer/2022032513/55d28754bb61eb9e618b45b4/html5/thumbnails/8.jpg)
Object-Oriented Programming
Java
very popular OO language
rich set of libraries and tools
mature integrated development environments
active community
Flaws
verbose and little declarative
no native rule representation
no API for rule-based development
Ludwig Ostermayer (University of Wurzburg) Seamless Cooperation of Java and Prolog 04.08.2015
![Page 9: Doctoral Consortium@RuleML2015: Seamless Cooperation of JAVA and PROLOG for Rule-Based Software Development](https://reader031.vdocuments.net/reader031/viewer/2022032513/55d28754bb61eb9e618b45b4/html5/thumbnails/9.jpg)
Object-Oriented Programming
Java
very popular OO language
rich set of libraries and tools
mature integrated development environments
active community
Flaws
verbose and little declarative
no native rule representation
no API for rule-based development
Ludwig Ostermayer (University of Wurzburg) Seamless Cooperation of Java and Prolog 04.08.2015
![Page 10: Doctoral Consortium@RuleML2015: Seamless Cooperation of JAVA and PROLOG for Rule-Based Software Development](https://reader031.vdocuments.net/reader031/viewer/2022032513/55d28754bb61eb9e618b45b4/html5/thumbnails/10.jpg)
Object-Oriented Programming
Java
very popular OO language
rich set of libraries and tools
mature integrated development environments
active community
Flaws
verbose and little declarative
no native rule representation
no API for rule-based development
Ludwig Ostermayer (University of Wurzburg) Seamless Cooperation of Java and Prolog 04.08.2015
![Page 11: Doctoral Consortium@RuleML2015: Seamless Cooperation of JAVA and PROLOG for Rule-Based Software Development](https://reader031.vdocuments.net/reader031/viewer/2022032513/55d28754bb61eb9e618b45b4/html5/thumbnails/11.jpg)
Object-Oriented Programming
Java
very popular OO language
rich set of libraries and tools
mature integrated development environments
active community
Flaws
verbose and little declarative
no native rule representation
no API for rule-based development
Ludwig Ostermayer (University of Wurzburg) Seamless Cooperation of Java and Prolog 04.08.2015
![Page 12: Doctoral Consortium@RuleML2015: Seamless Cooperation of JAVA and PROLOG for Rule-Based Software Development](https://reader031.vdocuments.net/reader031/viewer/2022032513/55d28754bb61eb9e618b45b4/html5/thumbnails/12.jpg)
Object-Oriented Programming
Java
very popular OO language
rich set of libraries and tools
mature integrated development environments
active community
Flaws
verbose and little declarative
no native rule representation
no API for rule-based development
Ludwig Ostermayer (University of Wurzburg) Seamless Cooperation of Java and Prolog 04.08.2015
![Page 13: Doctoral Consortium@RuleML2015: Seamless Cooperation of JAVA and PROLOG for Rule-Based Software Development](https://reader031.vdocuments.net/reader031/viewer/2022032513/55d28754bb61eb9e618b45b4/html5/thumbnails/13.jpg)
Object-Oriented Programming
Java
very popular OO language
rich set of libraries and tools
mature integrated development environments
active community
Flaws
verbose and little declarative
no native rule representation
no API for rule-based development
Ludwig Ostermayer (University of Wurzburg) Seamless Cooperation of Java and Prolog 04.08.2015
![Page 14: Doctoral Consortium@RuleML2015: Seamless Cooperation of JAVA and PROLOG for Rule-Based Software Development](https://reader031.vdocuments.net/reader031/viewer/2022032513/55d28754bb61eb9e618b45b4/html5/thumbnails/14.jpg)
Object-Oriented Programming
Java
very popular OO language
rich set of libraries and tools
mature integrated development environments
active community
Flaws
verbose and little declarative
no native rule representation
no API for rule-based development
Ludwig Ostermayer (University of Wurzburg) Seamless Cooperation of Java and Prolog 04.08.2015
![Page 15: Doctoral Consortium@RuleML2015: Seamless Cooperation of JAVA and PROLOG for Rule-Based Software Development](https://reader031.vdocuments.net/reader031/viewer/2022032513/55d28754bb61eb9e618b45b4/html5/thumbnails/15.jpg)
Logic Programming
Prolog
rule-based logic programming language
expert systems, linguistics and artificial intelligence
backtracking, partial bindings and incomplete structures
concise and declarative programs
Flaws
different Prolog implementations (BProlog, Ciao, ..., YAP)
platform dependence
programming in the large
Ludwig Ostermayer (University of Wurzburg) Seamless Cooperation of Java and Prolog 04.08.2015
![Page 16: Doctoral Consortium@RuleML2015: Seamless Cooperation of JAVA and PROLOG for Rule-Based Software Development](https://reader031.vdocuments.net/reader031/viewer/2022032513/55d28754bb61eb9e618b45b4/html5/thumbnails/16.jpg)
Logic Programming
Prolog
rule-based logic programming language
expert systems, linguistics and artificial intelligence
backtracking, partial bindings and incomplete structures
concise and declarative programs
Flaws
different Prolog implementations (BProlog, Ciao, ..., YAP)
platform dependence
programming in the large
Ludwig Ostermayer (University of Wurzburg) Seamless Cooperation of Java and Prolog 04.08.2015
![Page 17: Doctoral Consortium@RuleML2015: Seamless Cooperation of JAVA and PROLOG for Rule-Based Software Development](https://reader031.vdocuments.net/reader031/viewer/2022032513/55d28754bb61eb9e618b45b4/html5/thumbnails/17.jpg)
Logic Programming
Prolog
rule-based logic programming language
expert systems, linguistics and artificial intelligence
backtracking, partial bindings and incomplete structures
concise and declarative programs
Flaws
different Prolog implementations (BProlog, Ciao, ..., YAP)
platform dependence
programming in the large
Ludwig Ostermayer (University of Wurzburg) Seamless Cooperation of Java and Prolog 04.08.2015
![Page 18: Doctoral Consortium@RuleML2015: Seamless Cooperation of JAVA and PROLOG for Rule-Based Software Development](https://reader031.vdocuments.net/reader031/viewer/2022032513/55d28754bb61eb9e618b45b4/html5/thumbnails/18.jpg)
Logic Programming
Prolog
rule-based logic programming language
expert systems, linguistics and artificial intelligence
backtracking, partial bindings and incomplete structures
concise and declarative programs
Flaws
different Prolog implementations (BProlog, Ciao, ..., YAP)
platform dependence
programming in the large
Ludwig Ostermayer (University of Wurzburg) Seamless Cooperation of Java and Prolog 04.08.2015
![Page 19: Doctoral Consortium@RuleML2015: Seamless Cooperation of JAVA and PROLOG for Rule-Based Software Development](https://reader031.vdocuments.net/reader031/viewer/2022032513/55d28754bb61eb9e618b45b4/html5/thumbnails/19.jpg)
Logic Programming
Prolog
rule-based logic programming language
expert systems, linguistics and artificial intelligence
backtracking, partial bindings and incomplete structures
concise and declarative programs
Flaws
different Prolog implementations (BProlog, Ciao, ..., YAP)
platform dependence
programming in the large
Ludwig Ostermayer (University of Wurzburg) Seamless Cooperation of Java and Prolog 04.08.2015
![Page 20: Doctoral Consortium@RuleML2015: Seamless Cooperation of JAVA and PROLOG for Rule-Based Software Development](https://reader031.vdocuments.net/reader031/viewer/2022032513/55d28754bb61eb9e618b45b4/html5/thumbnails/20.jpg)
Logic Programming
Prolog
rule-based logic programming language
expert systems, linguistics and artificial intelligence
backtracking, partial bindings and incomplete structures
concise and declarative programs
Flaws
different Prolog implementations (BProlog, Ciao, ..., YAP)
platform dependence
programming in the large
Ludwig Ostermayer (University of Wurzburg) Seamless Cooperation of Java and Prolog 04.08.2015
![Page 21: Doctoral Consortium@RuleML2015: Seamless Cooperation of JAVA and PROLOG for Rule-Based Software Development](https://reader031.vdocuments.net/reader031/viewer/2022032513/55d28754bb61eb9e618b45b4/html5/thumbnails/21.jpg)
Cooperation of Java and Prolog
Reaping the benefits of decades of LP research whilesaving the investment already done for Java!1
1M. Calejo, PACLP, 1999.
Ludwig Ostermayer (University of Wurzburg) Seamless Cooperation of Java and Prolog 04.08.2015
![Page 22: Doctoral Consortium@RuleML2015: Seamless Cooperation of JAVA and PROLOG for Rule-Based Software Development](https://reader031.vdocuments.net/reader031/viewer/2022032513/55d28754bb61eb9e618b45b4/html5/thumbnails/22.jpg)
Cooperation of Java and Prolog
Reaping the benefits of decades of LP research whilesaving the investment already done for Java!1
1M. Calejo, PACLP, 1999.
Ludwig Ostermayer (University of Wurzburg) Seamless Cooperation of Java and Prolog 04.08.2015
![Page 23: Doctoral Consortium@RuleML2015: Seamless Cooperation of JAVA and PROLOG for Rule-Based Software Development](https://reader031.vdocuments.net/reader031/viewer/2022032513/55d28754bb61eb9e618b45b4/html5/thumbnails/23.jpg)
Isn’t it already sufficiently solved?
Related Work
Prolog Cafe (M. Banbara et al., 1997)
Jpl (P. Singleton et al., 1999)
InterProlog ( M. Calejo, 1999)
based on Linguistic Symbiosis (M. D’Hondt, 2004)
based on Annotations and Generics (M. Cimadamore et al., 2007)
Logic Java (T. Majchrzak et al., 2011)
Logic Objects ( S. Castro et al., 2013)
Ludwig Ostermayer (University of Wurzburg) Seamless Cooperation of Java and Prolog 04.08.2015
![Page 24: Doctoral Consortium@RuleML2015: Seamless Cooperation of JAVA and PROLOG for Rule-Based Software Development](https://reader031.vdocuments.net/reader031/viewer/2022032513/55d28754bb61eb9e618b45b4/html5/thumbnails/24.jpg)
Isn’t it already sufficiently solved?
Related Work
Prolog Cafe (M. Banbara et al., 1997)
Jpl (P. Singleton et al., 1999)
InterProlog ( M. Calejo, 1999)
based on Linguistic Symbiosis (M. D’Hondt, 2004)
based on Annotations and Generics (M. Cimadamore et al., 2007)
Logic Java (T. Majchrzak et al., 2011)
Logic Objects ( S. Castro et al., 2013)
Ludwig Ostermayer (University of Wurzburg) Seamless Cooperation of Java and Prolog 04.08.2015
![Page 25: Doctoral Consortium@RuleML2015: Seamless Cooperation of JAVA and PROLOG for Rule-Based Software Development](https://reader031.vdocuments.net/reader031/viewer/2022032513/55d28754bb61eb9e618b45b4/html5/thumbnails/25.jpg)
Observations
Java evolves ... new approaches to cooperate with Prologemerge!
Ludwig Ostermayer (University of Wurzburg) Seamless Cooperation of Java and Prolog 04.08.2015
![Page 26: Doctoral Consortium@RuleML2015: Seamless Cooperation of JAVA and PROLOG for Rule-Based Software Development](https://reader031.vdocuments.net/reader031/viewer/2022032513/55d28754bb61eb9e618b45b4/html5/thumbnails/26.jpg)
Observations
Java evolves ... new approaches to cooperate with Prologemerge!
Ludwig Ostermayer (University of Wurzburg) Seamless Cooperation of Java and Prolog 04.08.2015
![Page 27: Doctoral Consortium@RuleML2015: Seamless Cooperation of JAVA and PROLOG for Rule-Based Software Development](https://reader031.vdocuments.net/reader031/viewer/2022032513/55d28754bb61eb9e618b45b4/html5/thumbnails/27.jpg)
Synthesis of the State of the Art
Continuous Problems
portability
dependence on a specific Prolog implementationdependence on native codemodifications to the Jvm
obfuscation
boilerplate codecomplex blended syntax
overhead
coding praxisperformance
IDE support
Ludwig Ostermayer (University of Wurzburg) Seamless Cooperation of Java and Prolog 04.08.2015
![Page 28: Doctoral Consortium@RuleML2015: Seamless Cooperation of JAVA and PROLOG for Rule-Based Software Development](https://reader031.vdocuments.net/reader031/viewer/2022032513/55d28754bb61eb9e618b45b4/html5/thumbnails/28.jpg)
Synthesis of the State of the Art
Continuous Problems
portability
dependence on a specific Prolog implementationdependence on native codemodifications to the Jvm
obfuscation
boilerplate codecomplex blended syntax
overhead
coding praxisperformance
IDE support
Ludwig Ostermayer (University of Wurzburg) Seamless Cooperation of Java and Prolog 04.08.2015
![Page 29: Doctoral Consortium@RuleML2015: Seamless Cooperation of JAVA and PROLOG for Rule-Based Software Development](https://reader031.vdocuments.net/reader031/viewer/2022032513/55d28754bb61eb9e618b45b4/html5/thumbnails/29.jpg)
Synthesis of the State of the Art
Continuous Problems
portability
dependence on a specific Prolog implementationdependence on native codemodifications to the Jvm
obfuscation
boilerplate codecomplex blended syntax
overhead
coding praxisperformance
IDE support
Ludwig Ostermayer (University of Wurzburg) Seamless Cooperation of Java and Prolog 04.08.2015
![Page 30: Doctoral Consortium@RuleML2015: Seamless Cooperation of JAVA and PROLOG for Rule-Based Software Development](https://reader031.vdocuments.net/reader031/viewer/2022032513/55d28754bb61eb9e618b45b4/html5/thumbnails/30.jpg)
Synthesis of the State of the Art
Continuous Problems
portability
dependence on a specific Prolog implementationdependence on native codemodifications to the Jvm
obfuscation
boilerplate codecomplex blended syntax
overhead
coding praxisperformance
IDE support
Ludwig Ostermayer (University of Wurzburg) Seamless Cooperation of Java and Prolog 04.08.2015
![Page 31: Doctoral Consortium@RuleML2015: Seamless Cooperation of JAVA and PROLOG for Rule-Based Software Development](https://reader031.vdocuments.net/reader031/viewer/2022032513/55d28754bb61eb9e618b45b4/html5/thumbnails/31.jpg)
Synthesis of the State of the Art
Continuous Problems
portability
dependence on a specific Prolog implementationdependence on native codemodifications to the Jvm
obfuscation
boilerplate codecomplex blended syntax
overhead
coding praxisperformance
IDE support
Ludwig Ostermayer (University of Wurzburg) Seamless Cooperation of Java and Prolog 04.08.2015
![Page 32: Doctoral Consortium@RuleML2015: Seamless Cooperation of JAVA and PROLOG for Rule-Based Software Development](https://reader031.vdocuments.net/reader031/viewer/2022032513/55d28754bb61eb9e618b45b4/html5/thumbnails/32.jpg)
Synthesis of the State of the Art
Continuous Problems
portability
dependence on a specific Prolog implementationdependence on native codemodifications to the Jvm
obfuscation
boilerplate codecomplex blended syntax
overhead
coding praxisperformance
IDE support
Ludwig Ostermayer (University of Wurzburg) Seamless Cooperation of Java and Prolog 04.08.2015
![Page 33: Doctoral Consortium@RuleML2015: Seamless Cooperation of JAVA and PROLOG for Rule-Based Software Development](https://reader031.vdocuments.net/reader031/viewer/2022032513/55d28754bb61eb9e618b45b4/html5/thumbnails/33.jpg)
Synthesis of the State of the Art
Continuous Problems
portability
dependence on a specific Prolog implementationdependence on native codemodifications to the Jvm
obfuscation
boilerplate codecomplex blended syntax
overhead
coding praxisperformance
IDE support
Ludwig Ostermayer (University of Wurzburg) Seamless Cooperation of Java and Prolog 04.08.2015
![Page 34: Doctoral Consortium@RuleML2015: Seamless Cooperation of JAVA and PROLOG for Rule-Based Software Development](https://reader031.vdocuments.net/reader031/viewer/2022032513/55d28754bb61eb9e618b45b4/html5/thumbnails/34.jpg)
Synthesis of the State of the Art
Continuous Problems
portability
dependence on a specific Prolog implementationdependence on native codemodifications to the Jvm
obfuscation
boilerplate codecomplex blended syntax
overhead
coding praxisperformance
IDE support
Ludwig Ostermayer (University of Wurzburg) Seamless Cooperation of Java and Prolog 04.08.2015
![Page 35: Doctoral Consortium@RuleML2015: Seamless Cooperation of JAVA and PROLOG for Rule-Based Software Development](https://reader031.vdocuments.net/reader031/viewer/2022032513/55d28754bb61eb9e618b45b4/html5/thumbnails/35.jpg)
Connector Architecture for Prolog and Java
Java
Classes
Annotations
Objects
Prolog
Rules
Facts
PVNGenerator
OTM UnificationTerm
Capja
concise, extensible and intuitive communication layer purelyimplemented in Java
customizable object-term mapping (otm)
pluggable Prolog interface system (default interface included)
not limited to a certain Prolog system
high communication performance during runtime
smooth development cycle with IDE support in Java
Ludwig Ostermayer (University of Wurzburg) Seamless Cooperation of Java and Prolog 04.08.2015
![Page 36: Doctoral Consortium@RuleML2015: Seamless Cooperation of JAVA and PROLOG for Rule-Based Software Development](https://reader031.vdocuments.net/reader031/viewer/2022032513/55d28754bb61eb9e618b45b4/html5/thumbnails/36.jpg)
Connector Architecture for Prolog and Java
Java
Classes
Annotations
Objects
Prolog
Rules
Facts
PVNGenerator
OTM UnificationTerm
Capja
concise, extensible and intuitive communication layer purelyimplemented in Java
customizable object-term mapping (otm)
pluggable Prolog interface system (default interface included)
not limited to a certain Prolog system
high communication performance during runtime
smooth development cycle with IDE support in Java
Ludwig Ostermayer (University of Wurzburg) Seamless Cooperation of Java and Prolog 04.08.2015
![Page 37: Doctoral Consortium@RuleML2015: Seamless Cooperation of JAVA and PROLOG for Rule-Based Software Development](https://reader031.vdocuments.net/reader031/viewer/2022032513/55d28754bb61eb9e618b45b4/html5/thumbnails/37.jpg)
Connector Architecture for Prolog and Java
Java
Classes
Annotations
Objects
Prolog
Rules
Facts
PVNGenerator
OTM UnificationTerm
Capja
concise, extensible and intuitive communication layer purelyimplemented in Java
customizable object-term mapping (otm)
pluggable Prolog interface system (default interface included)
not limited to a certain Prolog system
high communication performance during runtime
smooth development cycle with IDE support in Java
Ludwig Ostermayer (University of Wurzburg) Seamless Cooperation of Java and Prolog 04.08.2015
![Page 38: Doctoral Consortium@RuleML2015: Seamless Cooperation of JAVA and PROLOG for Rule-Based Software Development](https://reader031.vdocuments.net/reader031/viewer/2022032513/55d28754bb61eb9e618b45b4/html5/thumbnails/38.jpg)
Connector Architecture for Prolog and Java
Java
Classes
Annotations
Objects
Prolog
Rules
Facts
PVNGenerator
OTM UnificationTerm
Capja
concise, extensible and intuitive communication layer purelyimplemented in Java
customizable object-term mapping (otm)
pluggable Prolog interface system (default interface included)
not limited to a certain Prolog system
high communication performance during runtime
smooth development cycle with IDE support in Java
Ludwig Ostermayer (University of Wurzburg) Seamless Cooperation of Java and Prolog 04.08.2015
![Page 39: Doctoral Consortium@RuleML2015: Seamless Cooperation of JAVA and PROLOG for Rule-Based Software Development](https://reader031.vdocuments.net/reader031/viewer/2022032513/55d28754bb61eb9e618b45b4/html5/thumbnails/39.jpg)
Connector Architecture for Prolog and Java
Java
Classes
Annotations
Objects
Prolog
Rules
Facts
PVNGenerator
OTM UnificationTerm
Capja
concise, extensible and intuitive communication layer purelyimplemented in Java
customizable object-term mapping (otm)
pluggable Prolog interface system (default interface included)
not limited to a certain Prolog system
high communication performance during runtime
smooth development cycle with IDE support in Java
Ludwig Ostermayer (University of Wurzburg) Seamless Cooperation of Java and Prolog 04.08.2015
![Page 40: Doctoral Consortium@RuleML2015: Seamless Cooperation of JAVA and PROLOG for Rule-Based Software Development](https://reader031.vdocuments.net/reader031/viewer/2022032513/55d28754bb61eb9e618b45b4/html5/thumbnails/40.jpg)
Connector Architecture for Prolog and Java
Java
Classes
Annotations
Objects
Prolog
Rules
Facts
PVNGenerator
OTM UnificationTerm
Capja
concise, extensible and intuitive communication layer purelyimplemented in Java
customizable object-term mapping (otm)
pluggable Prolog interface system (default interface included)
not limited to a certain Prolog system
high communication performance during runtime
smooth development cycle with IDE support in Java
Ludwig Ostermayer (University of Wurzburg) Seamless Cooperation of Java and Prolog 04.08.2015
![Page 41: Doctoral Consortium@RuleML2015: Seamless Cooperation of JAVA and PROLOG for Rule-Based Software Development](https://reader031.vdocuments.net/reader031/viewer/2022032513/55d28754bb61eb9e618b45b4/html5/thumbnails/41.jpg)
Components of Capja
Object-Term Mapping (otm)
default mapping
Annotation layer in Java for a customized mapping
Prolog-View on a given class in Java (@PlView Annotation)
Ludwig Ostermayer (University of Wurzburg) Seamless Cooperation of Java and Prolog 04.08.2015
![Page 42: Doctoral Consortium@RuleML2015: Seamless Cooperation of JAVA and PROLOG for Rule-Based Software Development](https://reader031.vdocuments.net/reader031/viewer/2022032513/55d28754bb61eb9e618b45b4/html5/thumbnails/42.jpg)
Components of Capja
Object-Term Mapping (otm)
default mapping
Annotation layer in Java for a customized mapping
Prolog-View on a given class in Java (@PlView Annotation)
Ludwig Ostermayer (University of Wurzburg) Seamless Cooperation of Java and Prolog 04.08.2015
![Page 43: Doctoral Consortium@RuleML2015: Seamless Cooperation of JAVA and PROLOG for Rule-Based Software Development](https://reader031.vdocuments.net/reader031/viewer/2022032513/55d28754bb61eb9e618b45b4/html5/thumbnails/43.jpg)
Components of Capja
Object-Term Mapping (otm)
default mapping
Annotation layer in Java for a customized mapping
Prolog-View on a given class in Java (@PlView Annotation)
Ludwig Ostermayer (University of Wurzburg) Seamless Cooperation of Java and Prolog 04.08.2015
![Page 44: Doctoral Consortium@RuleML2015: Seamless Cooperation of JAVA and PROLOG for Rule-Based Software Development](https://reader031.vdocuments.net/reader031/viewer/2022032513/55d28754bb61eb9e618b45b4/html5/thumbnails/44.jpg)
Components of Capja
Prolog-View Notation (PVN)
Prolog list-based notation
for the integration of Prolog predicates in Java
describes the structure of a term...
enriched by mapping information for Java
sufficient to generate from it the skeleton of a class...
... or an @PlView Annotation to control the otm from Prolog
Ludwig Ostermayer (University of Wurzburg) Seamless Cooperation of Java and Prolog 04.08.2015
![Page 45: Doctoral Consortium@RuleML2015: Seamless Cooperation of JAVA and PROLOG for Rule-Based Software Development](https://reader031.vdocuments.net/reader031/viewer/2022032513/55d28754bb61eb9e618b45b4/html5/thumbnails/45.jpg)
Components of Capja
Prolog-View Notation (PVN)
Prolog list-based notation
for the integration of Prolog predicates in Java
describes the structure of a term...
enriched by mapping information for Java
sufficient to generate from it the skeleton of a class...
... or an @PlView Annotation to control the otm from Prolog
Ludwig Ostermayer (University of Wurzburg) Seamless Cooperation of Java and Prolog 04.08.2015
![Page 46: Doctoral Consortium@RuleML2015: Seamless Cooperation of JAVA and PROLOG for Rule-Based Software Development](https://reader031.vdocuments.net/reader031/viewer/2022032513/55d28754bb61eb9e618b45b4/html5/thumbnails/46.jpg)
Components of Capja
Prolog-View Notation (PVN)
Prolog list-based notation
for the integration of Prolog predicates in Java
describes the structure of a term...
enriched by mapping information for Java
sufficient to generate from it the skeleton of a class...
... or an @PlView Annotation to control the otm from Prolog
Ludwig Ostermayer (University of Wurzburg) Seamless Cooperation of Java and Prolog 04.08.2015
![Page 47: Doctoral Consortium@RuleML2015: Seamless Cooperation of JAVA and PROLOG for Rule-Based Software Development](https://reader031.vdocuments.net/reader031/viewer/2022032513/55d28754bb61eb9e618b45b4/html5/thumbnails/47.jpg)
Components of Capja
Prolog-View Notation (PVN)
Prolog list-based notation
for the integration of Prolog predicates in Java
describes the structure of a term...
enriched by mapping information for Java
sufficient to generate from it the skeleton of a class...
... or an @PlView Annotation to control the otm from Prolog
Ludwig Ostermayer (University of Wurzburg) Seamless Cooperation of Java and Prolog 04.08.2015
![Page 48: Doctoral Consortium@RuleML2015: Seamless Cooperation of JAVA and PROLOG for Rule-Based Software Development](https://reader031.vdocuments.net/reader031/viewer/2022032513/55d28754bb61eb9e618b45b4/html5/thumbnails/48.jpg)
Components of Capja
Prolog-View Notation (PVN)
Prolog list-based notation
for the integration of Prolog predicates in Java
describes the structure of a term...
enriched by mapping information for Java
sufficient to generate from it the skeleton of a class...
... or an @PlView Annotation to control the otm from Prolog
Ludwig Ostermayer (University of Wurzburg) Seamless Cooperation of Java and Prolog 04.08.2015
![Page 49: Doctoral Consortium@RuleML2015: Seamless Cooperation of JAVA and PROLOG for Rule-Based Software Development](https://reader031.vdocuments.net/reader031/viewer/2022032513/55d28754bb61eb9e618b45b4/html5/thumbnails/49.jpg)
Components of Capja
Pluggable Interface System
(default) Portable Prolog Interface (PPI)
PPI successfully tested with B-, Ciao-, Gnu-, Swi-, Tu-, Xsb-and Yap-Prolog.
works with existing interfaces like Jpl, InterProlog
works with Prolog sockets or servers
Ludwig Ostermayer (University of Wurzburg) Seamless Cooperation of Java and Prolog 04.08.2015
![Page 50: Doctoral Consortium@RuleML2015: Seamless Cooperation of JAVA and PROLOG for Rule-Based Software Development](https://reader031.vdocuments.net/reader031/viewer/2022032513/55d28754bb61eb9e618b45b4/html5/thumbnails/50.jpg)
Components of Capja
Pluggable Interface System
(default) Portable Prolog Interface (PPI)
PPI successfully tested with B-, Ciao-, Gnu-, Swi-, Tu-, Xsb-and Yap-Prolog.
works with existing interfaces like Jpl, InterProlog
works with Prolog sockets or servers
Ludwig Ostermayer (University of Wurzburg) Seamless Cooperation of Java and Prolog 04.08.2015
![Page 51: Doctoral Consortium@RuleML2015: Seamless Cooperation of JAVA and PROLOG for Rule-Based Software Development](https://reader031.vdocuments.net/reader031/viewer/2022032513/55d28754bb61eb9e618b45b4/html5/thumbnails/51.jpg)
Components of Capja
Pluggable Interface System
(default) Portable Prolog Interface (PPI)
PPI successfully tested with B-, Ciao-, Gnu-, Swi-, Tu-, Xsb-and Yap-Prolog.
works with existing interfaces like Jpl, InterProlog
works with Prolog sockets or servers
Ludwig Ostermayer (University of Wurzburg) Seamless Cooperation of Java and Prolog 04.08.2015
![Page 52: Doctoral Consortium@RuleML2015: Seamless Cooperation of JAVA and PROLOG for Rule-Based Software Development](https://reader031.vdocuments.net/reader031/viewer/2022032513/55d28754bb61eb9e618b45b4/html5/thumbnails/52.jpg)
Components of Capja
Pluggable Interface System
(default) Portable Prolog Interface (PPI)
PPI successfully tested with B-, Ciao-, Gnu-, Swi-, Tu-, Xsb-and Yap-Prolog.
works with existing interfaces like Jpl, InterProlog
works with Prolog sockets or servers
Ludwig Ostermayer (University of Wurzburg) Seamless Cooperation of Java and Prolog 04.08.2015
![Page 53: Doctoral Consortium@RuleML2015: Seamless Cooperation of JAVA and PROLOG for Rule-Based Software Development](https://reader031.vdocuments.net/reader031/viewer/2022032513/55d28754bb61eb9e618b45b4/html5/thumbnails/53.jpg)
Components of Capja
Pluggable Interface System
(default) Portable Prolog Interface (PPI)
PPI successfully tested with B-, Ciao-, Gnu-, Swi-, Tu-, Xsb-and Yap-Prolog.
works with existing interfaces like Jpl, InterProlog
works with Prolog sockets or servers
Ludwig Ostermayer (University of Wurzburg) Seamless Cooperation of Java and Prolog 04.08.2015
![Page 54: Doctoral Consortium@RuleML2015: Seamless Cooperation of JAVA and PROLOG for Rule-Based Software Development](https://reader031.vdocuments.net/reader031/viewer/2022032513/55d28754bb61eb9e618b45b4/html5/thumbnails/54.jpg)
Components of Capja
JPLambda
concise and readable Prolog queries in Java
based on Java Lambda expressions
code as data
Lambda expression to further narrow the result set
the Lambda’s evaluation is transferred (where possible) to Prolog
Ludwig Ostermayer (University of Wurzburg) Seamless Cooperation of Java and Prolog 04.08.2015
![Page 55: Doctoral Consortium@RuleML2015: Seamless Cooperation of JAVA and PROLOG for Rule-Based Software Development](https://reader031.vdocuments.net/reader031/viewer/2022032513/55d28754bb61eb9e618b45b4/html5/thumbnails/55.jpg)
Components of Capja
JPLambda
concise and readable Prolog queries in Java
based on Java Lambda expressions
code as data
Lambda expression to further narrow the result set
the Lambda’s evaluation is transferred (where possible) to Prolog
Ludwig Ostermayer (University of Wurzburg) Seamless Cooperation of Java and Prolog 04.08.2015
![Page 56: Doctoral Consortium@RuleML2015: Seamless Cooperation of JAVA and PROLOG for Rule-Based Software Development](https://reader031.vdocuments.net/reader031/viewer/2022032513/55d28754bb61eb9e618b45b4/html5/thumbnails/56.jpg)
Components of Capja
JPLambda
concise and readable Prolog queries in Java
based on Java Lambda expressions
code as data
Lambda expression to further narrow the result set
the Lambda’s evaluation is transferred (where possible) to Prolog
Ludwig Ostermayer (University of Wurzburg) Seamless Cooperation of Java and Prolog 04.08.2015
![Page 57: Doctoral Consortium@RuleML2015: Seamless Cooperation of JAVA and PROLOG for Rule-Based Software Development](https://reader031.vdocuments.net/reader031/viewer/2022032513/55d28754bb61eb9e618b45b4/html5/thumbnails/57.jpg)
Components of Capja
JPLambda
concise and readable Prolog queries in Java
based on Java Lambda expressions
code as data
Lambda expression to further narrow the result set
the Lambda’s evaluation is transferred (where possible) to Prolog
Ludwig Ostermayer (University of Wurzburg) Seamless Cooperation of Java and Prolog 04.08.2015
![Page 58: Doctoral Consortium@RuleML2015: Seamless Cooperation of JAVA and PROLOG for Rule-Based Software Development](https://reader031.vdocuments.net/reader031/viewer/2022032513/55d28754bb61eb9e618b45b4/html5/thumbnails/58.jpg)
Components of Capja
JPLambda
concise and readable Prolog queries in Java
based on Java Lambda expressions
code as data
Lambda expression to further narrow the result set
the Lambda’s evaluation is transferred (where possible) to Prolog
Ludwig Ostermayer (University of Wurzburg) Seamless Cooperation of Java and Prolog 04.08.2015
![Page 59: Doctoral Consortium@RuleML2015: Seamless Cooperation of JAVA and PROLOG for Rule-Based Software Development](https://reader031.vdocuments.net/reader031/viewer/2022032513/55d28754bb61eb9e618b45b4/html5/thumbnails/59.jpg)
Components of Capja
JPLambda
concise and readable Prolog queries in Java
based on Java Lambda expressions
code as data
Lambda expression to further narrow the result set
the Lambda’s evaluation is transferred (where possible) to Prolog
Ludwig Ostermayer (University of Wurzburg) Seamless Cooperation of Java and Prolog 04.08.2015
![Page 60: Doctoral Consortium@RuleML2015: Seamless Cooperation of JAVA and PROLOG for Rule-Based Software Development](https://reader031.vdocuments.net/reader031/viewer/2022032513/55d28754bb61eb9e618b45b4/html5/thumbnails/60.jpg)
Limitations
What Capja (currently) can’t do for you...
support for queries from Prolog to Java (upcoming)
concurrency management
Ludwig Ostermayer (University of Wurzburg) Seamless Cooperation of Java and Prolog 04.08.2015
![Page 61: Doctoral Consortium@RuleML2015: Seamless Cooperation of JAVA and PROLOG for Rule-Based Software Development](https://reader031.vdocuments.net/reader031/viewer/2022032513/55d28754bb61eb9e618b45b4/html5/thumbnails/61.jpg)
Limitations
What Capja (currently) can’t do for you...
support for queries from Prolog to Java (upcoming)
concurrency management
Ludwig Ostermayer (University of Wurzburg) Seamless Cooperation of Java and Prolog 04.08.2015
![Page 62: Doctoral Consortium@RuleML2015: Seamless Cooperation of JAVA and PROLOG for Rule-Based Software Development](https://reader031.vdocuments.net/reader031/viewer/2022032513/55d28754bb61eb9e618b45b4/html5/thumbnails/62.jpg)
Limitations
What Capja (currently) can’t do for you...
support for queries from Prolog to Java (upcoming)
concurrency management
Ludwig Ostermayer (University of Wurzburg) Seamless Cooperation of Java and Prolog 04.08.2015
![Page 63: Doctoral Consortium@RuleML2015: Seamless Cooperation of JAVA and PROLOG for Rule-Based Software Development](https://reader031.vdocuments.net/reader031/viewer/2022032513/55d28754bb61eb9e618b45b4/html5/thumbnails/63.jpg)
Experiments
Case Studies
knowledge bases (e-commerce)
graphs (metro systems)
planning (logistics)
Results
simple and clean code
up to 50% less lines of code (loc) as with pure Java
up to 25% less loc compared to an implementation with Jpl
better or (at least) comparable performance compared to formerapproaches
Ludwig Ostermayer (University of Wurzburg) Seamless Cooperation of Java and Prolog 04.08.2015
![Page 64: Doctoral Consortium@RuleML2015: Seamless Cooperation of JAVA and PROLOG for Rule-Based Software Development](https://reader031.vdocuments.net/reader031/viewer/2022032513/55d28754bb61eb9e618b45b4/html5/thumbnails/64.jpg)
Experiments
Case Studies
knowledge bases (e-commerce)
graphs (metro systems)
planning (logistics)
Results
simple and clean code
up to 50% less lines of code (loc) as with pure Java
up to 25% less loc compared to an implementation with Jpl
better or (at least) comparable performance compared to formerapproaches
Ludwig Ostermayer (University of Wurzburg) Seamless Cooperation of Java and Prolog 04.08.2015
![Page 65: Doctoral Consortium@RuleML2015: Seamless Cooperation of JAVA and PROLOG for Rule-Based Software Development](https://reader031.vdocuments.net/reader031/viewer/2022032513/55d28754bb61eb9e618b45b4/html5/thumbnails/65.jpg)
Experiments
Case Studies
knowledge bases (e-commerce)
graphs (metro systems)
planning (logistics)
Results
simple and clean code
up to 50% less lines of code (loc) as with pure Java
up to 25% less loc compared to an implementation with Jpl
better or (at least) comparable performance compared to formerapproaches
Ludwig Ostermayer (University of Wurzburg) Seamless Cooperation of Java and Prolog 04.08.2015
![Page 66: Doctoral Consortium@RuleML2015: Seamless Cooperation of JAVA and PROLOG for Rule-Based Software Development](https://reader031.vdocuments.net/reader031/viewer/2022032513/55d28754bb61eb9e618b45b4/html5/thumbnails/66.jpg)
Experiments
Case Studies
knowledge bases (e-commerce)
graphs (metro systems)
planning (logistics)
Results
simple and clean code
up to 50% less lines of code (loc) as with pure Java
up to 25% less loc compared to an implementation with Jpl
better or (at least) comparable performance compared to formerapproaches
Ludwig Ostermayer (University of Wurzburg) Seamless Cooperation of Java and Prolog 04.08.2015
![Page 67: Doctoral Consortium@RuleML2015: Seamless Cooperation of JAVA and PROLOG for Rule-Based Software Development](https://reader031.vdocuments.net/reader031/viewer/2022032513/55d28754bb61eb9e618b45b4/html5/thumbnails/67.jpg)
Experiments
Case Studies
knowledge bases (e-commerce)
graphs (metro systems)
planning (logistics)
Results
simple and clean code
up to 50% less lines of code (loc) as with pure Java
up to 25% less loc compared to an implementation with Jpl
better or (at least) comparable performance compared to formerapproaches
Ludwig Ostermayer (University of Wurzburg) Seamless Cooperation of Java and Prolog 04.08.2015
![Page 68: Doctoral Consortium@RuleML2015: Seamless Cooperation of JAVA and PROLOG for Rule-Based Software Development](https://reader031.vdocuments.net/reader031/viewer/2022032513/55d28754bb61eb9e618b45b4/html5/thumbnails/68.jpg)
Experiments
Case Studies
knowledge bases (e-commerce)
graphs (metro systems)
planning (logistics)
Results
simple and clean code
up to 50% less lines of code (loc) as with pure Java
up to 25% less loc compared to an implementation with Jpl
better or (at least) comparable performance compared to formerapproaches
Ludwig Ostermayer (University of Wurzburg) Seamless Cooperation of Java and Prolog 04.08.2015
![Page 69: Doctoral Consortium@RuleML2015: Seamless Cooperation of JAVA and PROLOG for Rule-Based Software Development](https://reader031.vdocuments.net/reader031/viewer/2022032513/55d28754bb61eb9e618b45b4/html5/thumbnails/69.jpg)
Experiments
Case Studies
knowledge bases (e-commerce)
graphs (metro systems)
planning (logistics)
Results
simple and clean code
up to 50% less lines of code (loc) as with pure Java
up to 25% less loc compared to an implementation with Jpl
better or (at least) comparable performance compared to formerapproaches
Ludwig Ostermayer (University of Wurzburg) Seamless Cooperation of Java and Prolog 04.08.2015
![Page 70: Doctoral Consortium@RuleML2015: Seamless Cooperation of JAVA and PROLOG for Rule-Based Software Development](https://reader031.vdocuments.net/reader031/viewer/2022032513/55d28754bb61eb9e618b45b4/html5/thumbnails/70.jpg)
Thanks for the Attention!
Questions are welcome!
Ludwig Ostermayer (University of Wurzburg) Seamless Cooperation of Java and Prolog 04.08.2015
![Page 71: Doctoral Consortium@RuleML2015: Seamless Cooperation of JAVA and PROLOG for Rule-Based Software Development](https://reader031.vdocuments.net/reader031/viewer/2022032513/55d28754bb61eb9e618b45b4/html5/thumbnails/71.jpg)
Talk is cheap. Show me the Code.2
A Person class with two different Prolog-Views...
1 @PlView(viewId="V1", dropArgs={"familyName"},2 modifyArgs={@PlArg(valueOf="children",viewId="V2")})3 @PlView(viewId="V2", functor="child",4 orderArgs={"firstName"})5 class Person {6 private String firstName;7 private String familyName;8 private int age;9 private ArrayList<Person> children;
10 //...constructors and methods...11 }
... and its corresponding PVN representation.
1 pl_view(person, compound, [pl_arg(firstName, string),2 pl_arg(familyName, string), pl_arg(age, int),3 pl_arg(children, arrayList, person)]).
2Linus Torvald
Ludwig Ostermayer (University of Wurzburg) Seamless Cooperation of Java and Prolog 04.08.2015
![Page 72: Doctoral Consortium@RuleML2015: Seamless Cooperation of JAVA and PROLOG for Rule-Based Software Development](https://reader031.vdocuments.net/reader031/viewer/2022032513/55d28754bb61eb9e618b45b4/html5/thumbnails/72.jpg)
Talk is cheap. Show me the Code.2
A Person class with two different Prolog-Views...
1 @PlView(viewId="V1", dropArgs={"familyName"},2 modifyArgs={@PlArg(valueOf="children",viewId="V2")})3 @PlView(viewId="V2", functor="child",4 orderArgs={"firstName"})5 class Person {6 private String firstName;7 private String familyName;8 private int age;9 private ArrayList<Person> children;
10 //...constructors and methods...11 }
... and its corresponding PVN representation.
1 pl_view(person, compound, [pl_arg(firstName, string),2 pl_arg(familyName, string), pl_arg(age, int),3 pl_arg(children, arrayList, person)]).
2Linus Torvald
Ludwig Ostermayer (University of Wurzburg) Seamless Cooperation of Java and Prolog 04.08.2015
![Page 73: Doctoral Consortium@RuleML2015: Seamless Cooperation of JAVA and PROLOG for Rule-Based Software Development](https://reader031.vdocuments.net/reader031/viewer/2022032513/55d28754bb61eb9e618b45b4/html5/thumbnails/73.jpg)
Talk is cheap. Show me the Code.2
A Person class with two different Prolog-Views...
1 @PlView(viewId="V1", dropArgs={"familyName"},2 modifyArgs={@PlArg(valueOf="children",viewId="V2")})3 @PlView(viewId="V2", functor="child",4 orderArgs={"firstName"})5 class Person {6 private String firstName;7 private String familyName;8 private int age;9 private ArrayList<Person> children;
10 //...constructors and methods...11 }
... and its corresponding PVN representation.
1 pl_view(person, compound, [pl_arg(firstName, string),2 pl_arg(familyName, string), pl_arg(age, int),3 pl_arg(children, arrayList, person)]).
2Linus Torvald
Ludwig Ostermayer (University of Wurzburg) Seamless Cooperation of Java and Prolog 04.08.2015
![Page 74: Doctoral Consortium@RuleML2015: Seamless Cooperation of JAVA and PROLOG for Rule-Based Software Development](https://reader031.vdocuments.net/reader031/viewer/2022032513/55d28754bb61eb9e618b45b4/html5/thumbnails/74.jpg)
Talk is cheap. Show me the Code.2
A Person class with two different Prolog-Views...
1 @PlView(viewId="V1", dropArgs={"familyName"},2 modifyArgs={@PlArg(valueOf="children",viewId="V2")})3 @PlView(viewId="V2", functor="child",4 orderArgs={"firstName"})5 class Person {6 private String firstName;7 private String familyName;8 private int age;9 private ArrayList<Person> children;
10 //...constructors and methods...11 }
... and its corresponding PVN representation.
1 pl_view(person, compound, [pl_arg(firstName, string),2 pl_arg(familyName, string), pl_arg(age, int),3 pl_arg(children, arrayList, person)]).
2Linus Torvald
Ludwig Ostermayer (University of Wurzburg) Seamless Cooperation of Java and Prolog 04.08.2015
![Page 75: Doctoral Consortium@RuleML2015: Seamless Cooperation of JAVA and PROLOG for Rule-Based Software Development](https://reader031.vdocuments.net/reader031/viewer/2022032513/55d28754bb61eb9e618b45b4/html5/thumbnails/75.jpg)
Talk is cheap. Show me the Code.2
A Person class with two different Prolog-Views...
1 @PlView(viewId="V1", dropArgs={"familyName"},2 modifyArgs={@PlArg(valueOf="children",viewId="V2")})3 @PlView(viewId="V2", functor="child",4 orderArgs={"firstName"})5 class Person {6 private String firstName;7 private String familyName;8 private int age;9 private ArrayList<Person> children;
10 //...constructors and methods...11 }
... and its corresponding PVN representation.
1 pl_view(person, compound, [pl_arg(firstName, string),2 pl_arg(familyName, string), pl_arg(age, int),3 pl_arg(children, arrayList, person)]).
2Linus Torvald
Ludwig Ostermayer (University of Wurzburg) Seamless Cooperation of Java and Prolog 04.08.2015
![Page 76: Doctoral Consortium@RuleML2015: Seamless Cooperation of JAVA and PROLOG for Rule-Based Software Development](https://reader031.vdocuments.net/reader031/viewer/2022032513/55d28754bb61eb9e618b45b4/html5/thumbnails/76.jpg)
Some objects...
1 Person homer = new Person("Homer", null, 40);2 Person bart = new Person("Bart", "Stimpson", 10);3 homer.getChildren().add(bart);
...that we map via the otm to terms...
1 % default mapping of homer2 person('Homer', X, 40, [person('Bart',10,[])]).3 % the Prolog-View "V1" of homer4 person('Homer', 40, [child('Bart')]).
... and that can be queried using a JPLambda.
1 Unifier<Person> personUnifier = new Unifier$3141<>(2 person -> person.getFamilyName() == "Stimpson"3 && person.getAge() < 18);4 //person(FirstName, 'Stimpson', Age, Children), Age < 185 Iterator<Person> personIt1 = personUnifier.unify();6 Iterator<Person> personIt2 = personUnifier.findall();
Ludwig Ostermayer (University of Wurzburg) Seamless Cooperation of Java and Prolog 04.08.2015
![Page 77: Doctoral Consortium@RuleML2015: Seamless Cooperation of JAVA and PROLOG for Rule-Based Software Development](https://reader031.vdocuments.net/reader031/viewer/2022032513/55d28754bb61eb9e618b45b4/html5/thumbnails/77.jpg)
Some objects...
1 Person homer = new Person("Homer", null, 40);2 Person bart = new Person("Bart", "Stimpson", 10);3 homer.getChildren().add(bart);
...that we map via the otm to terms...
1 % default mapping of homer2 person('Homer', X, 40, [person('Bart',10,[])]).3 % the Prolog-View "V1" of homer4 person('Homer', 40, [child('Bart')]).
... and that can be queried using a JPLambda.
1 Unifier<Person> personUnifier = new Unifier$3141<>(2 person -> person.getFamilyName() == "Stimpson"3 && person.getAge() < 18);4 //person(FirstName, 'Stimpson', Age, Children), Age < 185 Iterator<Person> personIt1 = personUnifier.unify();6 Iterator<Person> personIt2 = personUnifier.findall();
Ludwig Ostermayer (University of Wurzburg) Seamless Cooperation of Java and Prolog 04.08.2015
![Page 78: Doctoral Consortium@RuleML2015: Seamless Cooperation of JAVA and PROLOG for Rule-Based Software Development](https://reader031.vdocuments.net/reader031/viewer/2022032513/55d28754bb61eb9e618b45b4/html5/thumbnails/78.jpg)
Some objects...
1 Person homer = new Person("Homer", null, 40);2 Person bart = new Person("Bart", "Stimpson", 10);3 homer.getChildren().add(bart);
...that we map via the otm to terms...
1 % default mapping of homer2 person('Homer', X, 40, [person('Bart',10,[])]).3 % the Prolog-View "V1" of homer4 person('Homer', 40, [child('Bart')]).
... and that can be queried using a JPLambda.
1 Unifier<Person> personUnifier = new Unifier$3141<>(2 person -> person.getFamilyName() == "Stimpson"3 && person.getAge() < 18);4 //person(FirstName, 'Stimpson', Age, Children), Age < 185 Iterator<Person> personIt1 = personUnifier.unify();6 Iterator<Person> personIt2 = personUnifier.findall();
Ludwig Ostermayer (University of Wurzburg) Seamless Cooperation of Java and Prolog 04.08.2015
![Page 79: Doctoral Consortium@RuleML2015: Seamless Cooperation of JAVA and PROLOG for Rule-Based Software Development](https://reader031.vdocuments.net/reader031/viewer/2022032513/55d28754bb61eb9e618b45b4/html5/thumbnails/79.jpg)
Some objects...
1 Person homer = new Person("Homer", null, 40);2 Person bart = new Person("Bart", "Stimpson", 10);3 homer.getChildren().add(bart);
...that we map via the otm to terms...
1 % default mapping of homer2 person('Homer', X, 40, [person('Bart',10,[])]).3 % the Prolog-View "V1" of homer4 person('Homer', 40, [child('Bart')]).
... and that can be queried using a JPLambda.
1 Unifier<Person> personUnifier = new Unifier$3141<>(2 person -> person.getFamilyName() == "Stimpson"3 && person.getAge() < 18);4 //person(FirstName, 'Stimpson', Age, Children), Age < 185 Iterator<Person> personIt1 = personUnifier.unify();6 Iterator<Person> personIt2 = personUnifier.findall();
Ludwig Ostermayer (University of Wurzburg) Seamless Cooperation of Java and Prolog 04.08.2015
![Page 80: Doctoral Consortium@RuleML2015: Seamless Cooperation of JAVA and PROLOG for Rule-Based Software Development](https://reader031.vdocuments.net/reader031/viewer/2022032513/55d28754bb61eb9e618b45b4/html5/thumbnails/80.jpg)
Some objects...
1 Person homer = new Person("Homer", null, 40);2 Person bart = new Person("Bart", "Stimpson", 10);3 homer.getChildren().add(bart);
...that we map via the otm to terms...
1 % default mapping of homer2 person('Homer', X, 40, [person('Bart',10,[])]).3 % the Prolog-View "V1" of homer4 person('Homer', 40, [child('Bart')]).
... and that can be queried using a JPLambda.
1 Unifier<Person> personUnifier = new Unifier$3141<>(2 person -> person.getFamilyName() == "Stimpson"3 && person.getAge() < 18);4 //person(FirstName, 'Stimpson', Age, Children), Age < 185 Iterator<Person> personIt1 = personUnifier.unify();6 Iterator<Person> personIt2 = personUnifier.findall();
Ludwig Ostermayer (University of Wurzburg) Seamless Cooperation of Java and Prolog 04.08.2015
![Page 81: Doctoral Consortium@RuleML2015: Seamless Cooperation of JAVA and PROLOG for Rule-Based Software Development](https://reader031.vdocuments.net/reader031/viewer/2022032513/55d28754bb61eb9e618b45b4/html5/thumbnails/81.jpg)
Some objects...
1 Person homer = new Person("Homer", null, 40);2 Person bart = new Person("Bart", "Stimpson", 10);3 homer.getChildren().add(bart);
...that we map via the otm to terms...
1 % default mapping of homer2 person('Homer', X, 40, [person('Bart',10,[])]).3 % the Prolog-View "V1" of homer4 person('Homer', 40, [child('Bart')]).
... and that can be queried using a JPLambda.
1 Unifier<Person> personUnifier = new Unifier$3141<>(2 person -> person.getFamilyName() == "Stimpson"3 && person.getAge() < 18);4 //person(FirstName, 'Stimpson', Age, Children), Age < 185 Iterator<Person> personIt1 = personUnifier.unify();6 Iterator<Person> personIt2 = personUnifier.findall();
Ludwig Ostermayer (University of Wurzburg) Seamless Cooperation of Java and Prolog 04.08.2015