<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def get_name(self, obj=None, withext=True):
 """Return the filename :param obj: the fileinfo with information. If None, this will use the stored object of JB_File :type obj: :class:`FileInfo` :param withext: If True, return with the fileextension. :type withext: bool :returns: the filename, default is with fileextension :rtype: str :raises: None """

        if obj is None:
            obj = self._obj
        chunks = []
        for e in self._elements:
            c = e.get_chunk(obj)
            if c is not None:
                chunks.append(c)
        name = '_'.join(chunks)
        if withext:
            name = os.extsep.join([name, self.get_ext(obj)])
        return name