All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.umlg.runtime.domain.ocl.OclInvalidInstance Maven / Gradle / Ivy

There is a newer version: 2.0.15
Show newest version
package org.umlg.runtime.domain.ocl;


public final class OclInvalidInstance implements OclInvalid {
 
	public final static OclInvalid INSTANCE = new OclInvalidInstance();
	
	private OclInvalidInstance() {
	}

	@Override
	public boolean equals(Object object) {
		return object == this;
	}

	@Override
	public boolean notEquals(Object object) {
		return object != this;
	}

	@Override
	public Boolean oclIsNew() {
		return false;
	}

	@Override
	public Boolean oclIsUndefined() {
		return true;
	}

	@Override
	public Boolean oclIsInvalid() {
		return true;
	}

	@SuppressWarnings("unchecked")
	@Override
	public  T oclAsType(T classifier) {
		return (T)this;
	}

	@Override
	public Boolean oclIsTypeOf(Object object) {
		return object == this;
	}

	/**
	 * All oclInvalid conforms to all types
	 */
	@Override
	public Boolean oclIsKindOf(Object object) {
		return true;
	}

	@Override
	public Boolean oclIsInState(OclState state) {
		// TODO
		throw new RuntimeException("Not implemented");
	}

	@SuppressWarnings("unchecked")
	@Override
	public Class oclType() {
		return OclInvalid.class;
	}

	@Override
	public String oclLocale() {
		// TODO
		throw new RuntimeException("Not implemented");
	}
	
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy