Gets the current {@link PropertyState} of a given {@link Attribute}.

@param attribute to get
@return the state of the attribute
775554
public PropertyState getState(Attribute<E, ?> attribute) {
        if (stateless) {
            return null;
        }
        PropertyState state = attribute.getPropertyState().get(entity);
        return state == null ? PropertyState.FETCH : state;
    }
448472
protected byte getAttributePresentity(char attributeType) {
		if (!rfc3489CompatibilityMode) {
			return O;
		}

		byte msgIndex = -1;
		byte attributeIndex = -1;

		switch (messageType) {
		case BINDING_REQUEST:
			msgIndex = BINDING_REQUEST_PRESENTITY_INDEX;
			break;
		case BINDING_SUCCESS_RESPONSE:
			msgIndex = BINDING_RESPONSE_PRESENTITY_INDEX;
			break;
		case BINDING_ERROR_RESPONSE:
			msgIndex = BINDING_ERROR_RESPONSE_PRESENTITY_INDEX;
			break;
		case SHARED_SECRET_REQUEST:
			msgIndex = SHARED_SECRET_REQUEST_PRESENTITY_INDEX;
			break;
		case SHARED_SECRET_RESPONSE:
			msgIndex = SHARED_SECRET_RESPONSE_PRESENTITY_INDEX;
			break;
		case SHARED_SECRET_ERROR_RESPONSE:
			msgIndex = SHARED_SECRET_ERROR_RESPONSE_PRESENTITY_INDEX;
			break;
		case ALLOCATE_REQUEST:
			msgIndex = ALLOCATE_REQUEST_PRESENTITY_INDEX;
			break;
		case REFRESH_REQUEST:
			msgIndex = REFRESH_REQUEST_PRESENTITY_INDEX;
			break;
		case CHANNELBIND_REQUEST:
			msgIndex = CHANNELBIND_REQUEST_PRESENTITY_INDEX;
			break;
		case SEND_INDICATION:
			msgIndex = SEND_INDICATION_PRESENTITY_INDEX;
			break;
		case DATA_INDICATION:
			msgIndex = DATA_INDICATION_PRESENTITY_INDEX;
			break;
		default:
			if (logger.isDebugEnabled()) {
				logger.debug("Attribute presentity not defined for STUN " + "message type: " + ((int) messageType) + ". Will assume optional.");
			}
			return O;
		}

		switch (attributeType) {
		case StunAttribute.MAPPED_ADDRESS:
			attributeIndex = MAPPED_ADDRESS_PRESENTITY_INDEX;
			break;
		case StunAttribute.RESPONSE_ADDRESS:
			attributeIndex = RESPONSE_ADDRESS_PRESENTITY_INDEX;
			break;
		case StunAttribute.CHANGE_REQUEST:
			attributeIndex = CHANGE_REQUEST_PRESENTITY_INDEX;
			break;
		case StunAttribute.SOURCE_ADDRESS:
			attributeIndex = SOURCE_ADDRESS_PRESENTITY_INDEX;
			break;
		case StunAttribute.CHANGED_ADDRESS:
			attributeIndex = CHANGED_ADDRESS_PRESENTITY_INDEX;
			break;
		case StunAttribute.USERNAME:
			attributeIndex = USERNAME_PRESENTITY_INDEX;
			break;
		case StunAttribute.PASSWORD:
			attributeIndex = PASSWORD_PRESENTITY_INDEX;
			break;
		case StunAttribute.MESSAGE_INTEGRITY:
			attributeIndex = MESSAGE_INTEGRITY_PRESENTITY_INDEX;
			break;
		case StunAttribute.ERROR_CODE:
			attributeIndex = ERROR_CODE_PRESENTITY_INDEX;
			break;
		case StunAttribute.UNKNOWN_ATTRIBUTES:
			attributeIndex = UNKNOWN_ATTRIBUTES_PRESENTITY_INDEX;
			break;
		case StunAttribute.REFLECTED_FROM:
			attributeIndex = REFLECTED_FROM_PRESENTITY_INDEX;
			break;
		case StunAttribute.XOR_MAPPED_ADDRESS:
			attributeIndex = XOR_MAPPED_ADDRESS_PRESENTITY_INDEX;
			break;
		case StunAttribute.XOR_ONLY:
			attributeIndex = XOR_ONLY_PRESENTITY_INDEX;
			break;
		case StunAttribute.SOFTWARE:
			attributeIndex = SOFTWARE_PRESENTITY_INDEX;
			break;
		case StunAttribute.ALTERNATE_SERVER:
			attributeIndex = ALTERNATE_SERVER_PRESENTITY_INDEX;
			break;
		case StunAttribute.REALM:
			attributeIndex = REALM_PRESENTITY_INDEX;
			break;
		case StunAttribute.NONCE:
			attributeIndex = NONCE_PRESENTITY_INDEX;
			break;
		case StunAttribute.FINGERPRINT:
			attributeIndex = FINGERPRINT_PRESENTITY_INDEX;
			break;
		case StunAttribute.CHANNEL_NUMBER:
			attributeIndex = CHANNEL_NUMBER_PRESENTITY_INDEX;
			break;
		case StunAttribute.LIFETIME:
			attributeIndex = LIFETIME_PRESENTITY_INDEX;
			break;
		case StunAttribute.XOR_PEER_ADDRESS:
			attributeIndex = XOR_PEER_ADDRESS_PRESENTITY_INDEX;
			break;
		case StunAttribute.DATA:
			attributeIndex = DATA_PRESENTITY_INDEX;
			break;
		case StunAttribute.XOR_RELAYED_ADDRESS:
			attributeIndex = XOR_RELAYED_ADDRESS_PRESENTITY_INDEX;
			break;
		case StunAttribute.EVEN_PORT:
			attributeIndex = EVEN_PORT_PRESENTITY_INDEX;
			break;
		case StunAttribute.REQUESTED_TRANSPORT:
			attributeIndex = REQUESTED_TRANSPORT_PRESENTITY_INDEX;
			break;
		case StunAttribute.DONT_FRAGMENT:
			attributeIndex = DONT_FRAGMENT_PRESENTITY_INDEX;
			break;
		case StunAttribute.RESERVATION_TOKEN:
			attributeIndex = RESERVATION_TOKEN_PRESENTITY_INDEX;
			break;
		default:
			attributeIndex = UNKNOWN_OPTIONAL_ATTRIBUTES_PRESENTITY_INDEX;
			break;
		}

		return attributePresentities[attributeIndex][msgIndex];
	}
