get all fields of object in apex code example Example: apex get object fields Map fieldMap = Schema.SObjectType..fields.getMap();