class documentation

class Role(Resource): (source)

View In Hierarchy

A role inside a project.

Method __init__ Initializes a generic resource.
Method add_user Add the specified users or groups to this project role. One of ``users`` or ``groups`` must be specified.
Method update Add the specified users or groups to this project role. One of ``users`` or ``groups`` must be specified.
Instance Variable raw Undocumented

Inherited from Resource:

Method __eq__ Default equality test.
Method __getattr__ Allow access of attributes via names.
Method __getstate__ Pickling the resource.
Method __hash__ Hash calculation.
Method __repr__ Identify the class and include any and all relevant values.
Method __setstate__ Unpickling of the resource.
Method __str__ Return the first value we find that is likely to be human-readable.
Method delete Delete this resource from the server, passing the specified query parameters.
Method find Finds a resource based on the input parameters.
Constant JIRA_BASE_URL Undocumented
Method _default_headers Undocumented
Method _find_by_url Finds a resource on the specified url.
Method _get_url Gets the url for the specified path.
Method _load Load a resource.
Method _parse_raw Parse a raw dictionary to create a resource.
Constant _HASH_IDS Undocumented
Constant _READABLE_IDS Undocumented
Instance Variable _base_url Undocumented
Instance Variable _options Undocumented
Instance Variable _resource Undocumented
Instance Variable _session Undocumented
def __init__(self, options: Dict[str, str], session: ResilientSession, raw: Dict[str, Any] = None): (source)

Initializes a generic resource. Args: resource (str): The name of the resource. options (Dict[str,str]): Options for the new resource session (ResilientSession): Session used for the resource. base_url (Optional[str]): The Base Jira url.

def add_user(self, users: Union[str, List, Tuple] = None, groups: Union[str, List, Tuple] = None): (source)

Add the specified users or groups to this project role. One of ``users`` or ``groups`` must be specified. Args: users (Optional[Union[str,List,Tuple]]): a user or users to add to the role groups (Optional[Union[str,List,Tuple]]): a group or groups to add to the role

def update(self, users: Union[str, List, Tuple] = None, groups: Union[str, List, Tuple] = None): (source)

Add the specified users or groups to this project role. One of ``users`` or ``groups`` must be specified. Args: users (Optional[Union[str,List,Tuple]]): a user or users to add to the role groups (Optional[Union[str,List,Tuple]]): a group or groups to add to the role

raw: Dict[str, Any] = (source)

Undocumented