def get_by_id(self, id):
        """
        Return object based on ``child_id_attribute``.

        Parameters
        ----------
        val : str

        Returns
        -------
        object

        Notes
        -----
        Based on `.get()`_ from `backbone.js`_.

        .. _backbone.js: http://backbonejs.org/
        .. _.get(): http://backbonejs.org/#Collection-get
        """
        for child in self.children:
            if child[self.child_id_attribute] == id:
                return child
            else:
                continue

        return None
def get_by_id ( self , id ) : for child in self . children : if child [ self . child_id_attribute ] == id : return child else : continue return None
Return object based on ``child_id_attribute``.

        Parameters
        ----------
        val : str

        Returns
        -------
        object

        Notes
        -----
        Based on `.get()`_ from `backbone.js`_.

        .. _backbone.js: http://backbonejs.org/
        .. _.get(): http://backbonejs.org/#Collection-get