Documentation ¶
Overview ¶
Package admin can initialize MarkLogic instances
Index ¶
- type InitHandle
- func (rh *InitHandle) AcceptResponse(resp *http.Response) error
- func (rh *InitHandle) Deserialize(bytes []byte)
- func (rh *InitHandle) Deserialized() interface{}
- func (rh *InitHandle) Get() *InitializeProperties
- func (rh *InitHandle) GetFormat() int
- func (rh *InitHandle) Serialize(response interface{})
- func (rh *InitHandle) Serialized() string
- func (rh *InitHandle) SetTimestamp(timestamp string)
- func (rh *InitHandle) Timestamp() string
- type InitializeProperties
- type InstanceAdminHandle
- func (rh *InstanceAdminHandle) AcceptResponse(resp *http.Response) error
- func (rh *InstanceAdminHandle) Deserialize(bytes []byte)
- func (rh *InstanceAdminHandle) Deserialized() interface{}
- func (rh *InstanceAdminHandle) Get() *InstanceAdminRequest
- func (rh *InstanceAdminHandle) GetFormat() int
- func (rh *InstanceAdminHandle) Serialize(request interface{})
- func (rh *InstanceAdminHandle) Serialized() string
- func (rh *InstanceAdminHandle) SetTimestamp(timestamp string)
- func (rh *InstanceAdminHandle) Timestamp() string
- type InstanceAdminRequest
- type LastStartupElement
- type LinkElement
- type RestartResponse
- type RestartResponseHandle
- func (rh *RestartResponseHandle) AcceptResponse(resp *http.Response) error
- func (rh *RestartResponseHandle) Deserialize(bytes []byte)
- func (rh *RestartResponseHandle) Deserialized() interface{}
- func (rh *RestartResponseHandle) Get() *RestartResponse
- func (rh *RestartResponseHandle) GetFormat() int
- func (rh *RestartResponseHandle) Serialize(response interface{})
- func (rh *RestartResponseHandle) Serialized() string
- func (rh *RestartResponseHandle) SetTimestamp(timestamp string)
- func (rh *RestartResponseHandle) Timestamp() string
- type Service
- type TimestampResponseHandle
- func (rh *TimestampResponseHandle) AcceptResponse(resp *http.Response) error
- func (rh *TimestampResponseHandle) Deserialize(bytes []byte)
- func (rh *TimestampResponseHandle) Deserialized() interface{}
- func (rh *TimestampResponseHandle) Get() *string
- func (rh *TimestampResponseHandle) GetFormat() int
- func (rh *TimestampResponseHandle) Serialize(response interface{})
- func (rh *TimestampResponseHandle) Serialized() string
- func (rh *TimestampResponseHandle) SetTimestamp(timestamp string)
- func (rh *TimestampResponseHandle) Timestamp() string
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type InitHandle ¶
InitHandle returns the raw string results of JSON or XML
func (*InitHandle) AcceptResponse ¶
func (rh *InitHandle) AcceptResponse(resp *http.Response) error
AcceptResponse handles an *http.Response
func (*InitHandle) Deserialize ¶
func (rh *InitHandle) Deserialize(bytes []byte)
Deserialize returns Response struct that represents XML or JSON
func (*InitHandle) Deserialized ¶
func (rh *InitHandle) Deserialized() interface{}
Deserialized returns deserialized InitializeProperties
func (*InitHandle) Get ¶
func (rh *InitHandle) Get() *InitializeProperties
Get returns deserialized InitializeProperties
func (*InitHandle) GetFormat ¶
func (rh *InitHandle) GetFormat() int
GetFormat returns int that represents XML or JSON
func (*InitHandle) Serialize ¶
func (rh *InitHandle) Serialize(response interface{})
Serialize returns []byte of XML or JSON that represents the Response struct
func (*InitHandle) Serialized ¶
func (rh *InitHandle) Serialized() string
Serialized returns string of XML or JSON
func (*InitHandle) SetTimestamp ¶
func (rh *InitHandle) SetTimestamp(timestamp string)
SetTimestamp sets the timestamp
func (*InitHandle) Timestamp ¶
func (rh *InitHandle) Timestamp() string
Timestamp retieves a timestamp
type InitializeProperties ¶
type InitializeProperties struct { XMLName xml.Name `xml:"http://marklogic.com/manage init" json:"-"` LicenseKey string `xml:"license-key" json:"license-key"` Licensee string `xml:"licensee" json:"licensee"` }
InitializeProperties represents a request for /admin/v1/init API
type InstanceAdminHandle ¶
type InstanceAdminHandle struct { *bytes.Buffer Format int // contains filtered or unexported fields }
InstanceAdminHandle returns the raw string results of JSON or XML
func (*InstanceAdminHandle) AcceptResponse ¶
func (rh *InstanceAdminHandle) AcceptResponse(resp *http.Response) error
AcceptResponse handles an *http.Response
func (*InstanceAdminHandle) Deserialize ¶
func (rh *InstanceAdminHandle) Deserialize(bytes []byte)
Deserialize returns Response struct that represents XML or JSON
func (*InstanceAdminHandle) Deserialized ¶
func (rh *InstanceAdminHandle) Deserialized() interface{}
Deserialized returns deserialized InstanceAdminRequest as interface{}
func (*InstanceAdminHandle) Get ¶
func (rh *InstanceAdminHandle) Get() *InstanceAdminRequest
Get returns returns deserialized InstanceAdminRequest
func (*InstanceAdminHandle) GetFormat ¶
func (rh *InstanceAdminHandle) GetFormat() int
GetFormat returns int that represents XML or JSON
func (*InstanceAdminHandle) Serialize ¶
func (rh *InstanceAdminHandle) Serialize(request interface{})
Serialize returns []byte of XML or JSON that represents the Response struct
func (*InstanceAdminHandle) Serialized ¶
func (rh *InstanceAdminHandle) Serialized() string
Serialized returns string of XML or JSON
func (*InstanceAdminHandle) SetTimestamp ¶
func (rh *InstanceAdminHandle) SetTimestamp(timestamp string)
SetTimestamp sets the timestamp
func (*InstanceAdminHandle) Timestamp ¶
func (rh *InstanceAdminHandle) Timestamp() string
Timestamp retieves a timestamp
type InstanceAdminRequest ¶
type InstanceAdminRequest struct { XMLName xml.Name `xml:"http://marklogic.com/manage instance-admin" json:"-"` Username string `xml:"admin-username" json:"admin-username"` Password string `xml:"admin-password" json:"admin-password"` Realm string `xml:"realm" json:"realm"` }
InstanceAdminRequest represents the properties of a MarkLogic Database
type LastStartupElement ¶
type LastStartupElement struct { XMLName xml.Name `xml:"last-startup" json:"-"` Value string `xml:",chardata"` HostID string `xml:"host-id,attr"` }
LastStartupElement represents MarkLogic last startup information
type LinkElement ¶
type LinkElement struct { XMLName xml.Name `xml:"link" json:"-"` KindRef string `xml:"kindref"` URIRef string `xml:"uriref"` }
LinkElement represents link information
type RestartResponse ¶
type RestartResponse struct { XMLName xml.Name `xml:"http://marklogic.com/manage restart" json:"-"` LastStartup LastStartupElement `xml:"last-startup" json:"last-startup,omitempty"` Link LinkElement `xml:"link" json:"link,omitempty"` Message string `xml:"message" json:"message,omitempty"` // contains filtered or unexported fields }
RestartResponse represents a response from /admin/v1/init API
type RestartResponseHandle ¶
type RestartResponseHandle struct { *bytes.Buffer Format int // contains filtered or unexported fields }
RestartResponseHandle is a handle that places the results into a Response struct
func (*RestartResponseHandle) AcceptResponse ¶
func (rh *RestartResponseHandle) AcceptResponse(resp *http.Response) error
AcceptResponse handles an *http.Response
func (*RestartResponseHandle) Deserialize ¶
func (rh *RestartResponseHandle) Deserialize(bytes []byte)
Deserialize returns Response struct that represents XML or JSON
func (*RestartResponseHandle) Deserialized ¶
func (rh *RestartResponseHandle) Deserialized() interface{}
Deserialized returns deserialised RestartResponse as interface{}
func (*RestartResponseHandle) Get ¶
func (rh *RestartResponseHandle) Get() *RestartResponse
Get returns deserialised RestartResponse
func (*RestartResponseHandle) GetFormat ¶
func (rh *RestartResponseHandle) GetFormat() int
GetFormat returns int that represents XML or JSON
func (*RestartResponseHandle) Serialize ¶
func (rh *RestartResponseHandle) Serialize(response interface{})
Serialize returns []byte of XML or JSON that represents the Response struct
func (*RestartResponseHandle) Serialized ¶
func (rh *RestartResponseHandle) Serialized() string
Serialized returns string of XML or JSON
func (*RestartResponseHandle) SetTimestamp ¶
func (rh *RestartResponseHandle) SetTimestamp(timestamp string)
SetTimestamp sets the timestamp
func (*RestartResponseHandle) Timestamp ¶
func (rh *RestartResponseHandle) Timestamp() string
Timestamp retieves a timestamp
type Service ¶
type Service struct {
// contains filtered or unexported fields
}
Service is used for the admin service
func NewService ¶
func NewService(client *clients.AdminClient) *Service
NewService returns a new admin.Service
func (*Service) InstanceAdmin ¶
func (s *Service) InstanceAdmin(username string, password string, realm string, response handle.ResponseHandle) error
InstanceAdmin install the admin username and password, and initialize the security database and objects.
type TimestampResponseHandle ¶
type TimestampResponseHandle struct { *bytes.Buffer Format int // contains filtered or unexported fields }
TimestampResponseHandle is a handle that places the results into a Response struct
func (*TimestampResponseHandle) AcceptResponse ¶
func (rh *TimestampResponseHandle) AcceptResponse(resp *http.Response) error
AcceptResponse handles an *http.Response
func (*TimestampResponseHandle) Deserialize ¶
func (rh *TimestampResponseHandle) Deserialize(bytes []byte)
Deserialize returns Response struct that represents XML or JSON
func (*TimestampResponseHandle) Deserialized ¶
func (rh *TimestampResponseHandle) Deserialized() interface{}
Deserialized returns deserialized timestamp string as interface{}
func (*TimestampResponseHandle) Get ¶
func (rh *TimestampResponseHandle) Get() *string
Get returns string of timestamp
func (*TimestampResponseHandle) GetFormat ¶
func (rh *TimestampResponseHandle) GetFormat() int
GetFormat returns int that represents XML or JSON
func (*TimestampResponseHandle) Serialize ¶
func (rh *TimestampResponseHandle) Serialize(response interface{})
Serialize returns []byte of XML or JSON that represents the Response struct
func (*TimestampResponseHandle) Serialized ¶
func (rh *TimestampResponseHandle) Serialized() string
Serialized returns string of XML or JSON
func (*TimestampResponseHandle) SetTimestamp ¶
func (rh *TimestampResponseHandle) SetTimestamp(timestamp string)
SetTimestamp sets the timestamp
func (*TimestampResponseHandle) Timestamp ¶
func (rh *TimestampResponseHandle) Timestamp() string
Timestamp retieves a timestamp