// TODO: Get appropriate copyright header package awx // WorkflowJobResource defines the resource of the workflow job type WorkflowJobResource struct { Resource } // NewWorkflowJobResource creates a new workflow job resource func NewWorkflowJobResource(connection Connecter, path string) Getter { resource := new(WorkflowJobResource) resource.connection = connection resource.path = path return resource } // Get returns a get request for the workflow job resource func (r *WorkflowJobResource) Get() Sender { request := new(WorkflowJobGetRequest) request.resource = &r.Resource return request } // WorkflowJobGetRequest defines the get request for the workflow job type WorkflowJobGetRequest struct { Request } // Send sends the workflow job get request and returns the response func (r *WorkflowJobGetRequest) Send() (response interface{}, err error) { response = new(WorkflowJobGetResponse) err = r.get(response) if err != nil { return nil, err } return } // Filter adds the given filter to the workflow job get request and returns it func (r *WorkflowJobGetRequest) Filter(name string, value interface{}) Sender { r.addFilter(name, value) return r }