1369845
@Override
	public Attribute getAttribute(int index) {
		Attribute attribute = attributes.get(index - 1);
		return attribute;
	}
133489
public JcProperty atttribute(String name) {
		if (this.delegate != null)
			return this.delegate.atttribute(name);
		JcProperty ret = checkField_getJcVal(name, JcProperty.class);
		QueryRecorder.recordInvocationReplace(this, ret, "atttribute");
		return ret;
	}
1316514
public static Object getAttribute(String name)
  {
    ClassLoader loader = Thread.currentThread().getContextClassLoader();

    return getAttribute(name, loader);
  }
776593
public String getAttributeValue(final String name) {
        final List<Attribute> attributes = Collections.synchronizedList(getAttributes());
        for (int i = 0; i < attributes.size(); i++) {
            final Attribute a = attributes.get(i);

            if (a.getName() != null && a.getName().equals(name)) {
                return a.getValue();
            }
        }
        return null;
    }
305970
@SuppressWarnings("unchecked")
   public <T> Attribute<T> attribute(String name) {
      return (Attribute<T>) this.attributes.get(name);
   }
156251
@SuppressWarnings("unchecked")
    public <T> T attribute(String attribute) {
        return (T) servletRequest.getAttribute(attribute);
    }
1314105
@Override
    public void visit(final Attribute attribute) {
        if (type.isEmpty() || type.equals(attribute.getString())) {
            for (final GedObject gedObject : attribute.getAttributes()) {
                gedObject.accept(this);
                if (!dateString.isEmpty()) {
                    break;
                }
            }
        }
    }
1297262
public <T> T getAttribute(String attrName, Class<T> clazz) {
        Lock lock = lockForRead();
        try {
            return MapUtils.getValue(attributes, attrName, clazz);
        } finally {
            lock.unlock();
        }
    }
1168090
public Object getAttributeValue(FeatureDescriptor feature,
                                    String attributeName) {

        if (feature == null || attributeName == null) {
            return null;
        }

        return feature.getValue(attributeName);
    }
988669
public Attribute getAttribute4Attribute(final String _attributeName)
    {
        final OneSelect oneselect = this.attr2OneSelect.get(_attributeName);
        return oneselect == null ? null : oneselect.getAttribute();
    }
693488
public static boolean isHaveAttribute(AttributeSet attrs, String attribute) {
        return attrs.getAttributeValue(Ui.androidStyleNameSpace, attribute) != null;
    }
866584
public Object getAttribute(String key) {
        Objects.requireNonNull(key, Required.KEY.toString());
        return this.attributes.get(key);
    }
993249
public Object getAttribute(String attrName) {
        Lock lock = lockForRead();
        try {
            return attributes != null ? attributes.get(attrName) : null;
        } finally {
            lock.unlock();
        }
    }
1356085
public Bindings getBindings(String attribute) {
        if (_bindings == null || attribute == null) return null;

        Iterator iter = _bindings.iterator();
        Bindings bind;
        String canonAttrib = canonicalize(attribute);
        String tmpCanonAttrib = null;
        while(iter.hasNext()) {
            bind = (Bindings)iter.next();
	    tmpCanonAttrib = canonicalize(bind.getAttribute());
            if (tmpCanonAttrib.equalsIgnoreCase(canonAttrib)) {
                return bind;
            }
        }
        return null;
    }
589340
@Nullable
  public final synchronized Object getAttribute(String view, String attribute) {
    if (attributes == null) {
      return null;
    }
    return attributes.get(view, attribute);
  }