Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type APIRoot ¶
type APIRoot struct {
properties.TitleProperty
properties.DescriptionProperty
Versions []string `json:"versions"`
MaxContentLength int `json:"max_content_length"`
}
APIRoot - This type implements the TAXII 2 API Root Resource and defines all of the properties and methods needed to create and work with the TAXII API Root Resource. All of the methods not defined local to this type are inherited from the individual properties.
The following information comes directly from the TAXII 2 specification documents.
This Endpoint provides general information about an API Root, which can be used to help users and clients decide whether and how they want to interact with it. Multiple API Roots MAY be hosted on a single TAXII Server. Often, an API Root represents a single trust group.
The api-root resource contains general information about the API Root, such as a human-readable title and description, the TAXII versions it supports, and the maximum size of the content body it will accept in a PUT or POST (max_content_length).
func New ¶
func New() *APIRoot
New - This function will create a new TAXII API Root object and return it as a pointer.
func (*APIRoot) AddVersion ¶
AddVersion - This method takes in a string value that represents a version of the TAXII api that is supported and adds it to the versions property.
func (*APIRoot) GetMaxContentLength ¶
GetMaxContentLength - This method returns the max content length as an integer.
func (*APIRoot) SetMaxContentLength ¶
SetMaxContentLength - This method takes in an integer value representing the max content length that the server can support and updates the max content length property.