当前位置: 首页>>代码示例>>Java>>正文


Java AuthenticatingAuthority类代码示例

本文整理汇总了Java中org.opensaml.saml2.core.AuthenticatingAuthority的典型用法代码示例。如果您正苦于以下问题:Java AuthenticatingAuthority类的具体用法?Java AuthenticatingAuthority怎么用?Java AuthenticatingAuthority使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。


AuthenticatingAuthority类属于org.opensaml.saml2.core包,在下文中一共展示了AuthenticatingAuthority类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: testChildElementsMarshall

import org.opensaml.saml2.core.AuthenticatingAuthority; //导入依赖的package包/类
/** {@inheritDoc} */
public void testChildElementsMarshall() {
    QName qname = new QName(SAMLConstants.SAML20_NS, AuthnContext.DEFAULT_ELEMENT_LOCAL_NAME, SAMLConstants.SAML20_PREFIX);
    AuthnContext authnContext = (AuthnContext) buildXMLObject(qname);

    QName authnContextClassRefQName = new QName(SAMLConstants.SAML20_NS, AuthnContextClassRef.DEFAULT_ELEMENT_LOCAL_NAME, SAMLConstants.SAML20_PREFIX);
    authnContext.setAuthnContextClassRef((AuthnContextClassRef) buildXMLObject(authnContextClassRefQName));
    
    QName authnContextDeclQName = new QName(SAMLConstants.SAML20_NS, AuthnContextDecl.DEFAULT_ELEMENT_LOCAL_NAME, SAMLConstants.SAML20_PREFIX);
    authnContext.setAuthnContextDecl((AuthnContextDecl) buildXMLObject(authnContextDeclQName));
    
    QName authnContextDeclRefQName = new QName(SAMLConstants.SAML20_NS, AuthnContextDeclRef.DEFAULT_ELEMENT_LOCAL_NAME, SAMLConstants.SAML20_PREFIX);
    authnContext.setAuthnContextDeclRef((AuthnContextDeclRef) buildXMLObject(authnContextDeclRefQName));
    
    QName authenticatingAuthorityQName = new QName(SAMLConstants.SAML20_NS, AuthenticatingAuthority.DEFAULT_ELEMENT_LOCAL_NAME, SAMLConstants.SAML20_PREFIX);
    for (int i = 0; i < expectedAuthenticatingAuthorityCount; i++) {
        authnContext.getAuthenticatingAuthorities().add((AuthenticatingAuthority) buildXMLObject(authenticatingAuthorityQName));
    }

    assertEquals(expectedChildElementsDOM, authnContext);
}
 
开发者ID:apigee,项目名称:java-opensaml2,代码行数:22,代码来源:AuthnContextTest.java

示例2: processChildElement

import org.opensaml.saml2.core.AuthenticatingAuthority; //导入依赖的package包/类
/** {@inheritDoc} */
protected void processChildElement(XMLObject parentObject, XMLObject childObject) throws UnmarshallingException {
    AuthnContext authnContext = (AuthnContext) parentObject;
    if (childObject instanceof AuthnContextClassRef) {
        authnContext.setAuthnContextClassRef((AuthnContextClassRef) childObject);
    } else if (childObject instanceof AuthnContextDecl) {
        authnContext.setAuthnContextDecl((AuthnContextDecl) childObject);
    } else if (childObject instanceof AuthnContextDeclRef) {
        authnContext.setAuthnContextDeclRef((AuthnContextDeclRef) childObject);
    } else if (childObject instanceof AuthenticatingAuthority) {
        authnContext.getAuthenticatingAuthorities().add((AuthenticatingAuthority) childObject);
    } else {
        super.processChildElement(parentObject, childObject);
    }
}
 
开发者ID:lamsfoundation,项目名称:lams,代码行数:16,代码来源:AuthnContextUnmarshaller.java

示例3: testURIFailure

import org.opensaml.saml2.core.AuthenticatingAuthority; //导入依赖的package包/类
/**
 * Tests absent URI failure.
 * 
 * @throws ValidationException
 */
public void testURIFailure() throws ValidationException {
    AuthenticatingAuthority authenticatingAuthority = (AuthenticatingAuthority) target;

    authenticatingAuthority.setURI(null);
    assertValidationFail("URI was null, should raise a Validation Exception");

    authenticatingAuthority.setURI("");
    assertValidationFail("URI was empty string, should raise a Validation Exception");
    
    authenticatingAuthority.setURI("    ");
    assertValidationFail("URI was white space, should raise a Validation Exception");
}
 
开发者ID:apigee,项目名称:java-opensaml2,代码行数:18,代码来源:AuthenticatingAuthoritySchemaTest.java

示例4: testSingleElementUnmarshall

import org.opensaml.saml2.core.AuthenticatingAuthority; //导入依赖的package包/类
/** {@inheritDoc} */
public void testSingleElementUnmarshall() {
    AuthenticatingAuthority authenticatingAuthority = (AuthenticatingAuthority) unmarshallElement(singleElementFile);

    String assertionURI = authenticatingAuthority.getURI();
    assertEquals("URI was " + assertionURI + ", expected " + expectedURI, expectedURI, assertionURI);
}
 
开发者ID:apigee,项目名称:java-opensaml2,代码行数:8,代码来源:AuthenticatingAuthorityTest.java

示例5: testSingleElementMarshall

import org.opensaml.saml2.core.AuthenticatingAuthority; //导入依赖的package包/类
/** {@inheritDoc} */
public void testSingleElementMarshall() {
    QName qname = new QName(SAMLConstants.SAML20_NS, AuthenticatingAuthority.DEFAULT_ELEMENT_LOCAL_NAME,
            SAMLConstants.SAML20_PREFIX);
    AuthenticatingAuthority authenticatingAuthority = (AuthenticatingAuthority) buildXMLObject(qname);

    authenticatingAuthority.setURI(expectedURI);
    assertEquals(expectedDOM, authenticatingAuthority);

}
 
