Copyright 2004 Digital Enterprise Research Institute. All rights reserved. WSMO4J – Logical Expression Extension
Background WSMO4J captures WSMO meta model and concrete language WSML (v0.2) Generic model (concepts, attributes, relations, (pre/post)-conditions,...) can be refined by logical expressions Current Status: in WSMO4J object model for logical expression: java.lang.String Reasoning, logical processing require object model –Rewriting into other logical languages –Wrapper for reasoners –Manipulation on object level (i.e. By tools)
Logical Expression Object Model Simplicity Implementation not yet optimized Basic Idea: –getOperator() –getArgument() Example: –a and c[atr hasValue val] LogicalExpression getOperator(): AND getArit(): 2 getArgument(1): Atom (a) getArgument(2): Molecule (c[atr hasValue val])
Integration with WSMO4J – Terms (I) How does logexp extension integrate with the Objects / Identifiers? –Logic view on model requires: everything is a term –WSMO API has more restrictive view (concepts must be identified by IRI/Anonymous IDs) –E.g.: _date(2005,10,10) memberOf somethingElse is perfactly valid within logexp, but not in WSMO4J subclassing the relevant classes and let them inherit from org.wsmo.common.xyz;
Integration with WSMO4J – Terms (II)
Summary Logical Expression API is an extension to WSMO-API (and implementation) Users can switch „transparently“ between viewing them as strings or as object models Can be used to translate to different formalisms / reasoners Available: –Snapshot: –SourceCode: ext directoy of wsmo4j
Backup: Code example use it „transparently“ in WSMO4J //create a logicalexpressionfactory: HashMap params = new HashMap(); params.put(Factory.PROVIDER_CLASS, "org.deri.wsmo4j.logexpression.LogicalExpressionFactoryImpl"); LogicalExpressionFactory _leFactory = (LogicalExpressionFactory) Factory.createLogicalExpressionFactory(createParams); //use this _leFactory as replacement with standard factory: params = new HashMap(); params.put(Parser.PARSER_WSMO_FACTORY, Factory.createWsmoFactory(null)); params.put(Parser.PARSER_LE_FACTORY, _leFactory); Parser p = Factory.createParser(params);