@Override public boolean equals(Object obj) { return (obj instanceof HostConfigurableSocketFactory) && EqualsHelper.nullSafeEquals(this.host, ((HostConfigurableSocketFactory) obj).host); }
@Override public boolean equals(Object obj) { return (obj instanceof HostConfigurableSocketFactory) && EqualsHelper.nullSafeEquals(this.host, ((HostConfigurableSocketFactory) obj).host); }
@Override public boolean equals(Object obj) { if (this == obj) { return true; } if (obj == null || !(obj instanceof CustomProperties)) { return false; } CustomProperties other = (CustomProperties) obj; return EqualsHelper.nullSafeEquals(this.name, other.name); }
@Override public boolean equals(Object obj) { if (this == obj) { return true; } if (obj == null || !(obj instanceof CustomProperties)) { return false; } CustomProperties other = (CustomProperties) obj; return EqualsHelper.nullSafeEquals(this.name, other.name); }
/** * Convenience getter to interpret the {@link #EMPTY_LOCALNAME_SUBSTITUTE} */ public String getLocalNameSafe() { if (EqualsHelper.nullSafeEquals(localName, QNameEntity.EMPTY_LOCALNAME_SUBSTITUTE)) { return ""; } else { return localName; } } /**
/** * Convenience getter to interpret the {@link QName#EMPTY_URI_SUBSTITUTE} */ public String getUriSafe() { if (EqualsHelper.nullSafeEquals(uri, QName.EMPTY_URI_SUBSTITUTE)) { return ""; } else { return uri; } } /**
@Override public boolean equals(Object other) { if (this == other) { return true; } if (other == null || !(other instanceof Pair<?, ?>)) { return false; } Pair<?, ?> o = (Pair<?, ?>)other; return EqualsHelper.nullSafeEquals(this.first, o.first) && EqualsHelper.nullSafeEquals(this.second, o.second); }
@Override public boolean equals(Object obj) { if (this == obj) return true; if (obj == null) return false; if (getClass() != obj.getClass()) return false; RepoUsage that = (RepoUsage) obj; return EqualsHelper.nullSafeEquals(this.users, that.users) && EqualsHelper.nullSafeEquals(this.documents, that.documents) && EqualsHelper.nullSafeEquals(this.licenseMode, that.licenseMode) && EqualsHelper.nullSafeEquals(this.licenseExpiryDate, that.licenseExpiryDate) && this.readOnly == that.readOnly; }
@Override public boolean equals(Object obj) { if (this == obj) return true; if (obj == null) return false; if (getClass() != obj.getClass()) return false; RepoUsage that = (RepoUsage) obj; return EqualsHelper.nullSafeEquals(this.users, that.users) && EqualsHelper.nullSafeEquals(this.documents, that.documents) && EqualsHelper.nullSafeEquals(this.licenseMode, that.licenseMode) && EqualsHelper.nullSafeEquals(this.licenseExpiryDate, that.licenseExpiryDate) && this.readOnly == that.readOnly; }
private boolean isBuiltInAuthorities(String caseSensitiveUserName) { if (EqualsHelper.nullSafeEquals(caseSensitiveUserName, AuthenticationUtil.getSystemUserName())) { return true; } else if (EqualsHelper.nullSafeEquals(caseSensitiveUserName, AuthenticationUtil.getGuestUserName())) { return true; } return false; }
public Boolean doWork() throws Exception { // TODO Auto-generated method stub return EqualsHelper.nullSafeEquals(ownableService.getOwner(nodeRef), userName); }}, AuthenticationUtil.getSystemUserName());
@Override public boolean equals(Object otherObj) { if (otherObj == null || !otherObj.getClass().equals(this.getClass())) { return false; } OngoingAsyncAction otherNodeBeingActioned = (OngoingAsyncAction)otherObj; return EqualsHelper.nullSafeEquals(this.node, otherNodeBeingActioned.node) && EqualsHelper.nullSafeEquals(this.action.getActionDefinitionName(), otherNodeBeingActioned.action.getActionDefinitionName()); }
@Override public boolean equals(Object otherObj) { if (otherObj == null || !otherObj.getClass().equals(this.getClass())) { return false; } OngoingAsyncAction otherNodeBeingActioned = (OngoingAsyncAction)otherObj; return EqualsHelper.nullSafeEquals(this.node, otherNodeBeingActioned.node) && EqualsHelper.nullSafeEquals(this.action.getActionDefinitionName(), otherNodeBeingActioned.action.getActionDefinitionName()); }
public Boolean doWork() throws Exception { // TODO Auto-generated method stub return EqualsHelper.nullSafeEquals(ownableService.getOwner(nodeRef), userName); }}, AuthenticationUtil.getSystemUserName());
private boolean isSystemUserName(String userName) { return EqualsHelper.nullSafeEquals(userName, AuthenticationUtil.getSystemUserName(), true); }
private boolean isPivotTranslation(NodeRef contentNodeRef) { Locale locale = (Locale) nodeService.getProperty(contentNodeRef, ContentModel.PROP_LOCALE); // Get the container NodeRef containerNodeRef = getOrCreateMLContainer(contentNodeRef, false); Locale containerLocale = (Locale) nodeService.getProperty(containerNodeRef, ContentModel.PROP_LOCALE); boolean isPivot = EqualsHelper.nullSafeEquals(locale, containerLocale); // Done if (logger.isDebugEnabled()) { logger.debug("Node " + (isPivot ? "is" : "is not") + " pivot: " + contentNodeRef); } return isPivot; }
private boolean isPivotTranslation(NodeRef contentNodeRef) { Locale locale = (Locale) nodeService.getProperty(contentNodeRef, ContentModel.PROP_LOCALE); // Get the container NodeRef containerNodeRef = getOrCreateMLContainer(contentNodeRef, false); Locale containerLocale = (Locale) nodeService.getProperty(containerNodeRef, ContentModel.PROP_LOCALE); boolean isPivot = EqualsHelper.nullSafeEquals(locale, containerLocale); // Done if (logger.isDebugEnabled()) { logger.debug("Node " + (isPivot ? "is" : "is not") + " pivot: " + contentNodeRef); } return isPivot; }
public Pair<Long, Object> findByValue(Object value) { assertTrue(value == null || value instanceof TestValue); String dbValue = (value == null) ? null : ((TestValue)value).val; for (Map.Entry<Long, String> entry : database.entrySet()) { if (EqualsHelper.nullSafeEquals(entry.getValue(), dbValue)) { return new Pair<Long, Object>(entry.getKey(), entry.getValue()); } } return null; }
public String getAttributeQName(Object o) { QName qName = ((Property) o).qname; String escapedLocalName = ISO9075.encode(qName.getLocalName()); if (EqualsHelper.nullSafeEquals(escapedLocalName, qName.getLocalName())) { return qName.toString(); } else { return QName.createQName(qName.getNamespaceURI(), escapedLocalName).toString(); } }
public String getAttributeQName(Object o) { QName qName = ((Property) o).qname; String escapedLocalName = ISO9075.encode(qName.getLocalName()); if (EqualsHelper.nullSafeEquals(escapedLocalName, qName.getLocalName())) { return qName.toString(); } else { return QName.createQName(qName.getNamespaceURI(), escapedLocalName).toString(); } }