Example usage for java.lang Class equals

List of usage examples for java.lang Class equals

Introduction

In this page you can find the example usage for java.lang Class equals.

Prototype

public boolean equals(Object obj) 

Source Link

Document

Indicates whether some other object is "equal to" this one.

Usage

From source file:cz.zcu.kiv.eegdatabase.logic.controller.list.artifact.AddArtifactValidator.java

@Override
public boolean supports(Class<?> aClass) {
    return aClass.equals(AddArtifactCommand.class); //To change body of implemented methods use File | Settings | File Templates.
}

From source file:cz.zcu.kiv.eegdatabase.logic.controller.list.hardware.AddHardwareValidator.java

public boolean supports(Class clazz) {
    return clazz.equals(AddHardwareCommand.class);
}

From source file:cz.zcu.kiv.eegdatabase.logic.controller.scenario.AddScenarioSchemaValidator.java

public boolean supports(Class clazz) {
    return clazz.equals(AddScenarioSchemaCommand.class);
}

From source file:framework.GlobalHelpers.java

public static Field findInheritedField(Class<?> clazz, String name) {
    Field[] fields = clazz.getDeclaredFields();
    for (Field field : fields) {
        if (field.getName().equals(name)) {
            return field;
        }//  w  ww  .  j  av  a2 s .  c om
    }
    if (!clazz.equals(Object.class)) {
        return findInheritedField(clazz.getSuperclass(), name);
    }
    return null;
}

From source file:org.openmrs.module.appointmentscheduling.validator.AppointmentBlockValidator.java

/**
 * Determines if the command object being submitted is a valid type
 * /*from   w  w w  .  j  a  va 2  s .com*/
 * @see org.springframework.validation.Validator#supports(java.lang.Class)
 */
@SuppressWarnings("unchecked")
public boolean supports(Class c) {
    return c.equals(AppointmentBlock.class);
}

From source file:grails.util.GrailsClassUtils.java

/**
 * Returns true if the specified property in the specified class is of the specified type
 *
 * @param clazz The class which contains the property
 * @param propertyName The property name
 * @param type The type to check//from  w  ww.jav a  2s  . co  m
 *
 * @return A boolean value
 */
public static boolean isPropertyOfType(Class<?> clazz, String propertyName, Class<?> type) {
    try {
        Class<?> propType = getPropertyType(clazz, propertyName);
        return propType != null && propType.equals(type);
    } catch (Exception e) {
        return false;
    }
}

From source file:com.launchkey.example.springmvc.LaunchKeyAuthenticationProvider.java

@Override
public boolean supports(Class<?> aClass) {
    return aClass.equals(UsernamePasswordAuthenticationToken.class);
}

From source file:org.openmrs.module.appointmentscheduling.validator.AppointmentValidator.java

/**
 * Determines if the command object being submitted is a valid type
 * //from  w  ww  . j  a v  a 2 s  .c o m
 * @see org.springframework.validation.Validator#supports(java.lang.Class)
 */
@SuppressWarnings("unchecked")
public boolean supports(Class c) {
    return c.equals(Appointment.class);
}

From source file:cz.zcu.kiv.eegdatabase.logic.controller.person.AddPersonAdditionalParamValueValidator.java

public boolean supports(Class clazz) {
    return clazz.equals(AddPersonAdditionalParamValueCommand.class);
}

From source file:eu.europa.ec.markt.dss.web.controller.preferences.PreferenceFormValidator.java

@Override
public boolean supports(Class<?> clazz) {
    return clazz.equals(PreferenceForm.class);
}