Passed
Pull Request — master (#3)
by Timothy
06:14
created

FabricOUIdentifier   A

Complexity

Total Complexity 5

Size/Duplication

Total Lines 91
Duplicated Lines 0 %

Importance

Changes 1
Bugs 1 Features 1
Metric Value
c 1
b 1
f 1
dl 0
loc 91
rs 10
wmc 5
1
<?php
2
# Generated by the protocol buffer compiler.  DO NOT EDIT!
3
# source: msp/msp_config.proto
4
5
namespace Hyperledger\Fabric\Protos\MSP;
6
7
use Google\Protobuf\Internal\GPBType;
8
use Google\Protobuf\Internal\RepeatedField;
9
use Google\Protobuf\Internal\GPBUtil;
10
11
/**
12
 * FabricOUIdentifier represents an organizational unit and
13
 * its related chain of trust identifier.
14
 *
15
 * Generated from protobuf message <code>msp.FabricOUIdentifier</code>
16
 */
17
class FabricOUIdentifier extends \Google\Protobuf\Internal\Message
18
{
19
    /**
20
     * Certificate represents the second certificate in a certification chain.
21
     * (Notice that the first certificate in a certification chain is supposed
22
     * to be the certificate of an identity).
23
     * It must correspond to the certificate of root or intermediate CA
24
     * recognized by the MSP this message belongs to.
25
     * Starting from this certificate, a certification chain is computed
26
     * and boud to the OrganizationUnitIdentifier specified
27
     *
28
     * Generated from protobuf field <code>bytes certificate = 1;</code>
29
     */
30
    private $certificate = '';
31
    /**
32
     * OrganizationUnitIdentifier defines the organizational unit under the
33
     * MSP identified with MSPIdentifier
34
     *
35
     * Generated from protobuf field <code>string organizational_unit_identifier = 2;</code>
36
     */
37
    private $organizational_unit_identifier = '';
38
39
    public function __construct() {
40
        \GPBMetadata\Msp\MspConfig::initOnce();
41
        parent::__construct();
42
    }
43
44
    /**
45
     * Certificate represents the second certificate in a certification chain.
46
     * (Notice that the first certificate in a certification chain is supposed
47
     * to be the certificate of an identity).
48
     * It must correspond to the certificate of root or intermediate CA
49
     * recognized by the MSP this message belongs to.
50
     * Starting from this certificate, a certification chain is computed
51
     * and boud to the OrganizationUnitIdentifier specified
52
     *
53
     * Generated from protobuf field <code>bytes certificate = 1;</code>
54
     * @return string
55
     */
56
    public function getCertificate()
57
    {
58
        return $this->certificate;
59
    }
60
61
    /**
62
     * Certificate represents the second certificate in a certification chain.
63
     * (Notice that the first certificate in a certification chain is supposed
64
     * to be the certificate of an identity).
65
     * It must correspond to the certificate of root or intermediate CA
66
     * recognized by the MSP this message belongs to.
67
     * Starting from this certificate, a certification chain is computed
68
     * and boud to the OrganizationUnitIdentifier specified
69
     *
70
     * Generated from protobuf field <code>bytes certificate = 1;</code>
71
     * @param string $var
72
     * @return $this
73
     */
74
    public function setCertificate($var)
75
    {
76
        GPBUtil::checkString($var, False);
77
        $this->certificate = $var;
78
79
        return $this;
80
    }
81
82
    /**
83
     * OrganizationUnitIdentifier defines the organizational unit under the
84
     * MSP identified with MSPIdentifier
85
     *
86
     * Generated from protobuf field <code>string organizational_unit_identifier = 2;</code>
87
     * @return string
88
     */
89
    public function getOrganizationalUnitIdentifier()
90
    {
91
        return $this->organizational_unit_identifier;
92
    }
93
94
    /**
95
     * OrganizationUnitIdentifier defines the organizational unit under the
96
     * MSP identified with MSPIdentifier
97
     *
98
     * Generated from protobuf field <code>string organizational_unit_identifier = 2;</code>
99
     * @param string $var
100
     * @return $this
101
     */
102
    public function setOrganizationalUnitIdentifier($var)
103
    {
104
        GPBUtil::checkString($var, True);
105
        $this->organizational_unit_identifier = $var;
106
107
        return $this;
108
    }
109
110
}
111
112