Lines Matching refs:source

818      * @param string $source
824 function encodeDER($source, $mapping, $special = array()) argument
827 return $this->_encode_der($source, $mapping, null, $special);
833 * @param string $source
840 function _encode_der($source, $mapping, $idx = null, $special = array()) argument
842 if ($source instanceof Element) {
843 return $source->element;
847 if (isset($mapping['default']) && $source === $mapping['default']) {
853 $source = call_user_func($special[$idx], $source);
870 foreach ($source as $content) {
891 if (!array_key_exists($key, $source)) {
898 $temp = $this->_encode_der($source[$key], $child, $key, $special);
935 if (!isset($source[$key])) {
939 $temp = $this->_encode_der($source[$key], $child, $key, $special);
976 if (is_numeric($source)) {
977 $source = new BigInteger($source);
979 $value = $source->toBytes(true);
981 $value = array_search($source, $mapping['mapping']);
996 $date = new DateTime($source, new DateTimeZone('GMT'));
1004 if (in_array($mapping['mapping'][$i], $source)) {
1036 $value = base64_decode($source);
1039 $value = $this->_encodeOID($source);
1048 case !isset($source):
1050 case is_int($source):
1051 case $source instanceof BigInteger:
1052 …return $this->_encode_der($source, array('type' => self::TYPE_INTEGER) + $mapping, null, $special);
1053 case is_float($source):
1054 … return $this->_encode_der($source, array('type' => self::TYPE_REAL) + $mapping, null, $special);
1055 case is_bool($source):
1056 …return $this->_encode_der($source, array('type' => self::TYPE_BOOLEAN) + $mapping, null, $special);
1057 case is_array($source) && count($source) == 1:
1058 $typename = implode('', array_keys($source));
1061 …return $this->_encode_der($source[$typename], array('type' => $outtype) + $mapping, null, $special…
1077 return $this->_encode_der($source, $filters + $mapping, null, $special);
1092 $value = $source;
1095 $value = $source ? "\xFF" : "\x00";
1197 * @param string $source
1200 function _encodeOID($source) argument
1209 $oid = preg_match('#(?:\d+\.)+#', $source) ? $source : array_search($source, $this->oids);