def list(cls, spec=None):
        """ List prefixes.

            Maps to the function :py:func:`nipap.backend.Nipap.list_prefix` in
            the backend. Please see the documentation for the backend function
            for information regarding input arguments and return values.
        """

        if spec is None:
            spec = {}

        xmlrpc = XMLRPCConnection()
        try:
            pref_list = xmlrpc.connection.list_prefix(
                {
                    'prefix': spec,
                    'auth': AuthOptions().options
                })
        except xmlrpclib.Fault as xml_fault:
            raise _fault_to_exception(xml_fault)
        res = list()
        for pref in pref_list:
            p = Prefix.from_dict(pref)
            res.append(p)

        return res