Mark van Renswoude
f3d8ef6968
Changed: moved to Delphi XE2, changed StreamHelper to StreamWriter descendant Added: 64-bits build, for fun
37 lines
729 B
ObjectPascal
37 lines
729 B
ObjectPascal
unit XMLDataBindingHelpers;
|
|
|
|
interface
|
|
uses
|
|
System.Classes;
|
|
|
|
|
|
type
|
|
TNamedFormatWriter = class(TStreamWriter)
|
|
public
|
|
procedure WriteNamedFmt(const ASource: String; const AParams: array of const);
|
|
procedure WriteLineNamedFmt(const ASource: String; const AParams: array of const);
|
|
end;
|
|
|
|
|
|
implementation
|
|
uses
|
|
SysUtils,
|
|
|
|
X2UtNamedFormat;
|
|
|
|
|
|
{ TNamedFormatWriter }
|
|
procedure TNamedFormatWriter.WriteNamedFmt(const ASource: String; const AParams: array of const);
|
|
begin
|
|
Write(NamedFormat(ASource, AParams));
|
|
end;
|
|
|
|
|
|
procedure TNamedFormatWriter.WriteLineNamedFmt(const ASource: String; const AParams: array of const);
|
|
begin
|
|
WriteLine(NamedFormat(ASource, AParams));
|
|
end;
|
|
|
|
end.
|
|
|