Interface IPolicyWrapper

All Known Subinterfaces:
All Known Implementing Classes:
Policy, PolicyWrapper

public interface IPolicyWrapper

A Policy Wrapper is a bundle of policies that can be sent/posted as one object to the openSSO server.

Pantelis Sopasakis, Charalampos Chomenides

Method Summary
 Document getDocument()
 String getText()
 int publish(VRI policyServer, AuthenticationToken token)
          Publish this policy to a remote server and acquire a URI for it.

Method Detail


Document getDocument()


String getText()


int publish(VRI policyServer,
            AuthenticationToken token)
            throws ServiceInvocationException
Publish this policy to a remote server and acquire a URI for it.

policyServer - URI of the policy server. If set to null then the standard policy service of OpenTox at will be used instead.
token - Token used to authenticate the user that attempts to publish a new policy against the policy service. If you think that no authentication is needed to perform the HTTP request you may set it to null.
Server's response message
ToxOtisException - In case a HTTP related error occurs (I/O communication error, or the remote server is down), the service respondes in an unexpected manner like a status code 500 or 503 or authentication/authorization fails and a status code 403 or 401 are returned respectively.
InactiveTokenException - If the token the user uses is not active (because it has been invalidated, expired, or not initialized yet).

Copyright © 2011-2012 OpenTox. All Rights Reserved.