Java Doc for DIGConnection.java in  » RSS-RDF » Jena-2.5.5 » com » hp » hpl » jena » reasoner » dig » 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 » RSS RDF » Jena 2.5.5 » com.hp.hpl.jena.reasoner.dig 
Source Cross Reference  Class Diagram Java Document (Java Doc) 


java.lang.Object
   com.hp.hpl.jena.reasoner.dig.DIGConnection

DIGConnection
public class DIGConnection (Code)

Encapsulates the connection to a DIG reasoner.


author:
   Ian Dickinson, HP Labs (email)
version:
   Release @release@ ($Id: DIGConnection.java,v 1.16 2008/01/02 12:07:11 andy_seaborne Exp $)


Field Summary
final public static  StringDEFAULT_REASONER_URL
    
final public static  StringXSI
    
protected  Stringm_extReasonerURL
    
protected  DocumentBuilderFactorym_factory
    
protected  booleanm_logCommunications
    


Method Summary
public  voidbindKB(boolean rebind, DIGProfile profile)
    

Bind a DIG KB to this adapter, by requesting a KB URI through the newKB verb.

protected  DocumentcreateDigVerb(String verbName, DIGProfile profile)
    
protected  OutputFormatcreateXMLFormatter(Document doc)
    
public  voiderrorCheck(Document response, DIGProfile profile)
    
protected  DocumentgetDigResponse(HttpURLConnection conn)
    
public  StringgetReasonerURL()
    
public  IteratorgetWarnings()
    
protected  voidlogMessage(boolean outgoing, Document msg)
    
public  voidrelease()
    
public  DocumentsendDigVerb(Document digVerb, DIGProfile profile)
    

Send a verb to the attached DIG reasoner and answer the result.

public  voidserialiseDocument(Document doc, Writer out)
    
public  voidsetReasonerURL(String url)
    
public  booleanwarningCheck(Document response)
    

Field Detail
DEFAULT_REASONER_URL
final public static String DEFAULT_REASONER_URL(Code)
Default URL for connecting to a local DIG reasoner on port 8081



XSI
final public static String XSI(Code)
Namespace for XSI



m_extReasonerURL
protected String m_extReasonerURL(Code)
The URL to connect to, initialised to the default URL



m_factory
protected DocumentBuilderFactory m_factory(Code)
The XML document builder we are using



m_logCommunications
protected boolean m_logCommunications(Code)
Flag to control whether we log incoming and outgoing messages





Method Detail
bindKB
public void bindKB(boolean rebind, DIGProfile profile)(Code)

Bind a DIG KB to this adapter, by requesting a KB URI through the newKB verb. If there is already a binding, do nothing unless rebind is true.
Parameters:
  rebind - If true, any existing KB will be released before bindingto a new KB




createDigVerb
protected Document createDigVerb(String verbName, DIGProfile profile)(Code)

Create a DIG verb as an xml element in a new document object.


Parameters:
  verbName - The name of the DIG verb, as a string An XML DOM element representing the DIG verb



createXMLFormatter
protected OutputFormat createXMLFormatter(Document doc)(Code)

Answer an XML formatter object for the given document
Parameters:
  doc - The XML document to be serialised An XML formatter object for the document




errorCheck
public void errorCheck(Document response, DIGProfile profile)(Code)

Check the response from the DIG server to see if there is an error code, and raise an excption if so.


Parameters:
  response - The response from the DIG server



getDigResponse
protected Document getDigResponse(HttpURLConnection conn)(Code)

Answer the XML document object that resulted from the most recent request.


Parameters:
  conn - The current HTTP connection The response from the DIG reasoner, as an XML object
exception:
  DigReasonerException - if the underling connection or XML parser raisesan error.



getReasonerURL
public String getReasonerURL()(Code)

Answer the URL of the external reasoner this connection is bound to.

The current external reasoner URL



getWarnings
public Iterator getWarnings()(Code)

Answer an iterator over the warnings received since the last tell operation

An iterator over warnings



logMessage
protected void logMessage(boolean outgoing, Document msg)(Code)

Log the messages going to and from DIG


Parameters:
  outgoing - True for send, false for receive
Parameters:
  msg - The document sent or received.



release
public void release()(Code)

Release this connection back to the connection pool.




sendDigVerb
public Document sendDigVerb(Document digVerb, DIGProfile profile)(Code)

Send a verb to the attached DIG reasoner and answer the result. The verb is encoded as an XML document object.


Parameters:
  digVerb - A DIG verb (information request, ask or tell) as an XML document The resulting XML document formed from the response from the reasoner
exception:
  DigReasonerException - for any errors in XML encoding or HTTP transmission



serialiseDocument
public void serialiseDocument(Document doc, Writer out)(Code)

Serialise the given document to the given output writer.


Parameters:
  doc - An XML document to serialise
Parameters:
  out - A writer that will consume the seralised form of the document



setReasonerURL
public void setReasonerURL(String url)(Code)

Set the URL of the external reasoner with which this connection communicates.


Parameters:
  url - The URL of the new external reasoner connection point



warningCheck
public boolean warningCheck(Document response)(Code)

Append any warning messages from this response to the list of recent warnings, which is first cleared.


Parameters:
  response - The response from the DIG server True if any warnings were detected.



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.