DescribeSObjectResult sobject = pc.describeSObject(s.getName());
Field[] fields = sobject.getFields();
List<CustomField> customFields = new ArrayList<CustomField>();
for (Field f : fields) {
if (f.isCustom()) {
CustomField cf = new CustomField();
cf.setFullName(f.getName());
if (!s.isCustom()) {
if (!customFieldsToKeep.contains((s.getName() + "." + f.getName()).toLowerCase())) {
writer.addCustomField(co, cf);
}
} else {