QEP
Keywords: uk.ac.ic.doc.rodex.p2p.protocol.QEP class

Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## uk.ac.ic.doc.rodex.p2p.protocol
Class QEP

    java.lang.Object
      uk.ac.ic.doc.rodex.p2p.protocol.QEP

    public class QEP

extends java.lang.Object

Method Summary
`boolean` | `checkQualityIndicator(QueryDescription qd)` Check if query execution can meet the expected quality indicator
`static ASG` | `deserialiseASG(Root asgXML)` Deserialise an ASG from its XML representation
`AbstractMessage` | `executeQuery(AbstractMessage request)` Execute query and return result (server-side).
`static QEP` | `getQEPInstance(AutoMedPeer mainPeer)` Return a single QEP instance per JVM
`void` | `replySODefinition(AbstractMessage request, ResponseHandler outputHandler)` Look up the definition queries for a schema object and return it to the requesting peer.
`void` | `requestSODefinition(QuerySubGoal qsg, AutoMedPeer.PeerProcessDescription destPeer)` Request the query definitions for a schema object (represented by a `QuerySubGoal` object
`AbstractMessage` | `sendQuery(QueryDescription queryDesc, AutoMedPeer.PeerProcessDescription destPeer)` Send a query to the network for execution (client-side)
`static Root` | `serialiseASG(ASG q)` Serialise an ASG query into XML representation
`static Root` | `serialiseASG(java.util.List asgs)` Serialise an ASG query into XML representation

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Method Detail

### getQEPInstance

    public static QEP getQEPInstance(AutoMedPeer mainPeer)

  Return a single QEP instance per JVM

### sendQuery

    public AbstractMessage sendQuery(QueryDescription queryDesc,
                                     AutoMedPeer.PeerProcessDescription destPeer)
                              throws CommunicationException,
                                     AutoMedException

  Send a query to the network for execution (client-side)

  Parameters:
    `queryDesc` - a `QueryDescription` object of the query to be sent
    `destPeer` - a `AutoMedPeer.PeerProcessDescription` object of the destination peer to which the query is sent
  Returns:
    `AbstractMessage` result of query execution
  Throws:
    `CommunicationException`
    `AutoMedException`

### serialiseASG

    public static Root serialiseASG(ASG q)
                             throws AutoMedTreeException

  Serialise an ASG query into XML representation

  Throws:
    `AutoMedTreeException`

### serialiseASG

    public static Root serialiseASG(java.util.List asgs)
                             throws AutoMedTreeException

  Serialise an ASG query into XML representation

  Throws:
    `AutoMedTreeException`

### deserialiseASG

    public static ASG deserialiseASG(Root asgXML)
                              throws AutoMedTreeException

  Deserialise an ASG from its XML representation

  Throws:
    `AutoMedTreeException`

### executeQuery

    public AbstractMessage executeQuery(AbstractMessage request)

  Execute query and return result (server-side).

  Parameters:
    `request` - `AbstractMessage` received from the network
  Returns:
    `AbstractMessage` the message to send back to client

### requestSODefinition

    public void requestSODefinition(QuerySubGoal qsg,
                                    AutoMedPeer.PeerProcessDescription destPeer)
                             throws CommunicationException,
                                    UnsuccessfulReplyException

  Request the query definitions for a schema object (represented by a `QuerySubGoal` object

  Throws:
    `CommunicationException`
    `UnsuccessfulReplyException`

### replySODefinition

    public void replySODefinition(AbstractMessage request,
                                  ResponseHandler outputHandler)
                           throws CommunicationException

  Look up the definition queries for a schema object and return it to the requesting peer.

  Throws:
    `CommunicationException`

### checkQualityIndicator

    public boolean checkQualityIndicator(QueryDescription qd)
                                  throws AutoMedException

  Check if query execution can meet the expected quality indicator

  Throws:
    `AutoMedException`

Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD