Skip to content

Commit

Permalink
Merge pull request #7 from viniciussanchez/master
Browse files Browse the repository at this point in the history
Added ClearBody function
  • Loading branch information
juliosenha authored Nov 5, 2020
2 parents 38e79ef + 797a78c commit 3df7ec9
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 0 deletions.
1 change: 1 addition & 0 deletions src/Mail4Delphi.Intf.pas
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ interface
function AddCC(const AMail: string; const AName: string = ''): IMail;
function AddBCC(const AMail: string; const AName: string = ''): IMail;
function AddBody(const ABody: string): IMail;
function ClearBody: IMail;
function Host(const AHost: string): IMail;
function UserName(const AUserName: string): IMail;
function Password(const APassword: string): IMail;
Expand Down
7 changes: 7 additions & 0 deletions src/Mail4Delphi.pas
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@ TMail = class(TInterfacedObject, IMail)
function AddCC(const AMail: string; const AName: string = ''): IMail;
function AddBCC(const AMail: string; const AName: string = ''): IMail;
function AddBody(const ABody: string): IMail;
function ClearBody: IMail;
function Host(const AHost: string): IMail;
function UserName(const AUserName: string): IMail;
function Password(const APassword: string): IMail;
Expand Down Expand Up @@ -172,6 +173,12 @@ function TMail.Clear: IMail;
Result := Self;
end;

function TMail.ClearBody: IMail;
begin
FIdText.Body.Clear;
Result := Self;
end;

function TMail.ContentType(const AValue: string): IMail;
begin
FIdText.ContentType := AValue;
Expand Down

0 comments on commit 3df7ec9

Please sign in to comment.