Return true if the agent has the posture indicated in the atribut of the
class, in another case it returns false;

@param agent
@return
965874
@Override
    public boolean simpleEvaluation(Agent agent) {
        Node device = agent.getAgentsAppState().getDevicesAppState().getDevice(deviceId);
        if (device != null) {
            PHATDoorSensor psControl = device.getControl(PHATDoorSensor.class);
            if (psControl != null) {
                DoorData doorData = psControl.getDoorData();
                if(doorData != null) {
                    return (doorState.equals("ON") && psControl.getDoorData().isOpened()) ||
                            (doorState.equals("OFF") && !psControl.getDoorData().isOpened());
                }
            }
        }
        return false;
    }
647092
@Override
    public boolean simpleEvaluation(Agent currentAgent) {
        Agent agent = currentAgent;
        if (bodyId != null) {
            agent = agent.getAgentsAppState().getAgent(bodyId);
            if(agent == null) {
                logger.log(Level.SEVERE, "Body {0} does not exists!", new Object[]{bodyId});
                return false;
            }
        }
        if(agent instanceof HumanAgent) {
            return ((HumanAgent)agent).getBodyPosture().name().equals(bodyState);
        }
        return false;
    }
94674
private boolean hasChangedPosition(I_CmsDropTarget target) {

        if ((m_currentTarget != target) || (m_currentIndex != target.getPlaceholderIndex())) {
            m_currentTarget = target;
            m_currentIndex = target.getPlaceholderIndex();
            return true;
        }
        return false;
    }
595011
public boolean isRoleMapped(Long pRoleId){
       if(userRoles == null || userRoles.length == 0){
            return false;
        }
        for(int i=0; i<userRoles.length; i++){
            if(userRoles[i].getId().longValue() == pRoleId.longValue()){
                return true;
            }
        }
        return false;
    }
14826
public boolean hasPrimitivePeer() {
        if (mObjectClass == Integer.class ||
            mObjectClass == Boolean.class ||
            mObjectClass == Byte.class ||
            mObjectClass == Character.class ||
            mObjectClass == Short.class ||
            mObjectClass == Long.class ||
            mObjectClass == Float.class ||
            mObjectClass == Double.class ||
            mObjectClass == Void.class) {

            return true;
        }

        return false;
    }
545654
@Check
	protected void checkModifiers(SarlAgent agent) {
		this.agentModifierValidator.checkModifiers(agent,
				MessageFormat.format(Messages.SARLValidator_9, agent.getName()));
	}
623090
public boolean hasRole(CmsObject cms, CmsRole role) {

        return m_securityManager.hasRole(cms.getRequestContext(), cms.getRequestContext().getCurrentUser(), role);
    }
19629
public boolean isUserInRole(String role)
    {
        if (_servletHolder!=null)
            role=_servletHolder.getUserRoleLink(role);
        return _httpRequest.isUserInRole(role);
    }
1042919
public boolean isSet(String propName) {
        if (propName.equals("method")) {
            return isSetMethod();
        }
        if (propName.equals("object")) {
            return isSetObject();
        }
        if (propName.equals("attribute")) {
            return isSetAttribute();
        }
        return false;
    }
226056
protected boolean cannotInstantiate(Class<?> actionClass) {
		return actionClass.isAnnotation() || actionClass.isInterface() || actionClass.isEnum()
				|| (actionClass.getModifiers() & Modifier.ABSTRACT) != 0 || actionClass.isAnonymousClass();
	}
1037470
public static boolean hasRoleOn(String role, String simpleScope) {
        return securitySupport.hasRole(role, new SimpleScope(simpleScope));
    }
138769
@Override
    public boolean isUserInRole(String role) {
        ServletRESTRequestImpl ret = castRequest();
        if (ret != null)
            return ret.isUserInRole(role);
        return false;
    }
606869
protected boolean isValidAgentName() {
		if (this.lastAgentNameError != null) {
			final boolean isValid = Strings.isNullOrEmpty(this.lastAgentNameError);
			if (!isValid) {
				setErrorMessage(this.lastAgentNameError);
			}
			return isValid;
		}
		final String name = this.agentNameTextField.getText();
		if (Strings.isNullOrEmpty(name)) {
			this.lastAgentNameError = Messages.MainLaunchConfigurationTab_2;
			setErrorMessage(this.lastAgentNameError);
			return false;
		}
		if (!isAgentNameDefined(name)) {
			this.lastAgentNameError = MessageFormat.format(Messages.MainLaunchConfigurationTab_8, name);
			setErrorMessage(this.lastAgentNameError);
			return false;
		}
		this.lastAgentNameError = Utilities.EMPTY_STRING;
		return true;
	}
953322
public final boolean hasProperty(final String property) {
    final String val = properties.get(property);
    if (val == null)
      return false;
    if (val.isEmpty())
      return false;
    return true;
  }
736335
public static boolean hasBody(Response response) {
    // HEAD requests never yield a body regardless of the response headers.
    if (response.request().method().equals("HEAD")) {
      return false;
    }

    int responseCode = response.code();
    if ((responseCode < HTTP_CONTINUE || responseCode >= 200)
        && responseCode != HTTP_NO_CONTENT
        && responseCode != HTTP_NOT_MODIFIED) {
      return true;
    }

    // If the Content-Length or Transfer-Encoding headers disagree with the response code, the
    // response is malformed. For best compatibility, we honor the headers.
    if (contentLength(response) != -1
        || "chunked".equalsIgnoreCase(response.header("Transfer-Encoding"))) {
      return true;
    }

    return false;
  }
890540
public static Automaton getDeepestAutomaton(Agent agent) {
        Automaton a1 = agent.getAutomaton();
        Automaton a2 = agent.getAutomaton().currentState;
        while (a2 != null || !(a2 instanceof SimpleState)) {
            a1 = a2;
            a2 = a2.currentState;

        }
        return a1;

    }
1292870
public boolean hasRoleGrant(Grant grant,String role){
        if (grant == null) throw new IllegalArgumentException("grant cannot be null");
        if (role == null) throw new IllegalArgumentException("role cannot be null");
        Set<String> roles = rolesGrants.get(grant);
        return roles!=null&&roles.contains(role);
    }