Package org.picketlink.identity.federation.ws.wss.utility

Examples of org.picketlink.identity.federation.ws.wss.utility.AttributedDateTime


                    LifetimeType lifeTime = new LifetimeType();
                    // Get the Created
                    subEvent = StaxParserUtil.getNextStartElement(xmlEventReader);
                    String subTag = StaxParserUtil.getStartElementName(subEvent);
                    if (subTag.equals(WSTrustConstants.CREATED)) {
                        AttributedDateTime created = new AttributedDateTime();
                        created.setValue(StaxParserUtil.getElementText(xmlEventReader));
                        lifeTime.setCreated(created);
                    }
                    subEvent = StaxParserUtil.getNextStartElement(xmlEventReader);
                    subTag = StaxParserUtil.getStartElementName(subEvent);

                    if (subTag.equals(WSTrustConstants.EXPIRES)) {
                        AttributedDateTime expires = new AttributedDateTime();
                        expires.setValue(StaxParserUtil.getElementText(xmlEventReader));
                        lifeTime.setExpires(expires);
                    } else
                        throw logger.parserUnknownTag(subTag, subEvent.getLocation());

                    responseToken.setLifetime(new Lifetime(lifeTime));
View Full Code Here


                    LifetimeType lifeTime = new LifetimeType();
                    // Get the Created
                    subEvent = StaxParserUtil.getNextStartElement(xmlEventReader);
                    String subTag = StaxParserUtil.getStartElementName(subEvent);
                    if (subTag.equals(WSTrustConstants.CREATED)) {
                        AttributedDateTime created = new AttributedDateTime();
                        created.setValue(StaxParserUtil.getElementText(xmlEventReader));
                        lifeTime.setCreated(created);
                    }
                    subEvent = StaxParserUtil.getNextStartElement(xmlEventReader);
                    subTag = StaxParserUtil.getStartElementName(subEvent);

                    if (subTag.equals(WSTrustConstants.EXPIRES)) {
                        AttributedDateTime expires = new AttributedDateTime();
                        expires.setValue(StaxParserUtil.getElementText(xmlEventReader));
                        lifeTime.setExpires(expires);
                    } else
                        throw new RuntimeException(ErrorCodes.UNKNOWN_TAG + subTag);

                    requestToken.setLifetime(new Lifetime(lifeTime));
View Full Code Here

        this.created = factory.newXMLGregorianCalendar(created).normalize();
        this.expires = factory.newXMLGregorianCalendar(expires).normalize();

        // set the delegate fields.
        this.delegate = new LifetimeType();
        AttributedDateTime dateTime = new AttributedDateTime();
        dateTime.setValue(this.created.toXMLFormat());
        this.delegate.setCreated(dateTime);
        dateTime = new AttributedDateTime();
        dateTime.setValue(this.expires.toXMLFormat());
        this.delegate.setExpires(dateTime);

    }
View Full Code Here

TOP

Related Classes of org.picketlink.identity.federation.ws.wss.utility.AttributedDateTime

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.