/*
@see PropertyCoder#decodeProperty
326932
Object decodeProperty(MsgDestEncodingUtilsImpl.PropertyInputStream stream) throws JMSException {
    if (TraceComponent.isAnyTracingEnabled() && tc.isEntryEnabled()) SibTr.entry(this, tc, "decodeProperty", stream);

    // The PhantomPropertyCoder does not encode/decode properties so this method should
    // never be called. If it is, throw an informative JMSException.
    JMSException e = (JMSException)JmsErrorUtils.newThrowable(JMSException.class
                                                             ,"INTERNAL_ERROR_CWSIA0362"
                                                             ,new Object[] {"PhantomPropertyCoder.decodeProperty#1", shortName, longName}
                                                             ,null
                                                             ,null   // FFDC it separately so we can dump the stream
                                                             ,null
                                                             ,tc);
    FFDCFilter.processException(e, "com.ibm.ws.sib.api.jms.PhantomPropertyCoder","PhantomPropertyCoder.decodeProperty#1",
      new Object[] {shortName, longName, stream.toDebugString()});
    throw e;
  }
704694
@Override
    public Object getPropertyValue(PropertyInfo propInfo) throws Exception {
        Object obj = registeredProperties == null ? null : registeredProperties.get(propInfo.getId());

        if (obj instanceof PropertyProxy) {
            Object value = ((PropertyProxy) obj).getValue();
            return value instanceof String ? propInfo.getPropertyType().getSerializer().deserialize((String) value) : value;
        } else {
            return obj == null ? null : propInfo.getPropertyValue(obj, obj == this);
        }
    }
1104190
@Override
    public String decode( String encodedText ) {
        if (encodedText == null) return null;
        StringBuilder sb = new StringBuilder();
        CharacterIterator iter = new StringCharacterIterator(encodedText);
        for (char c = iter.first(); c != CharacterIterator.DONE; c = iter.next()) {
            if (c == '&') {
                int index = iter.getIndex();

                do {
                    // CHECKSTYLE IGNORE check FOR NEXT 1 LINES
                    c = iter.next();
                } while (c != CharacterIterator.DONE && c != ';');

                // We found a closing semicolon
                if (c == ';') {
                    String s = encodedText.substring(index + 1, iter.getIndex());

                    if (SPECIAL_ENTITIES.containsKey(s)) {
                        sb.append(SPECIAL_ENTITIES.get(s));
                        continue;

                    }

                    if (s.length() > 0 && s.charAt(0) == '#') {
                        try {
                            sb.append((char)Short.parseShort(s.substring(1, s.length())));
                            continue;
                        } catch (NumberFormatException nfe) {
                            // This is possible in malformed encodings, but let it fall through
                        }
                    }
                }

                // Malformed encoding, restore state and pass poorly encoded data back
                // CHECKSTYLE IGNORE check FOR NEXT 1 LINES
                c = '&';
                iter.setIndex(index);
            }

            sb.append(c);

        }
        return sb.toString();
    }
1068462
function decodify (featureCollection, code, properties) {
  var feature = find(featureCollection.features, {'id': code});

  if (feature) {
    feature.properties = properties;
  }

  return feature;
}
279681
@Override
    public Object getProperty(String propertyId)
            throws SAXNotRecognizedException {
        if ((PROPERTY + "declaration-handler").equals(propertyId)) {
            return (declHandler == base) ? null : declHandler;
        }

        if ((PROPERTY + "lexical-handler").equals(propertyId)) {
            return (lexicalHandler == base) ? null : lexicalHandler;
        }

        // unknown properties
        throw new SAXNotRecognizedException(propertyId);
    }
108797
public byte[] readProperty(Destination dst, int objIndex, int propID, int start,
		int elements) throws KNXTimeoutException, KNXRemoteException,
		KNXDisconnectException, KNXLinkClosedException
	{
		if (objIndex < 0 || objIndex > 255 || propID < 0 || propID > 255 || start < 0
			|| start > 0xFFF || elements < 0 || elements > 15)
			throw new KNXIllegalArgumentException("argument value out of range");
		final byte[] asdu = new byte[4];
		asdu[0] = (byte) objIndex;
		asdu[1] = (byte) propID;
		asdu[2] = (byte) ((elements << 4) | ((start >>> 8) & 0xF));
		asdu[3] = (byte) start;

		final byte[] apdu = sendWait2(dst, priority, DataUnitBuilder.createAPDU(
			PROPERTY_READ, asdu), PROPERTY_RESPONSE, 4, 14);
		// check if number of elements is 0, indicates access problem
		final int number = (apdu[4] & 0xFF) >>> 4;
		if (number == 0)
			throw new KNXRemoteException("property access failed/forbidden");
		if (number != elements)
			throw new KNXInvalidResponseException("number of elements differ");
		final byte[] prop = new byte[apdu.length - 6];
		for (int i = 0; i < prop.length; ++i)
			prop[i] = apdu[i + 6];
		return prop;
	}
68160
@SuppressWarnings("unchecked")
    @Override
    public <T> T getProperty(Object key) {
        return (T) properties.get(key);
    }
565421
static Object decode(String s) {
    byte[] bytes = Base64.base64ToByteArray(s);
    ObjectInputStream objectInputStream;
    try {
      objectInputStream = new ObjectInputStream(
          new ByteArrayInputStream(bytes));
      return objectInputStream.readObject();
    } catch (IOException | ClassNotFoundException e) {
      log.error(e);
      return null;
    }
  }
395871
public VALUEFROM decodeFromRaw(Object o) {
        if (o == null && !isOptional()) return null;
        return decodeFromRawInternal(o);
    }
412490
void encodeProperty(ByteArrayOutputStream baos, Object value) throws JMSException {
    if (TraceComponent.isAnyTracingEnabled() && tc.isEntryEnabled()) SibTr.entry(this, tc, "encodeProperty", new Object[]{baos, value});

    super.encodeProperty(baos, value.toString());  // Just call the superclass, with the Integer 'toString'ed

    if (TraceComponent.isAnyTracingEnabled() && tc.isEntryEnabled()) SibTr.exit(this, tc, "encodeProperty");
  }
1106501
public String getProperty(String key, String defaultValue) {
        return mProperties.getProperty(key, defaultValue);
    }
135256
@Override
	public String getProperty(String key, String aDefault)
	{
		String retval = null;
		
		
		retval = getProperty(key,false);
		if (retval == null || retval.length() == 0)
		{
			retval = aDefault;
		}

		return Cryption.interpret(retval);

	}
1197892
@SuppressWarnings("unchecked")
	@Override
	public <T> T getProperty(Object key, Class<T> clazz) {
	    return (T)getProperty(key);
	}
1103397
public Object decode(byte[] frame, int offset, int indirect, JMFMessageData msg) throws JMFMessageCorruptionException {
    if (TraceComponent.isAnyTracingEnabled() && tc.isEntryEnabled()) JmfTr.entry(this, tc, "decode", new Object[]{frame, offset, indirect, msg});
    Object result = null;
    if (indirect < 0) {
      indirect = this.indirect;
    }
    if (indirect > 0) {
      result = new JSVaryingListImpl(frame, offset, element, indirect);
    }
    else if (varying) {
      result = new JSVaryingListImpl(frame, offset, element, 0);
    }
    else {
      result = new JSFixedListImpl(frame, offset, element);
    }
    if (TraceComponent.isAnyTracingEnabled() && tc.isEntryEnabled()) JmfTr.exit(this, tc, "decode",  result);
    return result;
  }
313215
private static void decodeTag(String stringTag, Map<TagKey, TagValueWithMetadata> tags) {
    String keyWithValue;
    int firstPropertyIndex = stringTag.indexOf(TAG_PROPERTIES_DELIMITER);
    if (firstPropertyIndex != -1) { // Tag with properties.
      keyWithValue = stringTag.substring(0, firstPropertyIndex);
      // TODO(songya): support decoding tag properties.
    } else { // Tag without properties.
      keyWithValue = stringTag;
    }
    List<String> keyValuePair = TAG_KEY_VALUE_SPLITTER.splitToList(keyWithValue);
    checkArgument(keyValuePair.size() == 2, "Malformed tag " + stringTag);
    TagKey key = TagKey.create(keyValuePair.get(0).trim());
    TagValue value = TagValue.create(keyValuePair.get(1).trim());
    TagValueWithMetadata valueWithMetadata =
        TagValueWithMetadata.create(value, METADATA_UNLIMITED_PROPAGATION);
    tags.put(key, valueWithMetadata);
  }
1273297
function parseProperty (value, propDefinition) {
  // Use default value if value is falsy.
  if (value === undefined || value === null || value === '') {
    value = propDefinition.default;
    if (Array.isArray(value)) { value = value.slice(); }
  }
  // Invoke property type parser.
  return propDefinition.parse(value, propDefinition.default);
}
968365
protected function decode($tsProperty)
    {
        $nameLength = hexdec(substr($tsProperty, 0, 2));

        # 1 data byte is 3 encoded bytes
        $valueLength = hexdec(substr($tsProperty, 2, 2)) * 3;

        $this->valueType = hexdec(substr($tsProperty, 4, 2));
        $this->name = pack('H*', substr($tsProperty, 6, $nameLength));
        $this->value = $this->getDecodedValueForProp($this->name, substr($tsProperty, 6 + $nameLength, $valueLength));
    }