Check that the given id is not the null id.<p>

@param id the id to check
@param canBeNull only if flag is set, <code>null</code> is accepted

@see #isNullUUID()
506886
public static void checkId(CmsUUID id, boolean canBeNull) {

        if (canBeNull && (id == null)) {
            return;
        }
        if ((!canBeNull && (id == null)) || id.isNullUUID()) {
            throw new CmsIllegalArgumentException(Messages.get().container(Messages.ERR_INVALID_UUID_1, id));
        }
    }
907578
public static void validateNotNull( Object object, String identifier )
        throws PostConditionException
    {
        if( object == null )
        {
            throw new PostConditionException( identifier + " was NULL." );
        }
    }
676026
public Integer getAndIncrementIDSeq(final String id) {
        Validate.notNull(id, "ID cannot be null");
        Integer count = this.idCounts.get(id);
        if (count == null) {
            count = Integer.valueOf(1);
        }
        this.idCounts.put(id, Integer.valueOf(count.intValue() + 1));
        return count;
    }
630755
public T setId(int id) {
    Preconditions.checkState(this.id == null);
    this.id = id;
    return (T) this;
  }
14891
public K find(final V id) {
        final V keyValue = keyForValue(id);
        
        if (inverse.containsKey(keyValue)) {
            return inverse.get(keyValue);
        }
        
        if (log.isDebugEnabled()) {
        	log.debug("Enum with value " + id + " not found");
        }
        
        return null;
    }
15858
public Element getIdElement(String id) {
    WeakReference<Element> ref = objWithId.get(id);
    return (ref != null) ? ref.get() : null;
  }
434992
@InterfaceAudience.Private
    public static boolean isValidDocumentId(String id) {
        // http://wiki.apache.org/couchdb/HTTP_Document_API#Documents
        if (id == null || id.length() == 0)
            return false;
        if (id.charAt(0) == '_')
            return (id.startsWith("_design/"));
        return true;
        // "_local/*" is not a valid document ID.
        // Local docs have their own API and shouldn't get here.
    }
1126763
public static boolean isValidId(String id) {
		if(id == null) return false;
		int len = id.length();
		if(len == 0) return false;
		// First character must be [A-Za-z]
		char ch = id.charAt(0);
		if(
			(ch<'A' || ch>'Z')
			&& (ch<'a' || ch>'z')
		) {
			return false;
		}
		// Remaining characters must match [A-Za-z0-9:_.-]
		for(int i = 1; i < len; i++) {
			if(
				(ch < 'A' || ch > 'Z')
				&& (ch < 'a' || ch > 'z')
				&& (ch < '0' || ch > '9')
				&& ch != ':'
				&& ch != '_'
				&& ch != '.'
				&& ch != '-'
			) {
				return false;
			}
		}
		return true;
	}
780588
public boolean isCurrentSpan(String id) {
        TraceState ts = traceState.get();

        if (id != null && ts != null) {
            boolean spanFound = ts.peekId().equals(id);
            if (log.isLoggable(Level.FINEST)) {
                log.finest("Is current span id = " + id + "? " + spanFound);
            }
            return spanFound;
        }

        return false;
    }
672205
public void setHtmlElementId(String id) {
		htmlElementId = id;
		mapWidget.setHtmlElement(DOM.getElementById(id));
		mapWidget.draw();
	}
903713
public static Expression id(String id) {
    CodeChunkUtils.checkId(id);
    return Leaf.create(id, /* isCheap= */ true);
  }
559804
public boolean contains(String id) {
        assertNotEmpty(id, "id");
        InputStream response = null;
        try {
            response = couchDbClient.head(new DatabaseURIHelper(dbUri).documentUri(id));
        } catch (NoDocumentException e) {
            return false;
        } finally {
            close(response);
        }
        return true;
    }
753723
function isNull(value, message, id) {
    if (message === void 0) { message = ''; }
    if (id === void 0) { id = ''; }
    if (this.enabled && value !== null) {
        throw ValueException.unexpectedValue(assertionTypes.IS_NULL, value, null, message, id);
    }
}
742551
static void checkId(String id) {
    if (!ID.matcher(id).matches()) {
      throw new IllegalArgumentException(String.format("not a valid js identifier: %s", id));
    }
  }
1163563
public static boolean isKnownById(int id) {
        final String hexId = Utils.supplyZero(Integer.toHexString(id).toUpperCase(), 4);
        
        String code = messageResolver.getMessage(String.format("locale.%s.code", hexId));
        return Utils.isNotEmpty(code);
    }
583741
protected void setId(String id) {
		if (!StringUtils.hasText(id)) {
			id = null;
		}
		this.id = id;
	}
25538
@Transactional
    public boolean isPropertyNull(PK id, SingularAttribute<E, ?> property) {
        checkNotNull(id, "The id cannot be null");
        checkNotNull(property, "The property cannot be null");
        CriteriaBuilder builder = entityManager.getCriteriaBuilder();
        CriteriaQuery<Long> criteriaQuery = builder.createQuery(Long.class);
        Root<E> root = criteriaQuery.from(type);
        criteriaQuery = criteriaQuery.select(builder.count(root));

        // predicate
        Predicate idPredicate = builder.equal(root.get("id"), id);
        Predicate isNullPredicate = builder.isNull(root.get(property));
        criteriaQuery = criteriaQuery.where(jpaUtil.andPredicate(builder, idPredicate, isNullPredicate));

        TypedQuery<Long> typedQuery = entityManager.createQuery(criteriaQuery);
        return typedQuery.getSingleResult().intValue() == 1;
    }