-1

what is interface? when using interface? In Salesforce Give Me Explination

0

Standard Salesforce Interface for Batch Apex. SFDC do have standard interfaces like Database.Batchable, Schedulable, etc.

For example, if you implement the Database.Batchable Interface, then you must implement the three methods defined in the Interface: Start, Execute and Finish

Code:-

Interface:- ==========

public interface PurchaseOrder {    
Double getDiscount();
 }

ApexClass:- ===========

public class Sample implements PurchaseOrder {        
Double discount;  
public void setDiscount(Double disc) {        
discount = disc;      
 }  

public Double getDiscount() {                
return 1.22;        
}
}
| improve this answer | |
  • Now I understood About Interface In Batch Apex interface – Farook Sep 9 '16 at 12:11

Not the answer you're looking for? Browse other questions tagged or ask your own question.