PHP 클래스 LdapTools\Utilities\TSProperty

또한 보기: https://msdn.microsoft.com/en-us/library/ff635169.aspx
또한 보기: http://daduke.org/linux/userparameters.html
저자: Chad Sikorra ([email protected])
파일 보기 프로젝트 열기: ldaptools/ldaptools 1 사용 예제들

보호된 프로퍼티들

프로퍼티 타입 설명
$name The property name.
$propTypes array There are some names that are simple repeats but have 'W' at the end. Not sure as to what that signifies. I cannot find any information on them in Microsoft documentation. However, their values appear to stay in sync with their non 'W' counterparts. But not doing so when manipulating the data manually does not seem to affect anything. This probably needs more investigation.
$value The property value.
$valueType The property value type.

공개 메소드들

메소드 설명
__construct ( string | null $value = null )
getName ( ) : string Get the name for the TSProperty.
getValue ( ) : string | integer Get the value for the TSProperty.
setName ( string $name ) Set the name for the TSProperty.
setValue ( string | integer $value ) Set the value for the TSProperty.
toBinary ( ) : string Convert the TSProperty name/value back to its binary representation for the userParameters blob.

보호된 메소드들

메소드 설명
dec2hex ( integer $int, integer $padLength = 2 ) : string Need to make sure hex values are always an even length, so pad as needed.
decode ( string $tsProperty ) Given a TSProperty blob, decode the name/value/type/etc.
decodePropValue ( string $hex, boolean $string = false ) : string Decode the property by inspecting the nibbles of each blob, checking the control, and adding up the results into a final value.
encodePropValue ( string $value, boolean $string = false ) : string Get the encoded property value as a binary blob.
getDecodedValueForProp ( string $propName, string $propValue ) : string | integer Based on the property name in question, get its actual value from the binary blob value.
getEncodedValueForProp ( string $propName, string | integer $propValue ) : string Based on the property name/value in question, get its encoded form.
getNibbleWithControl ( string $nibbleType, $nibble ) : string Get the nibble value with the control prefixed.
nibbleControl ( string $nibble, string $control ) : string Based on the control, adjust the nibble accordingly.
packBitString ( string $bits, boolean $len ) : string PHP's pack() function has no 'b' or 'B' template. This is a workaround that turns a literal bit-string into a packed byte-string with 8 bits per byte.

메소드 상세

__construct() 공개 메소드

public __construct ( string | null $value = null )
$value string | null Pass binary TSProperty data to construct its object representation.

dec2hex() 보호된 메소드

Need to make sure hex values are always an even length, so pad as needed.
protected dec2hex ( integer $int, integer $padLength = 2 ) : string
$int integer
$padLength integer The hex string must be padded to this length (with zeros).
리턴 string

decode() 보호된 메소드

Given a TSProperty blob, decode the name/value/type/etc.
protected decode ( string $tsProperty )
$tsProperty string

decodePropValue() 보호된 메소드

Decode the property by inspecting the nibbles of each blob, checking the control, and adding up the results into a final value.
protected decodePropValue ( string $hex, boolean $string = false ) : string
$hex string
$string boolean Whether or not this is simple string data.
리턴 string

encodePropValue() 보호된 메소드

Get the encoded property value as a binary blob.
protected encodePropValue ( string $value, boolean $string = false ) : string
$value string
$string boolean
리턴 string

getDecodedValueForProp() 보호된 메소드

Based on the property name in question, get its actual value from the binary blob value.
protected getDecodedValueForProp ( string $propName, string $propValue ) : string | integer
$propName string
$propValue string
리턴 string | integer

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

getName() 공개 메소드

Get the name for the TSProperty.
public getName ( ) : string
리턴 string

getNibbleWithControl() 보호된 메소드

If the nibble dec is <= 9, the control X equals 001011 and Y equals 001110, otherwise if the nibble dec is > 9 the control for X or Y equals 011010. Additionally, if the dec value of the nibble is > 9, then the nibble value must be subtracted by 9 before the final value is constructed.
protected getNibbleWithControl ( string $nibbleType, $nibble ) : string
$nibbleType string Either X or Y
$nibble
리턴 string

getValue() 공개 메소드

Get the value for the TSProperty.
public getValue ( ) : string | integer
리턴 string | integer

nibbleControl() 보호된 메소드

Based on the control, adjust the nibble accordingly.
protected nibbleControl ( string $nibble, string $control ) : string
$nibble string
$control string
리턴 string

packBitString() 보호된 메소드

PHP's pack() function has no 'b' or 'B' template. This is a workaround that turns a literal bit-string into a packed byte-string with 8 bits per byte.
protected packBitString ( string $bits, boolean $len ) : string
$bits string
$len boolean
리턴 string

setName() 공개 메소드

Set the name for the TSProperty.
public setName ( string $name )
$name string

setValue() 공개 메소드

Set the value for the TSProperty.
public setValue ( string | integer $value )
$value string | integer

toBinary() 공개 메소드

Convert the TSProperty name/value back to its binary representation for the userParameters blob.
public toBinary ( ) : string
리턴 string

프로퍼티 상세

$name 보호되어 있는 프로퍼티

The property name.
protected $name

$propTypes 보호되어 있는 프로퍼티

There are some names that are simple repeats but have 'W' at the end. Not sure as to what that signifies. I cannot find any information on them in Microsoft documentation. However, their values appear to stay in sync with their non 'W' counterparts. But not doing so when manipulating the data manually does not seem to affect anything. This probably needs more investigation.
protected array $propTypes
리턴 array

$value 보호되어 있는 프로퍼티

The property value.
protected $value

$valueType 보호되어 있는 프로퍼티

The property value type.
protected $valueType