Salesforce Apex Code Send mail

public void sender(String debugMessage){ Messaging.SingleEmailMessage message = new Messaging.SingleEmailMessage(); message.toAddresses = new String[] { ‘alessandro@xxx.it’ }; message.subject = ‘Debug’; message.plainTextBody = debugMessage; Messaging.SingleEmailMessage[] messages = new List {message}; Messaging.SendEmailResult[] results = Messaging.sendEmail(messages); }