public static function attrNameToOID(string $name): string
    {
        // if already in OID form
        if (preg_match('/^[0-9]+(?:\.[0-9]+)*$/', $name)) {
            return $name;
        }
        $map = self::_oidReverseMap();
        $k = strtolower($name);
        if (!isset($map[$k])) {
            throw new \OutOfBoundsException("No OID for $name.");
        }
        return $map[$k];
    }
public static function attrNameToOID(string $name): string
    {
        // if already in OID form
        if (preg_match('/^[0-9]+(?:\.[0-9]+)*$/', $name)) {
            return $name;
        }
        $map = self::_oidReverseMap();
        $k = strtolower($name);
        if (!isset($map[$k])) {
            throw new \OutOfBoundsException("No OID for $name.");
        }
        return $map[$k];
    }
public static function attrNameToOID ( string $ name ) : string { // if already in OID form if ( preg_match ( '/^[0-9]+(?:\.[0-9]+)*$/' , $ name ) ) { return $ name ; } $ map = self :: _oidReverseMap ( ) ; $ k = strtolower ( $ name ) ; if ( ! isset ( $ map [ $ k ] ) ) { throw new \ OutOfBoundsException ( "No OID for $name." ) ; } return $ map [ $ k ] ; }
Convert attribute name to OID.

@param string $name Primary attribute name or an alias
@throws \OutOfBoundsException
@return string OID in dotted format
Convert attribute name to OID .