gorealis v2 refactor (#5)
* Changing default timeout for start maintenance. * Upgrading dependencies to gorealis v2 and thrift 0.12.0 * Refactored to update to gorealis v2.
This commit is contained in:
parent
ad4dd9606e
commit
6ab5c9334d
1335 changed files with 137431 additions and 61530 deletions
vendor/git.apache.org/thrift.git/lib/delphi/src
45
vendor/git.apache.org/thrift.git/lib/delphi/src/Thrift.pas
generated
vendored
45
vendor/git.apache.org/thrift.git/lib/delphi/src/Thrift.pas
generated
vendored
|
@ -22,15 +22,19 @@ unit Thrift;
|
|||
interface
|
||||
|
||||
uses
|
||||
SysUtils, Thrift.Protocol;
|
||||
SysUtils,
|
||||
Thrift.Exception,
|
||||
Thrift.Protocol;
|
||||
|
||||
const
|
||||
Version = '0.10.0';
|
||||
Version = '0.12.0';
|
||||
|
||||
type
|
||||
TException = Thrift.Exception.TException; // compatibility alias
|
||||
|
||||
TApplicationExceptionSpecializedClass = class of TApplicationExceptionSpecialized;
|
||||
|
||||
TApplicationException = class( SysUtils.Exception )
|
||||
TApplicationException = class( TException)
|
||||
public
|
||||
type
|
||||
{$SCOPEDENUMS ON}
|
||||
|
@ -83,31 +87,9 @@ type
|
|||
TApplicationExceptionInvalidProtocol = class (TApplicationExceptionSpecialized);
|
||||
TApplicationExceptionUnsupportedClientType = class (TApplicationExceptionSpecialized);
|
||||
|
||||
// base class for IDL-generated exceptions
|
||||
TException = class( SysUtils.Exception)
|
||||
public
|
||||
function Message : string; // hide inherited property: allow read, but prevent accidental writes
|
||||
procedure UpdateMessageProperty; // update inherited message property with toString()
|
||||
end;
|
||||
|
||||
implementation
|
||||
|
||||
{ TException }
|
||||
|
||||
function TException.Message;
|
||||
// allow read (exception summary), but prevent accidental writes
|
||||
// read will return the exception summary
|
||||
begin
|
||||
result := Self.ToString;
|
||||
end;
|
||||
|
||||
procedure TException.UpdateMessageProperty;
|
||||
// Update the inherited Message property to better conform to standard behaviour.
|
||||
// Nice benefit: The IDE is now able to show the exception message again.
|
||||
begin
|
||||
inherited Message := Self.ToString; // produces a summary text
|
||||
end;
|
||||
|
||||
{ TApplicationException }
|
||||
|
||||
function TApplicationException.GetType: TExceptionType;
|
||||
|
@ -172,10 +154,10 @@ end;
|
|||
|
||||
class function TApplicationException.Read( const iprot: IProtocol): TApplicationException;
|
||||
var
|
||||
field : IField;
|
||||
field : TThriftField;
|
||||
msg : string;
|
||||
typ : TExceptionType;
|
||||
struc : IStruct;
|
||||
struc : TThriftStruct;
|
||||
begin
|
||||
msg := '';
|
||||
typ := TExceptionType.Unknown;
|
||||
|
@ -220,12 +202,11 @@ end;
|
|||
|
||||
procedure TApplicationException.Write( const oprot: IProtocol);
|
||||
var
|
||||
struc : IStruct;
|
||||
field : IField;
|
||||
|
||||
struc : TThriftStruct;
|
||||
field : TThriftField;
|
||||
begin
|
||||
struc := TStructImpl.Create( 'TApplicationException' );
|
||||
field := TFieldImpl.Create;
|
||||
Init(struc, 'TApplicationException');
|
||||
Init(field);
|
||||
|
||||
oprot.WriteStructBegin( struc );
|
||||
if Message <> '' then
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue