Documentation
¶
Index ¶
- func NewClient(opts *ClientOpts) *plugin.Client
- func Serve(opts *ServeOpts)
- type Client
- type ClientOpts
- type RuleSetPlugin
- type ServeOpts
- type Server
- func (s *Server) ApplyConfig(config *tflint.Config, resp *interface{}) error
- func (s *Server) Check(brokerID uint32, resp *interface{}) error
- func (s *Server) RuleNames(args interface{}, resp *[]string) error
- func (s *Server) RuleSetName(args interface{}, resp *string) error
- func (s *Server) RuleSetVersion(args interface{}, resp *string) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewClient ¶
func NewClient(opts *ClientOpts) *plugin.Client
NewClient is a wrapper of plugin.NewClient
Types ¶
type Client ¶
type Client struct {
// contains filtered or unexported fields
}
Client is an RPC client for use by the host
func (*Client) ApplyConfig ¶
ApplyConfig queries the RPC server for ApplyConfig
func (*Client) Check ¶
Check queries the RPC server for Check For bi-directional communication, you can pass a server that accepts Runner's queries
func (*Client) RuleSetName ¶
RuleSetName queries the RPC server for RuleSetName
func (*Client) RuleSetVersion ¶
RuleSetVersion queries the RPC server for RuleSetVersion
type ClientOpts ¶
ClientOpts is an option for initializing the RPC client
type RuleSetPlugin ¶
type RuleSetPlugin struct {
// contains filtered or unexported fields
}
RuleSetPlugin is a wrapper to satisfy the interface of go-plugin
type ServeOpts ¶
ServeOpts is an option for serving a plugin Each plugin can pass a RuleSet that represents its own functionality
type Server ¶
type Server struct {
// contains filtered or unexported fields
}
Server is an RPC server acting as a plugin
func (*Server) ApplyConfig ¶
ApplyConfig applies the passed config to its own plugin implementation
func (*Server) Check ¶
Check initializes an RPC client that can query to the host process and pass it to the Check method
func (*Server) RuleSetName ¶
RuleSetName replies its own the result of RuleSetName
func (*Server) RuleSetVersion ¶
RuleSetVersion replies its own the result of RuleSetVersion