You can omit the namespace when creating an instance of a schema class or when calling a schema method. For example, because the DescribeSObjectResult and FieldSet classes are in the Schema namespace, these code segments are equivalent.
Schema.DescribeSObjectResult d = Account.sObjectType.getDescribe();
Map<String, Schema.FieldSet> FSMap = d.fieldSets.getMap();
And:
DescribeSObjectResult d = Account.sObjectType.getDescribe();
Map<String, FieldSet> FSMap = d.fieldSets.getMap();
Use Schema.object_name to refer to an sObject that has the same name as a custom class. This disambiguation instructs the Apex runtime to use the sObject.
public class Account { public Integer myInteger; } // ... Schema.Account myAccountSObject = new Schema.Account(); Account accountClassInstance = new Account(); myAccountSObject.Name = 'Snazzy Account'; accountClassInstance.myInteger = 1;