public Object copyTo(Object target, CopyBuilder copyBuilder) { final Renew copy = ((target == null)?new Renew():((Renew) target)); { String sourceTerminationTime; sourceTerminationTime = this.getTerminationTime(); String copyTerminationTime = ((String) copyBuilder.copy(sourceTerminationTime)); copy.setTerminationTime(copyTerminationTime); } { List<Object> sourceAny; sourceAny = this.getAny(); List<Object> copyAny = ((List<Object> ) copyBuilder.copy(sourceAny)); copy.any = null; List<Object> uniqueAnyl = copy.getAny(); uniqueAnyl.addAll(copyAny); } return copy; }
public void toString(ToStringBuilder toStringBuilder) { { String theTerminationTime; theTerminationTime = this.getTerminationTime(); toStringBuilder.append("terminationTime", theTerminationTime); } { List<Object> theAny; theAny = this.getAny(); toStringBuilder.append("any", theAny); } }
@Override public final void setTerminationTime(Duration value) { this.jaxbTypeObj.setTerminationTime(value.toString()); }
/** * Create an instance of {@link Renew } * */ public Renew createRenew() { return new Renew(); }
/** * Method used to set an xml fragment representation of a {@link ResourcesUuidType} object into a * {@link Renew} object * * @param rUuidsObj {@link ResourcesUuidType} object whom the xml representation must be set * @param renewObj {@link Renew} object in which the xml representation must be set * @throws WSNotificationExtensionException */ public static void setResourcesUuidType(final ResourcesUuidType rUuidsObj ,final Renew renewObj) throws WSNotificationExtensionException{ final List<Object> listOfObj = ((com.ebmwebsourcing.wsstar.jaxb.notification.base.Renew) ((AbstractSchemaElementImpl<?>)renewObj).getModel()).getAny(); WsnSpecificTypeHelper.setResourceUuidType(rUuidsObj, listOfObj); }
public String getTerminationTime() throws WSNotificationException { return this.model.getTerminationTime(); }
public int hashCode() { final HashCodeBuilder hashCodeBuilder = new JAXBHashCodeBuilder(); hashCode(hashCodeBuilder); return hashCodeBuilder.toHashCode(); }
public String toString() { final ToStringBuilder toStringBuilder = new JAXBToStringBuilder(this); toString(toStringBuilder); return toStringBuilder.toString(); }
public boolean equals(Object object) { if (!(object instanceof Renew)) { return false; } if (this == object) { return true; } final EqualsBuilder equalsBuilder = new JAXBEqualsBuilder(); equals(object, equalsBuilder); return equalsBuilder.isEquals(); }
public Object copyTo(Object target) { final CopyBuilder copyBuilder = new JAXBCopyBuilder(); return copyTo(target, copyBuilder); }
public void equals(Object object, EqualsBuilder equalsBuilder) { if (!(object instanceof Renew)) { equalsBuilder.appendSuper(false); return ; } if (this == object) { return ; } final Renew that = ((Renew) object); equalsBuilder.append(this.getTerminationTime(), that.getTerminationTime()); equalsBuilder.append(this.getAny(), that.getAny()); }
public void setTerminationTime(Duration value) throws WSNotificationException { this.model.setTerminationTime(value.toString()); }
/** * Create an instance of {@link Renew } * */ public Renew createRenew() { return new Renew(); }
/** * Method used to get {@link ResourcesUuidType} object from * {@link Renew} object * * @param unsubsObj {@link Renew} object * @return {@link ResourcesUuidType} object * @throws WSNotificationExtensionException */ public static ResourcesUuidType getResourcesUuidType(final Renew renewObj) throws WSNotificationExtensionException{ final List<Object> listOfObj = ((com.ebmwebsourcing.wsstar.jaxb.notification.base.Renew) ((AbstractSchemaElementImpl<?>)renewObj).getModel()).getAny(); return WsnSpecificTypeHelper.getResourcesUuidType(listOfObj); } // --- Pseudo Setters ---
@Override public final Object getTerminationTime() { Object termTime = null; String jaxbTermTime = this.jaxbTypeObj.getTerminationTime(); if (jaxbTermTime != null && jaxbTermTime.length() >0){ try { if (jaxbTermTime.startsWith("P")){ termTime = DatatypeFactory.newInstance().newDuration(jaxbTermTime); } else if(jaxbTermTime.contains("T")){ termTime = DatatypeFactory.newInstance().newXMLGregorianCalendar(jaxbTermTime).toGregorianCalendar().getTime(); } } catch (DatatypeConfigurationException e) { RenewImpl.logger.log(Level.WARNING,"The \"InitalTerminaionTime\" field " + "value of the \"Subsrcibe\" payload does correspond to a string representation" + "of a \"Duration\" xml type nor \"DateTime\" xml type (received : " + jaxbTermTime+ ") \n",e); } } return termTime; }
public void hashCode(HashCodeBuilder hashCodeBuilder) { hashCodeBuilder.append(this.getTerminationTime()); hashCodeBuilder.append(this.getAny()); }
public void setTerminationTime(Date value) throws WSNotificationException { GregorianCalendar gCal = new GregorianCalendar(); gCal.setTime(value); XMLGregorianCalendar xmlGCal; try { xmlGCal = DatatypeFactory.newInstance().newXMLGregorianCalendar(gCal); } catch (DatatypeConfigurationException e) { throw new WSNotificationException(e); } this.model.setTerminationTime(xmlGCal.toString()); }
@Override public final void setTerminationTime(Date value) { this.jaxbTypeObj.setTerminationTime(WsrfbfUtils.toXMLGregorianCalendar(value, RenewImpl.logger).toString()); }
/** * A way to create a {@link com.ebmwebsourcing.wsstar.jaxb.notification.base.NotificationMessageHolderType} * "Jaxb model type" object from a {@link NotificationMessageHolderType} "api type" one * @param apiTypeObj * @return */ public static com.ebmwebsourcing.wsstar.jaxb.notification.base.Renew toJaxbModel(Renew apiTypeObj) { com.ebmwebsourcing.wsstar.jaxb.notification.base.Renew jaxbTypeObj = null; if (apiTypeObj instanceof RenewImpl){ jaxbTypeObj = ((RenewImpl)apiTypeObj).getJaxbTypeObj(); } else { jaxbTypeObj = WsnbJAXBContext.WSNB_JAXB_FACTORY.createRenew(); // ~~~~ Set TerminationTime ~~~~~ Object termiTime = apiTypeObj.getTerminationTime(); if (termiTime != null){ if (termiTime instanceof Duration){ jaxbTypeObj.setTerminationTime(((Duration)termiTime).toString()); } else if (termiTime instanceof Date){ jaxbTypeObj.setTerminationTime(((Date)termiTime).toString()); } } } return jaxbTypeObj; } }