def get_fields(schema):
    """Return a dictionary containing all the Fields in a schema.
    """
    from guillotina.schema.interfaces import IField
    fields = {}
    for name in schema:
        attr = schema[name]
        if IField.providedBy(attr):
            fields[name] = attr
    return fields
