本文整理汇总了Java中org.opensaml.saml1.core.ConfirmationMethod类的典型用法代码示例。如果您正苦于以下问题:Java ConfirmationMethod类的具体用法?Java ConfirmationMethod怎么用?Java ConfirmationMethod使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
ConfirmationMethod类属于org.opensaml.saml1.core包,在下文中一共展示了ConfirmationMethod类的18个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的Java代码示例。
示例1: newSubject
import org.opensaml.saml1.core.ConfirmationMethod; //导入依赖的package包/类
private Subject newSubject(final String identifier) {
final SubjectConfirmation confirmation = newSamlObject(SubjectConfirmation.class);
final ConfirmationMethod method = newSamlObject(ConfirmationMethod.class);
method.setConfirmationMethod(CONFIRMATION_METHOD);
confirmation.getConfirmationMethods().add(method);
final NameIdentifier nameIdentifier = newSamlObject(NameIdentifier.class);
nameIdentifier.setNameIdentifier(identifier);
final Subject subject = newSamlObject(Subject.class);
subject.setNameIdentifier(nameIdentifier);
subject.setSubjectConfirmation(confirmation);
return subject;
}
开发者ID:luotuo,项目名称:cas4.0.x-server-wechat,代码行数:13,代码来源:Saml10SuccessResponseView.java
示例2: processChildElement
import org.opensaml.saml1.core.ConfirmationMethod; //导入依赖的package包/类
/** {@inheritDoc} */
protected void processChildElement(XMLObject parentSAMLObject, XMLObject childSAMLObject)
throws UnmarshallingException {
SubjectConfirmation subjectConfirmation = (SubjectConfirmation) parentSAMLObject;
if (childSAMLObject instanceof ConfirmationMethod) {
subjectConfirmation.getConfirmationMethods().add((ConfirmationMethod) childSAMLObject);
} else if(childSAMLObject instanceof KeyInfo) {
subjectConfirmation.setKeyInfo((KeyInfo)childSAMLObject);
} else {
subjectConfirmation.setSubjectConfirmationData(childSAMLObject);
}
}
开发者ID:lamsfoundation,项目名称:lams,代码行数:15,代码来源:SubjectConfirmationUnmarshaller.java
示例3: processChildElement
import org.opensaml.saml1.core.ConfirmationMethod; //导入依赖的package包/类
/** {@inheritDoc} */
protected void processChildElement(XMLObject parentSAMLObject, XMLObject childSAMLObject)
throws UnmarshallingException {
SubjectConfirmation subjectConfirmation = (SubjectConfirmation) parentSAMLObject;
if (childSAMLObject instanceof ConfirmationMethod) {
subjectConfirmation.getConfirmationMethods().add((ConfirmationMethod) childSAMLObject);
} else {
subjectConfirmation.setSubjectConfirmationData(childSAMLObject);
}
}
开发者ID:apigee,项目名称:java-opensaml2,代码行数:13,代码来源:SubjectConfirmationUnmarshaller.java
示例4: populateRequiredData
import org.opensaml.saml1.core.ConfirmationMethod; //导入依赖的package包/类
/** {@inheritDoc} */
protected void populateRequiredData() {
super.populateRequiredData();
SubjectConfirmation subjectConfirmation = (SubjectConfirmation) target;
QName qname = new QName(SAMLConstants.SAML1_NS, ConfirmationMethod.DEFAULT_ELEMENT_LOCAL_NAME, SAMLConstants.SAML1_PREFIX);
subjectConfirmation.getConfirmationMethods().add((ConfirmationMethod)buildXMLObject(qname));
}
开发者ID:apigee,项目名称:java-opensaml2,代码行数:10,代码来源:SubjectConfirmationSchemaTest.java
示例5: testFullElementsMarshall
import org.opensaml.saml1.core.ConfirmationMethod; //导入依赖的package包/类
public void testFullElementsMarshall() {
SubjectConfirmation subjectConfirmation = (SubjectConfirmationImpl) buildXMLObject(qname);
QName oqname = new QName(SAMLConstants.SAML1_NS, ConfirmationMethod.DEFAULT_ELEMENT_LOCAL_NAME, SAMLConstants.SAML1_PREFIX);
subjectConfirmation.getConfirmationMethods().add((ConfirmationMethod) buildXMLObject(oqname));
subjectConfirmation.getConfirmationMethods().add((ConfirmationMethod) buildXMLObject(oqname));
XSAnyBuilder proxyBuilder = new XSAnyBuilder();
oqname = new QName(SAMLConstants.SAML1_NS, SubjectConfirmationData.DEFAULT_ELEMENT_LOCAL_NAME, SAMLConstants.SAML1_PREFIX);
subjectConfirmation.setSubjectConfirmationData(proxyBuilder.buildObject(oqname));
assertEquals(expectedFullDOM, subjectConfirmation);
}
开发者ID:apigee,项目名称:java-opensaml2,代码行数:14,代码来源:SubjectConfirmationTest.java
示例6: ConfirmationMethodTest
import org.opensaml.saml1.core.ConfirmationMethod; //导入依赖的package包/类
/**
* Constructor
*/
public ConfirmationMethodTest() {
super();
singleElementFile = "/data/org/opensaml/saml1/impl/singleConfirmationMethod.xml";
singleElementOptionalAttributesFile = "/data/org/opensaml/saml1/impl/singleConfirmationMethodAttributes.xml";
expectedConfirmationMethod = "confirmation";
qname = new QName(SAMLConstants.SAML1_NS, ConfirmationMethod.DEFAULT_ELEMENT_LOCAL_NAME, SAMLConstants.SAML1_PREFIX);
}
开发者ID:apigee,项目名称:java-opensaml2,代码行数:12,代码来源:ConfirmationMethodTest.java
示例7: testSingleElementOptionalAttributesMarshall
import org.opensaml.saml1.core.ConfirmationMethod; //导入依赖的package包/类
/** {@inheritDoc} */
public void testSingleElementOptionalAttributesMarshall() {
ConfirmationMethod confirmationMethod = (ConfirmationMethod) buildXMLObject(qname);
confirmationMethod.setConfirmationMethod(expectedConfirmationMethod);
assertEquals(expectedOptionalAttributesDOM, confirmationMethod);
}
开发者ID:apigee,项目名称:java-opensaml2,代码行数:9,代码来源:ConfirmationMethodTest.java
示例8: getConfirmationMethods
import org.opensaml.saml1.core.ConfirmationMethod; //导入依赖的package包/类
/** {@inheritDoc} */
public List<ConfirmationMethod> getConfirmationMethods() {
return confirmationMethods;
}
开发者ID:lamsfoundation,项目名称:lams,代码行数:5,代码来源:SubjectConfirmationImpl.java
示例9: processElementContent
import org.opensaml.saml1.core.ConfirmationMethod; //导入依赖的package包/类
/** {@inheritDoc} */
protected void processElementContent(XMLObject samlObject, String elementContent) {
ConfirmationMethod confirmationMethod = (ConfirmationMethod) samlObject;
confirmationMethod.setConfirmationMethod(elementContent);
}
开发者ID:lamsfoundation,项目名称:lams,代码行数:7,代码来源:ConfirmationMethodUnmarshaller.java
示例10: buildObject
import org.opensaml.saml1.core.ConfirmationMethod; //导入依赖的package包/类
/** {@inheritDoc} */
public ConfirmationMethod buildObject() {
return buildObject(SAMLConstants.SAML1_NS, ConfirmationMethod.DEFAULT_ELEMENT_LOCAL_NAME, SAMLConstants.SAML1_PREFIX);
}
开发者ID:lamsfoundation,项目名称:lams,代码行数:5,代码来源:ConfirmationMethodBuilder.java
示例11: marshallElementContent
import org.opensaml.saml1.core.ConfirmationMethod; //导入依赖的package包/类
/** {@inheritDoc} */
protected void marshallElementContent(XMLObject samlObject, Element domElement) throws MarshallingException {
ConfirmationMethod confirmationMethod = (ConfirmationMethod) samlObject;
XMLHelper.appendTextContent(domElement, confirmationMethod.getConfirmationMethod());
}
开发者ID:lamsfoundation,项目名称:lams,代码行数:7,代码来源:ConfirmationMethodMarshaller.java
示例12: createStatement
import org.opensaml.saml1.core.ConfirmationMethod; //导入依赖的package包/类
@Override
public void createStatement(GenericIdentityProviderData ipData, RahasData rahasData)
throws IdentityProviderException {
if (log.isDebugEnabled()) {
log.debug("Begin SAML statement creation.");
}
attributeStmt = (AttributeStatement) buildXMLObject(AttributeStatement.DEFAULT_ELEMENT_NAME);
Subject subject = (Subject) buildXMLObject(Subject.DEFAULT_ELEMENT_NAME);
SubjectConfirmation subjectConf =
(SubjectConfirmation) buildXMLObject(SubjectConfirmation.DEFAULT_ELEMENT_NAME);
ConfirmationMethod confMethod = (ConfirmationMethod) buildXMLObject(ConfirmationMethod.DEFAULT_ELEMENT_NAME);
confMethod.setConfirmationMethod(CONF_KEY);
subjectConf.getConfirmationMethods().add(confMethod);
subject.setSubjectConfirmation(subjectConf);
attributeStmt.setSubject(subject);
Map<String, RequestedClaimData> mapClaims = ipData.getRequestedClaims();
if (rahasData.getAppliesToAddress() != null) {
appilesTo = rahasData.getAppliesToAddress();
}
Iterator<RequestedClaimData> ite = mapClaims.values().iterator();
while (ite.hasNext()) {
RequestedClaimData claim = ite.next();
String uri = claim.getUri();
int index = uri.lastIndexOf("/");
String attrName = uri.substring(index + 1, uri.length());
String attrNamespace = uri.substring(0, index);
Attribute attribute = (Attribute) buildXMLObject(Attribute.DEFAULT_ELEMENT_NAME);
attribute.setAttributeName(attrName);
attribute.setAttributeNamespace(attrNamespace);
XMLObjectBuilderFactory builderFactory = Configuration.getBuilderFactory();
XSStringBuilder attributeValueBuilder = (XSStringBuilder) builderFactory.getBuilder(XSString.TYPE_NAME);
XSString stringValue =
attributeValueBuilder.buildObject(AttributeValue.DEFAULT_ELEMENT_NAME, XSString.TYPE_NAME);
stringValue.setValue(claim.getValue());
attribute.getAttributeValues().add(stringValue);
attributeStmt.getAttributes().add(attribute);
}
}
开发者ID:wso2-attic,项目名称:carbon-identity,代码行数:50,代码来源:SAML1TokenBuilder.java
示例13: ConfirmationMethodUnmarshaller
import org.opensaml.saml1.core.ConfirmationMethod; //导入依赖的package包/类
/**
* Constructor
*/
public ConfirmationMethodUnmarshaller() {
super(SAMLConstants.SAML1_NS, ConfirmationMethod.DEFAULT_ELEMENT_LOCAL_NAME);
}
开发者ID:apigee,项目名称:java-opensaml2,代码行数:7,代码来源:ConfirmationMethodUnmarshaller.java
示例14: ConfirmationMethodMarshaller
import org.opensaml.saml1.core.ConfirmationMethod; //导入依赖的package包/类
/**
* Constructor
*/
public ConfirmationMethodMarshaller() {
super(SAMLConstants.SAML1_NS, ConfirmationMethod.DEFAULT_ELEMENT_LOCAL_NAME);
}
开发者ID:apigee,项目名称:java-opensaml2,代码行数:7,代码来源:ConfirmationMethodMarshaller.java
示例15: marshallElementContent
import org.opensaml.saml1.core.ConfirmationMethod; //导入依赖的package包/类
/** {@inheritDoc} */
protected void marshallElementContent(XMLObject samlObject, Element domElement) throws MarshallingException {
ConfirmationMethod confirmationMethod = (ConfirmationMethod) samlObject;
XMLHelper.appendTextContent(domElement,confirmationMethod.getConfirmationMethod());
}
开发者ID:apigee,项目名称:java-opensaml2,代码行数:7,代码来源:ConfirmationMethodMarshaller.java
示例16: testSingleElementUnmarshall
import org.opensaml.saml1.core.ConfirmationMethod; //导入依赖的package包/类
/** {@inheritDoc} */
public void testSingleElementUnmarshall() {
ConfirmationMethod confirmationMethod = (ConfirmationMethod) unmarshallElement(singleElementFile);
assertNull("Contents of Confirmation Method", confirmationMethod.getConfirmationMethod());
}
开发者ID:apigee,项目名称:java-opensaml2,代码行数:9,代码来源:ConfirmationMethodTest.java
示例17: testSingleElementOptionalAttributesUnmarshall
import org.opensaml.saml1.core.ConfirmationMethod; //导入依赖的package包/类
/** {@inheritDoc} */
public void testSingleElementOptionalAttributesUnmarshall() {
ConfirmationMethod confirmationMethod = (ConfirmationMethod) unmarshallElement(singleElementOptionalAttributesFile);
assertEquals("Contents of Confirmation Method", expectedConfirmationMethod, confirmationMethod.getConfirmationMethod());
}
开发者ID:apigee,项目名称:java-opensaml2,代码行数:8,代码来源:ConfirmationMethodTest.java
示例18: SubjectConfirmationImpl
import org.opensaml.saml1.core.ConfirmationMethod; //导入依赖的package包/类
/**
* Constructor
*
* @param namespaceURI the namespace the element is in
* @param elementLocalName the local name of the XML element this Object represents
* @param namespacePrefix the prefix for the given namespace
*/
protected SubjectConfirmationImpl(String namespaceURI, String elementLocalName, String namespacePrefix) {
super(namespaceURI, elementLocalName, namespacePrefix);
confirmationMethods = new XMLObjectChildrenList<ConfirmationMethod>(this);
}
开发者ID:lamsfoundation,项目名称:lams,代码行数:12,代码来源:SubjectConfirmationImpl.java
注:本文中的org.opensaml.saml1.core.ConfirmationMethod类示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。 |
请发表评论