Documentation ¶
Overview ¶
Package roles provides information and interaction with the roles API resource for the OpenStack Identity service.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ListAssignments ¶
func ListAssignments(client *gophercloud.ServiceClient, opts ListAssignmentsOptsBuilder) pagination.Pager
ListAssignments enumerates the roles assigned to a specified resource.
Types ¶
type ListAssignmentsOpts ¶
type ListAssignmentsOpts struct { GroupId string `q:"group.id"` RoleId string `q:"role.id"` ScopeDomainId string `q:"scope.domain.id"` ScopeProjectId string `q:"scope.project.id"` UserId string `q:"user.id"` Effective bool `q:"effective"` }
ListAssignmentsOpts allows you to query the ListAssignments method. Specify one of or a combination of GroupId, RoleId, ScopeDomainId, ScopeProjectId, and/or UserId to search for roles assigned to corresponding entities. Effective lists effective assignments at the user, project, and domain level, allowing for the effects of group membership.
func (ListAssignmentsOpts) ToRolesListAssignmentsQuery ¶
func (opts ListAssignmentsOpts) ToRolesListAssignmentsQuery() (string, error)
ToRolesListAssignmentsQuery formats a ListAssignmentsOpts into a query string.
type ListAssignmentsOptsBuilder ¶
ListAssignmentsOptsBuilder allows extensions to add additional parameters to the ListAssignments request.
type RoleAssignment ¶
type RoleAssignment struct { Role Role `json:"role,omitempty"` Scope Scope `json:"scope,omitempty"` User User `json:"user,omitempty"` Group Group `json:"group,omitempty"` }
RoleAssignment is the result of a role assignments query.
func ExtractRoleAssignments ¶
func ExtractRoleAssignments(page pagination.Page) ([]RoleAssignment, error)
ExtractRoleAssignments extracts a slice of RoleAssignments from a Collection acquired from List.
type RoleAssignmentsPage ¶
type RoleAssignmentsPage struct {
pagination.LinkedPageBase
}
RoleAssignmentsPage is a single page of RoleAssignments results.
func (RoleAssignmentsPage) IsEmpty ¶
func (p RoleAssignmentsPage) IsEmpty() (bool, error)
IsEmpty returns true if the page contains no results.
func (RoleAssignmentsPage) NextPageURL ¶
func (page RoleAssignmentsPage) NextPageURL() (string, error)
NextPageURL uses the response's embedded link reference to navigate to the next page of results.