Package com.betfair.cougar.transport.api.protocol.http.soap

Examples of com.betfair.cougar.transport.api.protocol.http.soap.SoapIdentityTokenResolver


        }
    }

    private void writeHeaders(final SOAPFactory factory, final SOAPHeader header, HttpCommand command, ExecutionContextWithTokens context)
            throws Exception {
        final SoapIdentityTokenResolver identityTokenResolver = (SoapIdentityTokenResolver) command.getIdentityTokenResolver();
        if (context != null && context.getIdentity() != null && identityTokenResolver != null) {

            writeIdentity(context.getIdentityTokens(), new IdentityTokenIOAdapter() {
                @Override
                public void rewriteIdentityTokens(List<IdentityToken> identityTokens) {
                    OMElement element = header.addHeaderBlock(SECURITY_CREDENTIALS, factory.createOMNamespace(SECURITY_NAMESPACE, SECURITY_PREFIX));
                    identityTokenResolver.rewrite(identityTokens, element);
                }

                @Override
                public boolean isRewriteSupported() {
                    return identityTokenResolver.isRewriteSupported();
                }
            });
        }
    }
View Full Code Here


        }
    }

    private void writeHeaders(final SOAPFactory factory, final SOAPHeader header, HttpCommand command, ExecutionContextWithTokens context)
            throws Exception {
        final SoapIdentityTokenResolver identityTokenResolver = (SoapIdentityTokenResolver) command.getIdentityTokenResolver();
        if (context != null && context.getIdentity() != null && identityTokenResolver != null) {

            writeIdentity(context.getIdentityTokens(), new IdentityTokenIOAdapter() {
                @Override
                public void rewriteIdentityTokens(List<IdentityToken> identityTokens) {
                    OMElement element = header.addHeaderBlock(SECURITY_CREDENTIALS, factory.createOMNamespace(SECURITY_NAMESPACE, SECURITY_PREFIX));
                    identityTokenResolver.rewrite(identityTokens, element);
                }

                @Override
                public boolean isRewriteSupported() {
                    return identityTokenResolver.isRewriteSupported();
                }
            });
        }
    }
View Full Code Here

TOP

Related Classes of com.betfair.cougar.transport.api.protocol.http.soap.SoapIdentityTokenResolver

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.