@Override public boolean equals(Object obj) { if (this == obj) { return true; } if (!sameClassAs(obj)) { return false; } BatchId other = (BatchId) obj; return eq(getId(), other.getId()); }
@Override public String toString() { return "{BatchId id=" + getTextValue() + "}"; } }
/** * Constructs a new instance with the given value. * * @param id value. */ public BatchId(String id) { this(); setId(id); }
/** * Sets the value of the tag {@code <batch:id>}. * * @param entry entry to get the id from * @param id the batch id or null to remove it */ public static void setBatchId(IEntry entry, String id) { if (entry instanceof Element) { ((Element) entry).setElement(BatchId.KEY, (id == null) ? null : new BatchId(id)); } else { com.google.gdata.data.batch.BatchUtils.setBatchId( (ExtensionPoint) entry, id); } }
/** * Gets the value of the tag {@code <batch:id>}. * * @param entry the entry to get the id from * @return the batch id or null if it is not set */ public static String getBatchId(IEntry entry) { if (entry instanceof Entry) { return BatchId.getIdFrom((Entry) entry); } else { return com.google.gdata.data.batch.BatchUtils.getBatchId( (BaseEntry<?>) entry); } }
/** * Sets the value of the tag {@code <batch:id>}. * * @param entry entry to get the id from * @param id the batch id or null to remove it */ public static void setBatchId(IEntry entry, String id) { if (entry instanceof Element) { ((Element) entry).setElement(BatchId.KEY, (id == null) ? null : new BatchId(id)); } else { com.google.gdata.data.batch.BatchUtils.setBatchId( (ExtensionPoint) entry, id); } }
/** * Gets the value of the tag {@code <batch:id>}. * * @param entry the entry to get the id from * @return the batch id or null if it is not set */ public static String getBatchId(IEntry entry) { if (entry instanceof Entry) { return BatchId.getIdFrom((Entry) entry); } else { return com.google.gdata.data.batch.BatchUtils.getBatchId( (BaseEntry<?>) entry); } }
@Override public boolean equals(Object obj) { if (this == obj) { return true; } if (!sameClassAs(obj)) { return false; } BatchId other = (BatchId) obj; return eq(getId(), other.getId()); }
/** * Constructs a new instance with the given value. * * @param id value. */ public BatchId(String id) { this(); setId(id); }
@Override public String toString() { return "{BatchId id=" + getTextValue() + "}"; } }
/** * Sets the value of the tag {@code <batch:id>}. * * @param entry entry to get the id from * @param id the batch id or null to remove it */ public static void setBatchId(IEntry entry, String id) { if (entry instanceof Element) { ((Element) entry).setElement(BatchId.KEY, (id == null) ? null : new BatchId(id)); } else { com.google.gdata.data.batch.BatchUtils.setBatchId( (ExtensionPoint) entry, id); } }
/** * Gets the value of the tag {@code <batch:id>}. * * @param entry the entry to get the id from * @return the batch id or null if it is not set */ public static String getBatchId(IEntry entry) { if (entry instanceof Entry) { return BatchId.getIdFrom((Entry) entry); } else { return com.google.gdata.data.batch.BatchUtils.getBatchId( (BaseEntry<?>) entry); } }
@Override public boolean equals(Object obj) { if (this == obj) { return true; } if (!sameClassAs(obj)) { return false; } BatchId other = (BatchId) obj; return eq(getId(), other.getId()); }
/** * Convenience method for getting a batchId from * an element if it's there. * * @param element element to get id from. * @return the id or {@code null} if it's not defined. */ public static String getIdFrom(Element element) { BatchId tag = element.getElement(KEY); return tag == null ? null : tag.getId(); }
/** * Constructs a new instance with the given value. * * @param id value. */ public BatchId(String id) { this(); setId(id); }
@Override public String toString() { return "{BatchId id=" + getTextValue() + "}"; } }
/** * Convenience method for getting a batchId from * an element if it's there. * * @param element element to get id from. * @return the id or {@code null} if it's not defined. */ public static String getIdFrom(Element element) { BatchId tag = element.getElement(KEY); return tag == null ? null : tag.getId(); }