开发者ID:apigee,项目名称:java-opensaml2,代码行数:11,代码来源:AuthenticatingAuthorityTest.java

示例6: validate

import org.opensaml.saml2.core.AuthenticatingAuthority; //导入依赖的package包/类
/** {@inheritDoc} */
public void validate(AuthenticatingAuthority authenAuthority) throws ValidationException {
    validateURI(authenAuthority);
}
 
开发者ID:lamsfoundation,项目名称:lams,代码行数:5,代码来源:AuthenticatingAuthoritySchemaValidator.java

示例7: buildObject

import org.opensaml.saml2.core.AuthenticatingAuthority; //导入依赖的package包/类
/** {@inheritDoc} */
public AuthenticatingAuthority buildObject() {
    return buildObject(SAMLConstants.SAML20_NS, AuthenticatingAuthority.DEFAULT_ELEMENT_LOCAL_NAME,
            SAMLConstants.SAML20_PREFIX);
}
 
开发者ID:lamsfoundation,项目名称:lams,代码行数:6,代码来源:AuthenticatingAuthorityBuilder.java

示例8: processElementContent

import org.opensaml.saml2.core.AuthenticatingAuthority; //导入依赖的package包/类
/** {@inheritDoc} */
protected void processElementContent(XMLObject samlObject, String elementContent) {
    AuthenticatingAuthority authenticatingAuthority = (AuthenticatingAuthority) samlObject;
    authenticatingAuthority.setURI(elementContent);
}
 
开发者ID:lamsfoundation,项目名称:lams,代码行数:6,代码来源:AuthenticatingAuthorityUnmarshaller.java

示例9: marshallElementContent

import org.opensaml.saml2.core.AuthenticatingAuthority; //导入依赖的package包/类
/** {@inheritDoc} */
protected void marshallElementContent(XMLObject samlObject, Element domElement) throws MarshallingException {
    AuthenticatingAuthority authenticatingAuthority = (AuthenticatingAuthority) samlObject;
    XMLHelper.appendTextContent(domElement, authenticatingAuthority.getURI());
}
 
开发者ID:lamsfoundation,项目名称:lams,代码行数:6,代码来源:AuthenticatingAuthorityMarshaller.java

示例10: getAuthenticatingAuthorities

import org.opensaml.saml2.core.AuthenticatingAuthority; //导入依赖的package包/类
/** {@inheritDoc} */
public List<AuthenticatingAuthority> getAuthenticatingAuthorities() {
    return authenticatingAuthority;
}
 
开发者ID:lamsfoundation,项目名称:lams,代码行数:5,代码来源:AuthnContextImpl.java

示例11: AuthenticatingAuthorityUnmarshaller

import org.opensaml.saml2.core.AuthenticatingAuthority; //导入依赖的package包/类
/** Constructor. */
public AuthenticatingAuthorityUnmarshaller() {
    super(SAMLConstants.SAML20_NS, AuthenticatingAuthority.DEFAULT_ELEMENT_LOCAL_NAME);
}
 
开发者ID:apigee,项目名称:java-opensaml2,代码行数:5,代码来源:AuthenticatingAuthorityUnmarshaller.java

示例12: AuthenticatingAuthorityMarshaller

import org.opensaml.saml2.core.AuthenticatingAuthority; //导入依赖的package包/类
/** Constructor. */
public AuthenticatingAuthorityMarshaller() {
    super(SAMLConstants.SAML20_NS, AuthenticatingAuthority.DEFAULT_ELEMENT_LOCAL_NAME);
}
 
开发者ID:apigee,项目名称:java-opensaml2,代码行数:5,代码来源:AuthenticatingAuthorityMarshaller.java

示例13: AuthenticatingAuthoritySchemaTest

import org.opensaml.saml2.core.AuthenticatingAuthority; //导入依赖的package包/类
/** Constructor */
public AuthenticatingAuthoritySchemaTest() {
    targetQName = new QName(SAMLConstants.SAML20_NS, AuthenticatingAuthority.DEFAULT_ELEMENT_LOCAL_NAME,
            SAMLConstants.SAML20_PREFIX);
    validator = new AuthenticatingAuthoritySchemaValidator();
}
 
开发者ID:apigee,项目名称:java-opensaml2,代码行数:7,代码来源:AuthenticatingAuthoritySchemaTest.java

示例14: populateRequiredData

import org.opensaml.saml2.core.AuthenticatingAuthority; //导入依赖的package包/类
protected void populateRequiredData() {
    super.populateRequiredData();
    AuthenticatingAuthority authenticatingAuthority = (AuthenticatingAuthority) target;
    authenticatingAuthority.setURI("uri");
}
 
开发者ID:apigee,项目名称:java-opensaml2,代码行数:6,代码来源:AuthenticatingAuthoritySchemaTest.java

示例15: validateURI

import org.opensaml.saml2.core.AuthenticatingAuthority; //导入依赖的package包/类
/**
 * Checks that the URI is present.
 * 
 * @param authenAuthority
 * @throws ValidationException
 */
protected void validateURI(AuthenticatingAuthority authenAuthority) throws ValidationException {
    if (DatatypeHelper.isEmpty(authenAuthority.getURI())) {
        throw new ValidationException("URI required");
    }
}
 
开发者ID:lamsfoundation,项目名称:lams,代码行数:12,代码来源:AuthenticatingAuthoritySchemaValidator.java


注:本文中的org.opensaml.saml2.core.AuthenticatingAuthority类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。