Ejemplo n.º 1
0
    def get_character(self):
        """ Return a single character

        :param id: the id of the character
        :return: Character object
        """
        return bind_api(api=self,
                        path='/characters/{id}',
                        model_type='character',
                        allowed_parameters=['id'],
                        iteration_mode='id')
Ejemplo n.º 2
0
    def get_character(self):
        """ Return a single character

        :param id: the id of the character
        :return: Character object
        """
        return bind_api(api=self,
                        path='/characters/{id}',
                        model_type='character',
                        allowed_parameters=['id'],
                        iteration_mode='id')
Ejemplo n.º 3
0
    def get_book(self):
        """ Return a single book

        :param id: the id of the book
        :return: Book object
        """
        return bind_api(api=self,
                        path='/books/{id}',
                        model_type='book',
                        allowed_parameters=['id'],
                        iteration_mode='id')
Ejemplo n.º 4
0
    def get_house(self):
        """ Return a single house

        :param id: the id of the house
        :return: House object
        """
        return bind_api(api=self,
                        path='/houses/{id}',
                        model_type='house',
                        allowed_parameters=['id'],
                        iteration_mode='id')
Ejemplo n.º 5
0
    def get_book(self):
        """ Return a single book

        :param id: the id of the book
        :return: Book object
        """
        return bind_api(api=self,
                        path='/books/{id}',
                        model_type='book',
                        allowed_parameters=['id'],
                        iteration_mode='id')
Ejemplo n.º 6
0
    def get_house(self):
        """ Return a single house

        :param id: the id of the house
        :return: House object
        """
        return bind_api(api=self,
                        path='/houses/{id}',
                        model_type='house',
                        allowed_parameters=['id'],
                        iteration_mode='id')
Ejemplo n.º 7
0
    def get_characters(self):
        """ Return pages with characters that matches the given parameters

        :return:
        """
        return bind_api(api=self,
                        path='/characters',
                        model_type='character',
                        allowed_parameters=['page', 'name', 'culture', 'born', 'died', 'is_alive'],
                        is_data_list=True,
                        iteration_mode='page')
Ejemplo n.º 8
0
    def get_books(self):
        """ Return pages with books that matches the given parameters

        :return:
        """
        return bind_api(api=self,
                        path='/books',
                        model_type='book',
                        allowed_parameters=['page', 'name', 'from_release_date', 'to_release_date'],
                        is_data_list=True,
                        iteration_mode='page')
Ejemplo n.º 9
0
    def get_houses(self):
        """ Return pages with houses that matches the given parameters

        :return:
        """
        return bind_api(api=self,
                        path='/houses',
                        model_type='house',
                        allowed_parameters=['page', 'name', 'region', 'words', 'has_words', 'has_titles', 'has_seats',
                                            'has_died_out', 'has_ancestral_weapons'],
                        is_data_list=True,
                        iteration_mode='page')
Ejemplo n.º 10
0
    def get_characters(self):
        """ Return pages with characters that matches the given parameters

        :return:
        """
        return bind_api(api=self,
                        path='/characters',
                        model_type='character',
                        allowed_parameters=[
                            'page', 'name', 'culture', 'born', 'died',
                            'is_alive'
                        ],
                        is_data_list=True,
                        iteration_mode='page')
Ejemplo n.º 11
0
    def get_books(self):
        """ Return pages with books that matches the given parameters

        :return:
        """
        return bind_api(api=self,
                        path='/books',
                        model_type='book',
                        allowed_parameters=[
                            'page', 'name', 'from_release_date',
                            'to_release_date'
                        ],
                        is_data_list=True,
                        iteration_mode='page')
Ejemplo n.º 12
0
    def get_houses(self):
        """ Return pages with houses that matches the given parameters

        :return:
        """
        return bind_api(api=self,
                        path='/houses',
                        model_type='house',
                        allowed_parameters=[
                            'page', 'name', 'region', 'words', 'has_words',
                            'has_titles', 'has_seats', 'has_died_out',
                            'has_ancestral_weapons'
                        ],
                        is_data_list=True,
                        iteration_mode='page')