LdapTools\Utilities\TSProperty::getEncodedValueForProp PHP Метод

getEncodedValueForProp() защищенный Метод

Based on the property name/value in question, get its encoded form.
protected getEncodedValueForProp ( string $propName, string | integer $propValue ) : string
$propName string
$propValue string | integer
Результат string
    protected function getEncodedValueForProp($propName, $propValue)
    {
        if (in_array($propName, $this->propTypes['string'])) {
            # Simple strings are null terminated. Unsure if this is needed or simply a product of how ADUC does stuff?
            $value = $this->encodePropValue($propValue . "", true);
        } elseif (in_array($propName, $this->propTypes['time'])) {
            # Needs to be in microseconds (assuming it is in minute format)...
            $value = $this->encodePropValue($propValue * self::TIME_CONVERSION);
        } else {
            $value = $this->encodePropValue($propValue);
        }
        return $value;
    }