123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731173217331734173517361737173817391740174117421743174417451746174717481749175017511752175317541755175617571758175917601761176217631764176517661767176817691770177117721773177417751776177717781779178017811782178317841785178617871788178917901791179217931794179517961797179817991800180118021803180418051806180718081809181018111812181318141815181618171818181918201821182218231824182518261827182818291830183118321833183418351836183718381839184018411842184318441845184618471848184918501851185218531854185518561857185818591860186118621863186418651866186718681869187018711872187318741875187618771878187918801881188218831884188518861887188818891890189118921893189418951896189718981899190019011902190319041905190619071908190919101911191219131914191519161917191819191920192119221923192419251926192719281929193019311932193319341935193619371938193919401941194219431944194519461947194819491950195119521953195419551956195719581959196019611962196319641965196619671968196919701971197219731974197519761977197819791980198119821983198419851986198719881989199019911992199319941995199619971998199920002001200220032004200520062007200820092010201120122013201420152016201720182019202020212022202320242025202620272028202920302031203220332034203520362037203820392040204120422043204420452046204720482049205020512052205320542055205620572058205920602061206220632064206520662067206820692070207120722073207420752076207720782079208020812082208320842085208620872088208920902091209220932094209520962097209820992100210121022103210421052106210721082109211021112112211321142115211621172118211921202121212221232124212521262127212821292130213121322133213421352136213721382139214021412142214321442145214621472148214921502151215221532154215521562157215821592160216121622163216421652166216721682169217021712172217321742175217621772178217921802181218221832184218521862187218821892190219121922193219421952196219721982199220022012202220322042205220622072208220922102211221222132214221522162217221822192220222122222223222422252226222722282229223022312232223322342235223622372238223922402241224222432244224522462247224822492250225122522253225422552256225722582259226022612262226322642265226622672268226922702271227222732274227522762277227822792280228122822283228422852286228722882289229022912292229322942295229622972298229923002301230223032304230523062307230823092310231123122313231423152316231723182319232023212322232323242325232623272328232923302331233223332334233523362337233823392340234123422343234423452346234723482349235023512352235323542355235623572358235923602361236223632364236523662367236823692370237123722373237423752376237723782379238023812382238323842385238623872388238923902391239223932394239523962397239823992400240124022403240424052406240724082409241024112412241324142415241624172418241924202421242224232424242524262427242824292430243124322433243424352436243724382439244024412442244324442445244624472448244924502451245224532454245524562457245824592460246124622463246424652466246724682469247024712472247324742475247624772478247924802481248224832484248524862487248824892490249124922493249424952496249724982499250025012502250325042505250625072508250925102511251225132514251525162517251825192520252125222523252425252526252725282529253025312532253325342535253625372538253925402541254225432544254525462547254825492550255125522553255425552556255725582559256025612562256325642565256625672568 |
- unit googledatastore;
- {$MODE objfpc}
- {$H+}
- interface
- uses sysutils, classes, googleservice, restbase, googlebase;
- type
-
- //Top-level schema types
- TValue = Class;
- TReadOptions = Class;
- TPropertyOrder = Class;
- TCommitRequest = Class;
- TRollbackRequest = Class;
- TQuery = Class;
- TEntityResult = Class;
- TGqlQueryParameter = Class;
- TBeginTransactionResponse = Class;
- TFilter = Class;
- TArrayValue = Class;
- TPartitionId = Class;
- TQueryResultBatch = Class;
- TAllocateIdsRequest = Class;
- TPropertyFilter = Class;
- TKindExpression = Class;
- TPathElement = Class;
- TRollbackResponse = Class;
- TPropertyReference = Class;
- TProjection = Class;
- TAllocateIdsResponse = Class;
- TMutationResult = Class;
- TLookupResponse = Class;
- TBeginTransactionRequest = Class;
- TKey = Class;
- TRunQueryResponse = Class;
- TEntity = Class;
- TGqlQuery = Class;
- TCommitResponse = Class;
- TMutation = Class;
- TRunQueryRequest = Class;
- TCompositeFilter = Class;
- TLatLng = Class;
- TLookupRequest = Class;
- TValueArray = Array of TValue;
- TReadOptionsArray = Array of TReadOptions;
- TPropertyOrderArray = Array of TPropertyOrder;
- TCommitRequestArray = Array of TCommitRequest;
- TRollbackRequestArray = Array of TRollbackRequest;
- TQueryArray = Array of TQuery;
- TEntityResultArray = Array of TEntityResult;
- TGqlQueryParameterArray = Array of TGqlQueryParameter;
- TBeginTransactionResponseArray = Array of TBeginTransactionResponse;
- TFilterArray = Array of TFilter;
- TArrayValueArray = Array of TArrayValue;
- TPartitionIdArray = Array of TPartitionId;
- TQueryResultBatchArray = Array of TQueryResultBatch;
- TAllocateIdsRequestArray = Array of TAllocateIdsRequest;
- TPropertyFilterArray = Array of TPropertyFilter;
- TKindExpressionArray = Array of TKindExpression;
- TPathElementArray = Array of TPathElement;
- TRollbackResponseArray = Array of TRollbackResponse;
- TPropertyReferenceArray = Array of TPropertyReference;
- TProjectionArray = Array of TProjection;
- TAllocateIdsResponseArray = Array of TAllocateIdsResponse;
- TMutationResultArray = Array of TMutationResult;
- TLookupResponseArray = Array of TLookupResponse;
- TBeginTransactionRequestArray = Array of TBeginTransactionRequest;
- TKeyArray = Array of TKey;
- TRunQueryResponseArray = Array of TRunQueryResponse;
- TEntityArray = Array of TEntity;
- TGqlQueryArray = Array of TGqlQuery;
- TCommitResponseArray = Array of TCommitResponse;
- TMutationArray = Array of TMutation;
- TRunQueryRequestArray = Array of TRunQueryRequest;
- TCompositeFilterArray = Array of TCompositeFilter;
- TLatLngArray = Array of TLatLng;
- TLookupRequestArray = Array of TLookupRequest;
- //Anonymous types, using auto-generated names
- TEntityTypeproperties = Class;
- TGqlQueryTypenamedBindings = Class;
- TCommitRequestTypemutationsArray = Array of TMutation;
- TQueryTypedistinctOnArray = Array of TPropertyReference;
- TQueryTypeprojectionArray = Array of TProjection;
- TQueryTypeorderArray = Array of TPropertyOrder;
- TQueryTypekindArray = Array of TKindExpression;
- TArrayValueTypevaluesArray = Array of TValue;
- TQueryResultBatchTypeentityResultsArray = Array of TEntityResult;
- TAllocateIdsRequestTypekeysArray = Array of TKey;
- TAllocateIdsResponseTypekeysArray = Array of TKey;
- TLookupResponseTypefoundArray = Array of TEntityResult;
- TLookupResponseTypedeferredArray = Array of TKey;
- TLookupResponseTypemissingArray = Array of TEntityResult;
- TKeyTypepathArray = Array of TPathElement;
- TGqlQueryTypepositionalBindingsArray = Array of TGqlQueryParameter;
- TCommitResponseTypemutationResultsArray = Array of TMutationResult;
- TCompositeFilterTypefiltersArray = Array of TFilter;
- TLookupRequestTypekeysArray = Array of TKey;
-
- { --------------------------------------------------------------------
- TValue
- --------------------------------------------------------------------}
-
- TValue = Class(TGoogleBaseObject)
- Private
- FstringValue : String;
- FarrayValue : TArrayValue;
- FentityValue : TEntity;
- Fmeaning : integer;
- FintegerValue : String;
- FdoubleValue : double;
- FgeoPointValue : TLatLng;
- FblobValue : String;
- FnullValue : String;
- FkeyValue : TKey;
- FbooleanValue : boolean;
- FexcludeFromIndexes : boolean;
- FtimestampValue : String;
- Protected
- //Property setters
- Procedure SetstringValue(AIndex : Integer; const AValue : String); virtual;
- Procedure SetarrayValue(AIndex : Integer; const AValue : TArrayValue); virtual;
- Procedure SetentityValue(AIndex : Integer; const AValue : TEntity); virtual;
- Procedure Setmeaning(AIndex : Integer; const AValue : integer); virtual;
- Procedure SetintegerValue(AIndex : Integer; const AValue : String); virtual;
- Procedure SetdoubleValue(AIndex : Integer; const AValue : double); virtual;
- Procedure SetgeoPointValue(AIndex : Integer; const AValue : TLatLng); virtual;
- Procedure SetblobValue(AIndex : Integer; const AValue : String); virtual;
- Procedure SetnullValue(AIndex : Integer; const AValue : String); virtual;
- Procedure SetkeyValue(AIndex : Integer; const AValue : TKey); virtual;
- Procedure SetbooleanValue(AIndex : Integer; const AValue : boolean); virtual;
- Procedure SetexcludeFromIndexes(AIndex : Integer; const AValue : boolean); virtual;
- Procedure SettimestampValue(AIndex : Integer; const AValue : String); virtual;
- Public
- Published
- Property stringValue : String Index 0 Read FstringValue Write SetstringValue;
- Property arrayValue : TArrayValue Index 8 Read FarrayValue Write SetarrayValue;
- Property entityValue : TEntity Index 16 Read FentityValue Write SetentityValue;
- Property meaning : integer Index 24 Read Fmeaning Write Setmeaning;
- Property integerValue : String Index 32 Read FintegerValue Write SetintegerValue;
- Property doubleValue : double Index 40 Read FdoubleValue Write SetdoubleValue;
- Property geoPointValue : TLatLng Index 48 Read FgeoPointValue Write SetgeoPointValue;
- Property blobValue : String Index 56 Read FblobValue Write SetblobValue;
- Property nullValue : String Index 64 Read FnullValue Write SetnullValue;
- Property keyValue : TKey Index 72 Read FkeyValue Write SetkeyValue;
- Property booleanValue : boolean Index 80 Read FbooleanValue Write SetbooleanValue;
- Property excludeFromIndexes : boolean Index 88 Read FexcludeFromIndexes Write SetexcludeFromIndexes;
- Property timestampValue : String Index 96 Read FtimestampValue Write SettimestampValue;
- end;
- TValueClass = Class of TValue;
-
- { --------------------------------------------------------------------
- TReadOptions
- --------------------------------------------------------------------}
-
- TReadOptions = Class(TGoogleBaseObject)
- Private
- Ftransaction : String;
- FreadConsistency : String;
- Protected
- //Property setters
- Procedure Settransaction(AIndex : Integer; const AValue : String); virtual;
- Procedure SetreadConsistency(AIndex : Integer; const AValue : String); virtual;
- Public
- Published
- Property transaction : String Index 0 Read Ftransaction Write Settransaction;
- Property readConsistency : String Index 8 Read FreadConsistency Write SetreadConsistency;
- end;
- TReadOptionsClass = Class of TReadOptions;
-
- { --------------------------------------------------------------------
- TPropertyOrder
- --------------------------------------------------------------------}
-
- TPropertyOrder = Class(TGoogleBaseObject)
- Private
- Fdirection : String;
- F_property : TPropertyReference;
- Protected
- Class Function ExportPropertyName(Const AName : String) : string; override;
- //Property setters
- Procedure Setdirection(AIndex : Integer; const AValue : String); virtual;
- Procedure Set_property(AIndex : Integer; const AValue : TPropertyReference); virtual;
- Public
- Published
- Property direction : String Index 0 Read Fdirection Write Setdirection;
- Property _property : TPropertyReference Index 8 Read F_property Write Set_property;
- end;
- TPropertyOrderClass = Class of TPropertyOrder;
-
- { --------------------------------------------------------------------
- TCommitRequest
- --------------------------------------------------------------------}
-
- TCommitRequest = Class(TGoogleBaseObject)
- Private
- Ftransaction : String;
- Fmutations : TCommitRequestTypemutationsArray;
- Fmode : String;
- Protected
- //Property setters
- Procedure Settransaction(AIndex : Integer; const AValue : String); virtual;
- Procedure Setmutations(AIndex : Integer; const AValue : TCommitRequestTypemutationsArray); virtual;
- Procedure Setmode(AIndex : Integer; const AValue : String); virtual;
- //2.6.4. bug workaround
- {$IFDEF VER2_6}
- Procedure SetArrayLength(Const AName : String; ALength : Longint); override;
- {$ENDIF VER2_6}
- Public
- Published
- Property transaction : String Index 0 Read Ftransaction Write Settransaction;
- Property mutations : TCommitRequestTypemutationsArray Index 8 Read Fmutations Write Setmutations;
- Property mode : String Index 16 Read Fmode Write Setmode;
- end;
- TCommitRequestClass = Class of TCommitRequest;
-
- { --------------------------------------------------------------------
- TRollbackRequest
- --------------------------------------------------------------------}
-
- TRollbackRequest = Class(TGoogleBaseObject)
- Private
- Ftransaction : String;
- Protected
- //Property setters
- Procedure Settransaction(AIndex : Integer; const AValue : String); virtual;
- Public
- Published
- Property transaction : String Index 0 Read Ftransaction Write Settransaction;
- end;
- TRollbackRequestClass = Class of TRollbackRequest;
-
- { --------------------------------------------------------------------
- TQuery
- --------------------------------------------------------------------}
-
- TQuery = Class(TGoogleBaseObject)
- Private
- Flimit : integer;
- Ffilter : TFilter;
- FendCursor : String;
- FdistinctOn : TQueryTypedistinctOnArray;
- Foffset : integer;
- Fprojection : TQueryTypeprojectionArray;
- FstartCursor : String;
- Forder : TQueryTypeorderArray;
- Fkind : TQueryTypekindArray;
- Protected
- //Property setters
- Procedure Setlimit(AIndex : Integer; const AValue : integer); virtual;
- Procedure Setfilter(AIndex : Integer; const AValue : TFilter); virtual;
- Procedure SetendCursor(AIndex : Integer; const AValue : String); virtual;
- Procedure SetdistinctOn(AIndex : Integer; const AValue : TQueryTypedistinctOnArray); virtual;
- Procedure Setoffset(AIndex : Integer; const AValue : integer); virtual;
- Procedure Setprojection(AIndex : Integer; const AValue : TQueryTypeprojectionArray); virtual;
- Procedure SetstartCursor(AIndex : Integer; const AValue : String); virtual;
- Procedure Setorder(AIndex : Integer; const AValue : TQueryTypeorderArray); virtual;
- Procedure Setkind(AIndex : Integer; const AValue : TQueryTypekindArray); virtual;
- //2.6.4. bug workaround
- {$IFDEF VER2_6}
- Procedure SetArrayLength(Const AName : String; ALength : Longint); override;
- {$ENDIF VER2_6}
- Public
- Published
- Property limit : integer Index 0 Read Flimit Write Setlimit;
- Property filter : TFilter Index 8 Read Ffilter Write Setfilter;
- Property endCursor : String Index 16 Read FendCursor Write SetendCursor;
- Property distinctOn : TQueryTypedistinctOnArray Index 24 Read FdistinctOn Write SetdistinctOn;
- Property offset : integer Index 32 Read Foffset Write Setoffset;
- Property projection : TQueryTypeprojectionArray Index 40 Read Fprojection Write Setprojection;
- Property startCursor : String Index 48 Read FstartCursor Write SetstartCursor;
- Property order : TQueryTypeorderArray Index 56 Read Forder Write Setorder;
- Property kind : TQueryTypekindArray Index 64 Read Fkind Write Setkind;
- end;
- TQueryClass = Class of TQuery;
-
- { --------------------------------------------------------------------
- TEntityResult
- --------------------------------------------------------------------}
-
- TEntityResult = Class(TGoogleBaseObject)
- Private
- Fcursor : String;
- Fentity : TEntity;
- Protected
- //Property setters
- Procedure Setcursor(AIndex : Integer; const AValue : String); virtual;
- Procedure Setentity(AIndex : Integer; const AValue : TEntity); virtual;
- Public
- Published
- Property cursor : String Index 0 Read Fcursor Write Setcursor;
- Property entity : TEntity Index 8 Read Fentity Write Setentity;
- end;
- TEntityResultClass = Class of TEntityResult;
-
- { --------------------------------------------------------------------
- TGqlQueryParameter
- --------------------------------------------------------------------}
-
- TGqlQueryParameter = Class(TGoogleBaseObject)
- Private
- Fcursor : String;
- Fvalue : TValue;
- Protected
- //Property setters
- Procedure Setcursor(AIndex : Integer; const AValue : String); virtual;
- Procedure Setvalue(AIndex : Integer; const AValue : TValue); virtual;
- Public
- Published
- Property cursor : String Index 0 Read Fcursor Write Setcursor;
- Property value : TValue Index 8 Read Fvalue Write Setvalue;
- end;
- TGqlQueryParameterClass = Class of TGqlQueryParameter;
-
- { --------------------------------------------------------------------
- TBeginTransactionResponse
- --------------------------------------------------------------------}
-
- TBeginTransactionResponse = Class(TGoogleBaseObject)
- Private
- Ftransaction : String;
- Protected
- //Property setters
- Procedure Settransaction(AIndex : Integer; const AValue : String); virtual;
- Public
- Published
- Property transaction : String Index 0 Read Ftransaction Write Settransaction;
- end;
- TBeginTransactionResponseClass = Class of TBeginTransactionResponse;
-
- { --------------------------------------------------------------------
- TFilter
- --------------------------------------------------------------------}
-
- TFilter = Class(TGoogleBaseObject)
- Private
- FpropertyFilter : TPropertyFilter;
- FcompositeFilter : TCompositeFilter;
- Protected
- //Property setters
- Procedure SetpropertyFilter(AIndex : Integer; const AValue : TPropertyFilter); virtual;
- Procedure SetcompositeFilter(AIndex : Integer; const AValue : TCompositeFilter); virtual;
- Public
- Published
- Property propertyFilter : TPropertyFilter Index 0 Read FpropertyFilter Write SetpropertyFilter;
- Property compositeFilter : TCompositeFilter Index 8 Read FcompositeFilter Write SetcompositeFilter;
- end;
- TFilterClass = Class of TFilter;
-
- { --------------------------------------------------------------------
- TArrayValue
- --------------------------------------------------------------------}
-
- TArrayValue = Class(TGoogleBaseObject)
- Private
- Fvalues : TArrayValueTypevaluesArray;
- Protected
- //Property setters
- Procedure Setvalues(AIndex : Integer; const AValue : TArrayValueTypevaluesArray); virtual;
- //2.6.4. bug workaround
- {$IFDEF VER2_6}
- Procedure SetArrayLength(Const AName : String; ALength : Longint); override;
- {$ENDIF VER2_6}
- Public
- Published
- Property values : TArrayValueTypevaluesArray Index 0 Read Fvalues Write Setvalues;
- end;
- TArrayValueClass = Class of TArrayValue;
-
- { --------------------------------------------------------------------
- TPartitionId
- --------------------------------------------------------------------}
-
- TPartitionId = Class(TGoogleBaseObject)
- Private
- FnamespaceId : String;
- FprojectId : String;
- Protected
- //Property setters
- Procedure SetnamespaceId(AIndex : Integer; const AValue : String); virtual;
- Procedure SetprojectId(AIndex : Integer; const AValue : String); virtual;
- Public
- Published
- Property namespaceId : String Index 0 Read FnamespaceId Write SetnamespaceId;
- Property projectId : String Index 8 Read FprojectId Write SetprojectId;
- end;
- TPartitionIdClass = Class of TPartitionId;
-
- { --------------------------------------------------------------------
- TQueryResultBatch
- --------------------------------------------------------------------}
-
- TQueryResultBatch = Class(TGoogleBaseObject)
- Private
- FendCursor : String;
- FskippedCursor : String;
- FentityResultType : String;
- FmoreResults : String;
- FentityResults : TQueryResultBatchTypeentityResultsArray;
- FskippedResults : integer;
- Protected
- //Property setters
- Procedure SetendCursor(AIndex : Integer; const AValue : String); virtual;
- Procedure SetskippedCursor(AIndex : Integer; const AValue : String); virtual;
- Procedure SetentityResultType(AIndex : Integer; const AValue : String); virtual;
- Procedure SetmoreResults(AIndex : Integer; const AValue : String); virtual;
- Procedure SetentityResults(AIndex : Integer; const AValue : TQueryResultBatchTypeentityResultsArray); virtual;
- Procedure SetskippedResults(AIndex : Integer; const AValue : integer); virtual;
- //2.6.4. bug workaround
- {$IFDEF VER2_6}
- Procedure SetArrayLength(Const AName : String; ALength : Longint); override;
- {$ENDIF VER2_6}
- Public
- Published
- Property endCursor : String Index 0 Read FendCursor Write SetendCursor;
- Property skippedCursor : String Index 8 Read FskippedCursor Write SetskippedCursor;
- Property entityResultType : String Index 16 Read FentityResultType Write SetentityResultType;
- Property moreResults : String Index 24 Read FmoreResults Write SetmoreResults;
- Property entityResults : TQueryResultBatchTypeentityResultsArray Index 32 Read FentityResults Write SetentityResults;
- Property skippedResults : integer Index 40 Read FskippedResults Write SetskippedResults;
- end;
- TQueryResultBatchClass = Class of TQueryResultBatch;
-
- { --------------------------------------------------------------------
- TAllocateIdsRequest
- --------------------------------------------------------------------}
-
- TAllocateIdsRequest = Class(TGoogleBaseObject)
- Private
- Fkeys : TAllocateIdsRequestTypekeysArray;
- Protected
- //Property setters
- Procedure Setkeys(AIndex : Integer; const AValue : TAllocateIdsRequestTypekeysArray); virtual;
- //2.6.4. bug workaround
- {$IFDEF VER2_6}
- Procedure SetArrayLength(Const AName : String; ALength : Longint); override;
- {$ENDIF VER2_6}
- Public
- Published
- Property keys : TAllocateIdsRequestTypekeysArray Index 0 Read Fkeys Write Setkeys;
- end;
- TAllocateIdsRequestClass = Class of TAllocateIdsRequest;
-
- { --------------------------------------------------------------------
- TPropertyFilter
- --------------------------------------------------------------------}
-
- TPropertyFilter = Class(TGoogleBaseObject)
- Private
- Fvalue : TValue;
- Fop : String;
- F_property : TPropertyReference;
- Protected
- Class Function ExportPropertyName(Const AName : String) : string; override;
- //Property setters
- Procedure Setvalue(AIndex : Integer; const AValue : TValue); virtual;
- Procedure Setop(AIndex : Integer; const AValue : String); virtual;
- Procedure Set_property(AIndex : Integer; const AValue : TPropertyReference); virtual;
- Public
- Published
- Property value : TValue Index 0 Read Fvalue Write Setvalue;
- Property op : String Index 8 Read Fop Write Setop;
- Property _property : TPropertyReference Index 16 Read F_property Write Set_property;
- end;
- TPropertyFilterClass = Class of TPropertyFilter;
-
- { --------------------------------------------------------------------
- TKindExpression
- --------------------------------------------------------------------}
-
- TKindExpression = Class(TGoogleBaseObject)
- Private
- Fname : String;
- Protected
- //Property setters
- Procedure Setname(AIndex : Integer; const AValue : String); virtual;
- Public
- Published
- Property name : String Index 0 Read Fname Write Setname;
- end;
- TKindExpressionClass = Class of TKindExpression;
-
- { --------------------------------------------------------------------
- TPathElement
- --------------------------------------------------------------------}
-
- TPathElement = Class(TGoogleBaseObject)
- Private
- Fkind : String;
- Fname : String;
- Fid : String;
- Protected
- //Property setters
- Procedure Setkind(AIndex : Integer; const AValue : String); virtual;
- Procedure Setname(AIndex : Integer; const AValue : String); virtual;
- Procedure Setid(AIndex : Integer; const AValue : String); virtual;
- Public
- Published
- Property kind : String Index 0 Read Fkind Write Setkind;
- Property name : String Index 8 Read Fname Write Setname;
- Property id : String Index 16 Read Fid Write Setid;
- end;
- TPathElementClass = Class of TPathElement;
-
- { --------------------------------------------------------------------
- TRollbackResponse
- --------------------------------------------------------------------}
-
- TRollbackResponse = Class(TGoogleBaseObject)
- Private
- Protected
- //Property setters
- Public
- Published
- end;
- TRollbackResponseClass = Class of TRollbackResponse;
-
- { --------------------------------------------------------------------
- TPropertyReference
- --------------------------------------------------------------------}
-
- TPropertyReference = Class(TGoogleBaseObject)
- Private
- Fname : String;
- Protected
- //Property setters
- Procedure Setname(AIndex : Integer; const AValue : String); virtual;
- Public
- Published
- Property name : String Index 0 Read Fname Write Setname;
- end;
- TPropertyReferenceClass = Class of TPropertyReference;
-
- { --------------------------------------------------------------------
- TProjection
- --------------------------------------------------------------------}
-
- TProjection = Class(TGoogleBaseObject)
- Private
- F_property : TPropertyReference;
- Protected
- Class Function ExportPropertyName(Const AName : String) : string; override;
- //Property setters
- Procedure Set_property(AIndex : Integer; const AValue : TPropertyReference); virtual;
- Public
- Published
- Property _property : TPropertyReference Index 0 Read F_property Write Set_property;
- end;
- TProjectionClass = Class of TProjection;
-
- { --------------------------------------------------------------------
- TAllocateIdsResponse
- --------------------------------------------------------------------}
-
- TAllocateIdsResponse = Class(TGoogleBaseObject)
- Private
- Fkeys : TAllocateIdsResponseTypekeysArray;
- Protected
- //Property setters
- Procedure Setkeys(AIndex : Integer; const AValue : TAllocateIdsResponseTypekeysArray); virtual;
- //2.6.4. bug workaround
- {$IFDEF VER2_6}
- Procedure SetArrayLength(Const AName : String; ALength : Longint); override;
- {$ENDIF VER2_6}
- Public
- Published
- Property keys : TAllocateIdsResponseTypekeysArray Index 0 Read Fkeys Write Setkeys;
- end;
- TAllocateIdsResponseClass = Class of TAllocateIdsResponse;
-
- { --------------------------------------------------------------------
- TMutationResult
- --------------------------------------------------------------------}
-
- TMutationResult = Class(TGoogleBaseObject)
- Private
- Fkey : TKey;
- Protected
- //Property setters
- Procedure Setkey(AIndex : Integer; const AValue : TKey); virtual;
- Public
- Published
- Property key : TKey Index 0 Read Fkey Write Setkey;
- end;
- TMutationResultClass = Class of TMutationResult;
-
- { --------------------------------------------------------------------
- TLookupResponse
- --------------------------------------------------------------------}
-
- TLookupResponse = Class(TGoogleBaseObject)
- Private
- Ffound : TLookupResponseTypefoundArray;
- Fdeferred : TLookupResponseTypedeferredArray;
- Fmissing : TLookupResponseTypemissingArray;
- Protected
- //Property setters
- Procedure Setfound(AIndex : Integer; const AValue : TLookupResponseTypefoundArray); virtual;
- Procedure Setdeferred(AIndex : Integer; const AValue : TLookupResponseTypedeferredArray); virtual;
- Procedure Setmissing(AIndex : Integer; const AValue : TLookupResponseTypemissingArray); virtual;
- //2.6.4. bug workaround
- {$IFDEF VER2_6}
- Procedure SetArrayLength(Const AName : String; ALength : Longint); override;
- {$ENDIF VER2_6}
- Public
- Published
- Property found : TLookupResponseTypefoundArray Index 0 Read Ffound Write Setfound;
- Property deferred : TLookupResponseTypedeferredArray Index 8 Read Fdeferred Write Setdeferred;
- Property missing : TLookupResponseTypemissingArray Index 16 Read Fmissing Write Setmissing;
- end;
- TLookupResponseClass = Class of TLookupResponse;
-
- { --------------------------------------------------------------------
- TBeginTransactionRequest
- --------------------------------------------------------------------}
-
- TBeginTransactionRequest = Class(TGoogleBaseObject)
- Private
- Protected
- //Property setters
- Public
- Published
- end;
- TBeginTransactionRequestClass = Class of TBeginTransactionRequest;
-
- { --------------------------------------------------------------------
- TKey
- --------------------------------------------------------------------}
-
- TKey = Class(TGoogleBaseObject)
- Private
- FpartitionId : TPartitionId;
- Fpath : TKeyTypepathArray;
- Protected
- //Property setters
- Procedure SetpartitionId(AIndex : Integer; const AValue : TPartitionId); virtual;
- Procedure Setpath(AIndex : Integer; const AValue : TKeyTypepathArray); virtual;
- //2.6.4. bug workaround
- {$IFDEF VER2_6}
- Procedure SetArrayLength(Const AName : String; ALength : Longint); override;
- {$ENDIF VER2_6}
- Public
- Published
- Property partitionId : TPartitionId Index 0 Read FpartitionId Write SetpartitionId;
- Property path : TKeyTypepathArray Index 8 Read Fpath Write Setpath;
- end;
- TKeyClass = Class of TKey;
-
- { --------------------------------------------------------------------
- TRunQueryResponse
- --------------------------------------------------------------------}
-
- TRunQueryResponse = Class(TGoogleBaseObject)
- Private
- Fbatch : TQueryResultBatch;
- Fquery : TQuery;
- Protected
- //Property setters
- Procedure Setbatch(AIndex : Integer; const AValue : TQueryResultBatch); virtual;
- Procedure Setquery(AIndex : Integer; const AValue : TQuery); virtual;
- Public
- Published
- Property batch : TQueryResultBatch Index 0 Read Fbatch Write Setbatch;
- Property query : TQuery Index 8 Read Fquery Write Setquery;
- end;
- TRunQueryResponseClass = Class of TRunQueryResponse;
-
- { --------------------------------------------------------------------
- TEntityTypeproperties
- --------------------------------------------------------------------}
-
- TEntityTypeproperties = Class(TGoogleBaseObject)
- Private
- Protected
- //Property setters
- Public
- Class Function AllowAdditionalProperties : Boolean; override;
- Published
- end;
- TEntityTypepropertiesClass = Class of TEntityTypeproperties;
-
- { --------------------------------------------------------------------
- TEntity
- --------------------------------------------------------------------}
-
- TEntity = Class(TGoogleBaseObject)
- Private
- Fproperties : TEntityTypeproperties;
- Fkey : TKey;
- Protected
- //Property setters
- Procedure Setproperties(AIndex : Integer; const AValue : TEntityTypeproperties); virtual;
- Procedure Setkey(AIndex : Integer; const AValue : TKey); virtual;
- Public
- Published
- Property properties : TEntityTypeproperties Index 0 Read Fproperties Write Setproperties;
- Property key : TKey Index 8 Read Fkey Write Setkey;
- end;
- TEntityClass = Class of TEntity;
-
- { --------------------------------------------------------------------
- TGqlQueryTypenamedBindings
- --------------------------------------------------------------------}
-
- TGqlQueryTypenamedBindings = Class(TGoogleBaseObject)
- Private
- Protected
- //Property setters
- Public
- Class Function AllowAdditionalProperties : Boolean; override;
- Published
- end;
- TGqlQueryTypenamedBindingsClass = Class of TGqlQueryTypenamedBindings;
-
- { --------------------------------------------------------------------
- TGqlQuery
- --------------------------------------------------------------------}
-
- TGqlQuery = Class(TGoogleBaseObject)
- Private
- FnamedBindings : TGqlQueryTypenamedBindings;
- FqueryString : String;
- FallowLiterals : boolean;
- FpositionalBindings : TGqlQueryTypepositionalBindingsArray;
- Protected
- //Property setters
- Procedure SetnamedBindings(AIndex : Integer; const AValue : TGqlQueryTypenamedBindings); virtual;
- Procedure SetqueryString(AIndex : Integer; const AValue : String); virtual;
- Procedure SetallowLiterals(AIndex : Integer; const AValue : boolean); virtual;
- Procedure SetpositionalBindings(AIndex : Integer; const AValue : TGqlQueryTypepositionalBindingsArray); virtual;
- //2.6.4. bug workaround
- {$IFDEF VER2_6}
- Procedure SetArrayLength(Const AName : String; ALength : Longint); override;
- {$ENDIF VER2_6}
- Public
- Published
- Property namedBindings : TGqlQueryTypenamedBindings Index 0 Read FnamedBindings Write SetnamedBindings;
- Property queryString : String Index 8 Read FqueryString Write SetqueryString;
- Property allowLiterals : boolean Index 16 Read FallowLiterals Write SetallowLiterals;
- Property positionalBindings : TGqlQueryTypepositionalBindingsArray Index 24 Read FpositionalBindings Write SetpositionalBindings;
- end;
- TGqlQueryClass = Class of TGqlQuery;
-
- { --------------------------------------------------------------------
- TCommitResponse
- --------------------------------------------------------------------}
-
- TCommitResponse = Class(TGoogleBaseObject)
- Private
- FmutationResults : TCommitResponseTypemutationResultsArray;
- FindexUpdates : integer;
- Protected
- //Property setters
- Procedure SetmutationResults(AIndex : Integer; const AValue : TCommitResponseTypemutationResultsArray); virtual;
- Procedure SetindexUpdates(AIndex : Integer; const AValue : integer); virtual;
- //2.6.4. bug workaround
- {$IFDEF VER2_6}
- Procedure SetArrayLength(Const AName : String; ALength : Longint); override;
- {$ENDIF VER2_6}
- Public
- Published
- Property mutationResults : TCommitResponseTypemutationResultsArray Index 0 Read FmutationResults Write SetmutationResults;
- Property indexUpdates : integer Index 8 Read FindexUpdates Write SetindexUpdates;
- end;
- TCommitResponseClass = Class of TCommitResponse;
-
- { --------------------------------------------------------------------
- TMutation
- --------------------------------------------------------------------}
-
- TMutation = Class(TGoogleBaseObject)
- Private
- Fupdate : TEntity;
- Finsert : TEntity;
- Fdelete : TKey;
- Fupsert : TEntity;
- Protected
- //Property setters
- Procedure Setupdate(AIndex : Integer; const AValue : TEntity); virtual;
- Procedure Setinsert(AIndex : Integer; const AValue : TEntity); virtual;
- Procedure Setdelete(AIndex : Integer; const AValue : TKey); virtual;
- Procedure Setupsert(AIndex : Integer; const AValue : TEntity); virtual;
- Public
- Published
- Property update : TEntity Index 0 Read Fupdate Write Setupdate;
- Property insert : TEntity Index 8 Read Finsert Write Setinsert;
- Property delete : TKey Index 16 Read Fdelete Write Setdelete;
- Property upsert : TEntity Index 24 Read Fupsert Write Setupsert;
- end;
- TMutationClass = Class of TMutation;
-
- { --------------------------------------------------------------------
- TRunQueryRequest
- --------------------------------------------------------------------}
-
- TRunQueryRequest = Class(TGoogleBaseObject)
- Private
- FpartitionId : TPartitionId;
- FgqlQuery : TGqlQuery;
- Fquery : TQuery;
- FreadOptions : TReadOptions;
- Protected
- //Property setters
- Procedure SetpartitionId(AIndex : Integer; const AValue : TPartitionId); virtual;
- Procedure SetgqlQuery(AIndex : Integer; const AValue : TGqlQuery); virtual;
- Procedure Setquery(AIndex : Integer; const AValue : TQuery); virtual;
- Procedure SetreadOptions(AIndex : Integer; const AValue : TReadOptions); virtual;
- Public
- Published
- Property partitionId : TPartitionId Index 0 Read FpartitionId Write SetpartitionId;
- Property gqlQuery : TGqlQuery Index 8 Read FgqlQuery Write SetgqlQuery;
- Property query : TQuery Index 16 Read Fquery Write Setquery;
- Property readOptions : TReadOptions Index 24 Read FreadOptions Write SetreadOptions;
- end;
- TRunQueryRequestClass = Class of TRunQueryRequest;
-
- { --------------------------------------------------------------------
- TCompositeFilter
- --------------------------------------------------------------------}
-
- TCompositeFilter = Class(TGoogleBaseObject)
- Private
- Fop : String;
- Ffilters : TCompositeFilterTypefiltersArray;
- Protected
- //Property setters
- Procedure Setop(AIndex : Integer; const AValue : String); virtual;
- Procedure Setfilters(AIndex : Integer; const AValue : TCompositeFilterTypefiltersArray); virtual;
- //2.6.4. bug workaround
- {$IFDEF VER2_6}
- Procedure SetArrayLength(Const AName : String; ALength : Longint); override;
- {$ENDIF VER2_6}
- Public
- Published
- Property op : String Index 0 Read Fop Write Setop;
- Property filters : TCompositeFilterTypefiltersArray Index 8 Read Ffilters Write Setfilters;
- end;
- TCompositeFilterClass = Class of TCompositeFilter;
-
- { --------------------------------------------------------------------
- TLatLng
- --------------------------------------------------------------------}
-
- TLatLng = Class(TGoogleBaseObject)
- Private
- Flongitude : double;
- Flatitude : double;
- Protected
- //Property setters
- Procedure Setlongitude(AIndex : Integer; const AValue : double); virtual;
- Procedure Setlatitude(AIndex : Integer; const AValue : double); virtual;
- Public
- Published
- Property longitude : double Index 0 Read Flongitude Write Setlongitude;
- Property latitude : double Index 8 Read Flatitude Write Setlatitude;
- end;
- TLatLngClass = Class of TLatLng;
-
- { --------------------------------------------------------------------
- TLookupRequest
- --------------------------------------------------------------------}
-
- TLookupRequest = Class(TGoogleBaseObject)
- Private
- Fkeys : TLookupRequestTypekeysArray;
- FreadOptions : TReadOptions;
- Protected
- //Property setters
- Procedure Setkeys(AIndex : Integer; const AValue : TLookupRequestTypekeysArray); virtual;
- Procedure SetreadOptions(AIndex : Integer; const AValue : TReadOptions); virtual;
- //2.6.4. bug workaround
- {$IFDEF VER2_6}
- Procedure SetArrayLength(Const AName : String; ALength : Longint); override;
- {$ENDIF VER2_6}
- Public
- Published
- Property keys : TLookupRequestTypekeysArray Index 0 Read Fkeys Write Setkeys;
- Property readOptions : TReadOptions Index 8 Read FreadOptions Write SetreadOptions;
- end;
- TLookupRequestClass = Class of TLookupRequest;
-
- { --------------------------------------------------------------------
- TProjectsResource
- --------------------------------------------------------------------}
-
- TProjectsResource = Class(TGoogleResource)
- Public
- Class Function ResourceName : String; override;
- Class Function DefaultAPI : TGoogleAPIClass; override;
- Function RunQuery(projectId: string; aRunQueryRequest : TRunQueryRequest) : TRunQueryResponse;
- Function BeginTransaction(projectId: string; aBeginTransactionRequest : TBeginTransactionRequest) : TBeginTransactionResponse;
- Function AllocateIds(projectId: string; aAllocateIdsRequest : TAllocateIdsRequest) : TAllocateIdsResponse;
- Function Lookup(projectId: string; aLookupRequest : TLookupRequest) : TLookupResponse;
- Function Commit(projectId: string; aCommitRequest : TCommitRequest) : TCommitResponse;
- Function Rollback(projectId: string; aRollbackRequest : TRollbackRequest) : TRollbackResponse;
- end;
-
-
- { --------------------------------------------------------------------
- TDatastoreAPI
- --------------------------------------------------------------------}
-
- TDatastoreAPI = Class(TGoogleAPI)
- Private
- FProjectsInstance : TProjectsResource;
- Function GetProjectsInstance : TProjectsResource;virtual;
- Public
- //Override class functions with API info
- Class Function APIName : String; override;
- Class Function APIVersion : String; override;
- Class Function APIRevision : String; override;
- Class Function APIID : String; override;
- Class Function APITitle : String; override;
- Class Function APIDescription : String; override;
- Class Function APIOwnerDomain : String; override;
- Class Function APIOwnerName : String; override;
- Class Function APIIcon16 : String; override;
- Class Function APIIcon32 : String; override;
- Class Function APIdocumentationLink : String; override;
- Class Function APIrootUrl : string; override;
- Class Function APIbasePath : string;override;
- Class Function APIbaseURL : String;override;
- Class Function APIProtocol : string;override;
- Class Function APIservicePath : string;override;
- Class Function APIbatchPath : String;override;
- Class Function APIAuthScopes : TScopeInfoArray;override;
- Class Function APINeedsAuth : Boolean;override;
- Class Procedure RegisterAPIResources; override;
- //Add create function for resources
- Function CreateProjectsResource(AOwner : TComponent) : TProjectsResource;virtual;overload;
- Function CreateProjectsResource : TProjectsResource;virtual;overload;
- //Add default on-demand instances for resources
- Property ProjectsResource : TProjectsResource Read GetProjectsInstance;
- end;
- implementation
- { --------------------------------------------------------------------
- TValue
- --------------------------------------------------------------------}
- Procedure TValue.SetstringValue(AIndex : Integer; const AValue : String);
- begin
- If (FstringValue=AValue) then exit;
- FstringValue:=AValue;
- MarkPropertyChanged(AIndex);
- end;
- Procedure TValue.SetarrayValue(AIndex : Integer; const AValue : TArrayValue);
- begin
- If (FarrayValue=AValue) then exit;
- FarrayValue:=AValue;
- MarkPropertyChanged(AIndex);
- end;
- Procedure TValue.SetentityValue(AIndex : Integer; const AValue : TEntity);
- begin
- If (FentityValue=AValue) then exit;
- FentityValue:=AValue;
- MarkPropertyChanged(AIndex);
- end;
- Procedure TValue.Setmeaning(AIndex : Integer; const AValue : integer);
- begin
- If (Fmeaning=AValue) then exit;
- Fmeaning:=AValue;
- MarkPropertyChanged(AIndex);
- end;
- Procedure TValue.SetintegerValue(AIndex : Integer; const AValue : String);
- begin
- If (FintegerValue=AValue) then exit;
- FintegerValue:=AValue;
- MarkPropertyChanged(AIndex);
- end;
- Procedure TValue.SetdoubleValue(AIndex : Integer; const AValue : double);
- begin
- If (FdoubleValue=AValue) then exit;
- FdoubleValue:=AValue;
- MarkPropertyChanged(AIndex);
- end;
- Procedure TValue.SetgeoPointValue(AIndex : Integer; const AValue : TLatLng);
- begin
- If (FgeoPointValue=AValue) then exit;
- FgeoPointValue:=AValue;
- MarkPropertyChanged(AIndex);
- end;
- Procedure TValue.SetblobValue(AIndex : Integer; const AValue : String);
- begin
- If (FblobValue=AValue) then exit;
- FblobValue:=AValue;
- MarkPropertyChanged(AIndex);
- end;
- Procedure TValue.SetnullValue(AIndex : Integer; const AValue : String);
- begin
- If (FnullValue=AValue) then exit;
- FnullValue:=AValue;
- MarkPropertyChanged(AIndex);
- end;
- Procedure TValue.SetkeyValue(AIndex : Integer; const AValue : TKey);
- begin
- If (FkeyValue=AValue) then exit;
- FkeyValue:=AValue;
- MarkPropertyChanged(AIndex);
- end;
- Procedure TValue.SetbooleanValue(AIndex : Integer; const AValue : boolean);
- begin
- If (FbooleanValue=AValue) then exit;
- FbooleanValue:=AValue;
- MarkPropertyChanged(AIndex);
- end;
- Procedure TValue.SetexcludeFromIndexes(AIndex : Integer; const AValue : boolean);
- begin
- If (FexcludeFromIndexes=AValue) then exit;
- FexcludeFromIndexes:=AValue;
- MarkPropertyChanged(AIndex);
- end;
- Procedure TValue.SettimestampValue(AIndex : Integer; const AValue : String);
- begin
- If (FtimestampValue=AValue) then exit;
- FtimestampValue:=AValue;
- MarkPropertyChanged(AIndex);
- end;
- { --------------------------------------------------------------------
- TReadOptions
- --------------------------------------------------------------------}
- Procedure TReadOptions.Settransaction(AIndex : Integer; const AValue : String);
- begin
- If (Ftransaction=AValue) then exit;
- Ftransaction:=AValue;
- MarkPropertyChanged(AIndex);
- end;
- Procedure TReadOptions.SetreadConsistency(AIndex : Integer; const AValue : String);
- begin
- If (FreadConsistency=AValue) then exit;
- FreadConsistency:=AValue;
- MarkPropertyChanged(AIndex);
- end;
- { --------------------------------------------------------------------
- TPropertyOrder
- --------------------------------------------------------------------}
- Procedure TPropertyOrder.Setdirection(AIndex : Integer; const AValue : String);
- begin
- If (Fdirection=AValue) then exit;
- Fdirection:=AValue;
- MarkPropertyChanged(AIndex);
- end;
- Procedure TPropertyOrder.Set_property(AIndex : Integer; const AValue : TPropertyReference);
- begin
- If (F_property=AValue) then exit;
- F_property:=AValue;
- MarkPropertyChanged(AIndex);
- end;
- Class Function TPropertyOrder.ExportPropertyName(Const AName : String) :String;
- begin
- Case AName of
- '_property' : Result:='property';
- else
- Result:=Inherited ExportPropertyName(AName);
- end;
- end;
- { --------------------------------------------------------------------
- TCommitRequest
- --------------------------------------------------------------------}
- Procedure TCommitRequest.Settransaction(AIndex : Integer; const AValue : String);
- begin
- If (Ftransaction=AValue) then exit;
- Ftransaction:=AValue;
- MarkPropertyChanged(AIndex);
- end;
- Procedure TCommitRequest.Setmutations(AIndex : Integer; const AValue : TCommitRequestTypemutationsArray);
- begin
- If (Fmutations=AValue) then exit;
- Fmutations:=AValue;
- MarkPropertyChanged(AIndex);
- end;
- Procedure TCommitRequest.Setmode(AIndex : Integer; const AValue : String);
- begin
- If (Fmode=AValue) then exit;
- Fmode:=AValue;
- MarkPropertyChanged(AIndex);
- end;
- //2.6.4. bug workaround
- {$IFDEF VER2_6}
- Procedure TCommitRequest.SetArrayLength(Const AName : String; ALength : Longint);
- begin
- Case AName of
- 'mutations' : SetLength(Fmutations,ALength);
- else
- Inherited SetArrayLength(AName,ALength);
- end;
- end;
- {$ENDIF VER2_6}
- { --------------------------------------------------------------------
- TRollbackRequest
- --------------------------------------------------------------------}
- Procedure TRollbackRequest.Settransaction(AIndex : Integer; const AValue : String);
- begin
- If (Ftransaction=AValue) then exit;
- Ftransaction:=AValue;
- MarkPropertyChanged(AIndex);
- end;
- { --------------------------------------------------------------------
- TQuery
- --------------------------------------------------------------------}
- Procedure TQuery.Setlimit(AIndex : Integer; const AValue : integer);
- begin
- If (Flimit=AValue) then exit;
- Flimit:=AValue;
- MarkPropertyChanged(AIndex);
- end;
- Procedure TQuery.Setfilter(AIndex : Integer; const AValue : TFilter);
- begin
- If (Ffilter=AValue) then exit;
- Ffilter:=AValue;
- MarkPropertyChanged(AIndex);
- end;
- Procedure TQuery.SetendCursor(AIndex : Integer; const AValue : String);
- begin
- If (FendCursor=AValue) then exit;
- FendCursor:=AValue;
- MarkPropertyChanged(AIndex);
- end;
- Procedure TQuery.SetdistinctOn(AIndex : Integer; const AValue : TQueryTypedistinctOnArray);
- begin
- If (FdistinctOn=AValue) then exit;
- FdistinctOn:=AValue;
- MarkPropertyChanged(AIndex);
- end;
- Procedure TQuery.Setoffset(AIndex : Integer; const AValue : integer);
- begin
- If (Foffset=AValue) then exit;
- Foffset:=AValue;
- MarkPropertyChanged(AIndex);
- end;
- Procedure TQuery.Setprojection(AIndex : Integer; const AValue : TQueryTypeprojectionArray);
- begin
- If (Fprojection=AValue) then exit;
- Fprojection:=AValue;
- MarkPropertyChanged(AIndex);
- end;
- Procedure TQuery.SetstartCursor(AIndex : Integer; const AValue : String);
- begin
- If (FstartCursor=AValue) then exit;
- FstartCursor:=AValue;
- MarkPropertyChanged(AIndex);
- end;
- Procedure TQuery.Setorder(AIndex : Integer; const AValue : TQueryTypeorderArray);
- begin
- If (Forder=AValue) then exit;
- Forder:=AValue;
- MarkPropertyChanged(AIndex);
- end;
- Procedure TQuery.Setkind(AIndex : Integer; const AValue : TQueryTypekindArray);
- begin
- If (Fkind=AValue) then exit;
- Fkind:=AValue;
- MarkPropertyChanged(AIndex);
- end;
- //2.6.4. bug workaround
- {$IFDEF VER2_6}
- Procedure TQuery.SetArrayLength(Const AName : String; ALength : Longint);
- begin
- Case AName of
- 'distincton' : SetLength(FdistinctOn,ALength);
- 'projection' : SetLength(Fprojection,ALength);
- 'order' : SetLength(Forder,ALength);
- 'kind' : SetLength(Fkind,ALength);
- else
- Inherited SetArrayLength(AName,ALength);
- end;
- end;
- {$ENDIF VER2_6}
- { --------------------------------------------------------------------
- TEntityResult
- --------------------------------------------------------------------}
- Procedure TEntityResult.Setcursor(AIndex : Integer; const AValue : String);
- begin
- If (Fcursor=AValue) then exit;
- Fcursor:=AValue;
- MarkPropertyChanged(AIndex);
- end;
- Procedure TEntityResult.Setentity(AIndex : Integer; const AValue : TEntity);
- begin
- If (Fentity=AValue) then exit;
- Fentity:=AValue;
- MarkPropertyChanged(AIndex);
- end;
- { --------------------------------------------------------------------
- TGqlQueryParameter
- --------------------------------------------------------------------}
- Procedure TGqlQueryParameter.Setcursor(AIndex : Integer; const AValue : String);
- begin
- If (Fcursor=AValue) then exit;
- Fcursor:=AValue;
- MarkPropertyChanged(AIndex);
- end;
- Procedure TGqlQueryParameter.Setvalue(AIndex : Integer; const AValue : TValue);
- begin
- If (Fvalue=AValue) then exit;
- Fvalue:=AValue;
- MarkPropertyChanged(AIndex);
- end;
- { --------------------------------------------------------------------
- TBeginTransactionResponse
- --------------------------------------------------------------------}
- Procedure TBeginTransactionResponse.Settransaction(AIndex : Integer; const AValue : String);
- begin
- If (Ftransaction=AValue) then exit;
- Ftransaction:=AValue;
- MarkPropertyChanged(AIndex);
- end;
- { --------------------------------------------------------------------
- TFilter
- --------------------------------------------------------------------}
- Procedure TFilter.SetpropertyFilter(AIndex : Integer; const AValue : TPropertyFilter);
- begin
- If (FpropertyFilter=AValue) then exit;
- FpropertyFilter:=AValue;
- MarkPropertyChanged(AIndex);
- end;
- Procedure TFilter.SetcompositeFilter(AIndex : Integer; const AValue : TCompositeFilter);
- begin
- If (FcompositeFilter=AValue) then exit;
- FcompositeFilter:=AValue;
- MarkPropertyChanged(AIndex);
- end;
- { --------------------------------------------------------------------
- TArrayValue
- --------------------------------------------------------------------}
- Procedure TArrayValue.Setvalues(AIndex : Integer; const AValue : TArrayValueTypevaluesArray);
- begin
- If (Fvalues=AValue) then exit;
- Fvalues:=AValue;
- MarkPropertyChanged(AIndex);
- end;
- //2.6.4. bug workaround
- {$IFDEF VER2_6}
- Procedure TArrayValue.SetArrayLength(Const AName : String; ALength : Longint);
- begin
- Case AName of
- 'values' : SetLength(Fvalues,ALength);
- else
- Inherited SetArrayLength(AName,ALength);
- end;
- end;
- {$ENDIF VER2_6}
- { --------------------------------------------------------------------
- TPartitionId
- --------------------------------------------------------------------}
- Procedure TPartitionId.SetnamespaceId(AIndex : Integer; const AValue : String);
- begin
- If (FnamespaceId=AValue) then exit;
- FnamespaceId:=AValue;
- MarkPropertyChanged(AIndex);
- end;
- Procedure TPartitionId.SetprojectId(AIndex : Integer; const AValue : String);
- begin
- If (FprojectId=AValue) then exit;
- FprojectId:=AValue;
- MarkPropertyChanged(AIndex);
- end;
- { --------------------------------------------------------------------
- TQueryResultBatch
- --------------------------------------------------------------------}
- Procedure TQueryResultBatch.SetendCursor(AIndex : Integer; const AValue : String);
- begin
- If (FendCursor=AValue) then exit;
- FendCursor:=AValue;
- MarkPropertyChanged(AIndex);
- end;
- Procedure TQueryResultBatch.SetskippedCursor(AIndex : Integer; const AValue : String);
- begin
- If (FskippedCursor=AValue) then exit;
- FskippedCursor:=AValue;
- MarkPropertyChanged(AIndex);
- end;
- Procedure TQueryResultBatch.SetentityResultType(AIndex : Integer; const AValue : String);
- begin
- If (FentityResultType=AValue) then exit;
- FentityResultType:=AValue;
- MarkPropertyChanged(AIndex);
- end;
- Procedure TQueryResultBatch.SetmoreResults(AIndex : Integer; const AValue : String);
- begin
- If (FmoreResults=AValue) then exit;
- FmoreResults:=AValue;
- MarkPropertyChanged(AIndex);
- end;
- Procedure TQueryResultBatch.SetentityResults(AIndex : Integer; const AValue : TQueryResultBatchTypeentityResultsArray);
- begin
- If (FentityResults=AValue) then exit;
- FentityResults:=AValue;
- MarkPropertyChanged(AIndex);
- end;
- Procedure TQueryResultBatch.SetskippedResults(AIndex : Integer; const AValue : integer);
- begin
- If (FskippedResults=AValue) then exit;
- FskippedResults:=AValue;
- MarkPropertyChanged(AIndex);
- end;
- //2.6.4. bug workaround
- {$IFDEF VER2_6}
- Procedure TQueryResultBatch.SetArrayLength(Const AName : String; ALength : Longint);
- begin
- Case AName of
- 'entityresults' : SetLength(FentityResults,ALength);
- else
- Inherited SetArrayLength(AName,ALength);
- end;
- end;
- {$ENDIF VER2_6}
- { --------------------------------------------------------------------
- TAllocateIdsRequest
- --------------------------------------------------------------------}
- Procedure TAllocateIdsRequest.Setkeys(AIndex : Integer; const AValue : TAllocateIdsRequestTypekeysArray);
- begin
- If (Fkeys=AValue) then exit;
- Fkeys:=AValue;
- MarkPropertyChanged(AIndex);
- end;
- //2.6.4. bug workaround
- {$IFDEF VER2_6}
- Procedure TAllocateIdsRequest.SetArrayLength(Const AName : String; ALength : Longint);
- begin
- Case AName of
- 'keys' : SetLength(Fkeys,ALength);
- else
- Inherited SetArrayLength(AName,ALength);
- end;
- end;
- {$ENDIF VER2_6}
- { --------------------------------------------------------------------
- TPropertyFilter
- --------------------------------------------------------------------}
- Procedure TPropertyFilter.Setvalue(AIndex : Integer; const AValue : TValue);
- begin
- If (Fvalue=AValue) then exit;
- Fvalue:=AValue;
- MarkPropertyChanged(AIndex);
- end;
- Procedure TPropertyFilter.Setop(AIndex : Integer; const AValue : String);
- begin
- If (Fop=AValue) then exit;
- Fop:=AValue;
- MarkPropertyChanged(AIndex);
- end;
- Procedure TPropertyFilter.Set_property(AIndex : Integer; const AValue : TPropertyReference);
- begin
- If (F_property=AValue) then exit;
- F_property:=AValue;
- MarkPropertyChanged(AIndex);
- end;
- Class Function TPropertyFilter.ExportPropertyName(Const AName : String) :String;
- begin
- Case AName of
- '_property' : Result:='property';
- else
- Result:=Inherited ExportPropertyName(AName);
- end;
- end;
- { --------------------------------------------------------------------
- TKindExpression
- --------------------------------------------------------------------}
- Procedure TKindExpression.Setname(AIndex : Integer; const AValue : String);
- begin
- If (Fname=AValue) then exit;
- Fname:=AValue;
- MarkPropertyChanged(AIndex);
- end;
- { --------------------------------------------------------------------
- TPathElement
- --------------------------------------------------------------------}
- Procedure TPathElement.Setkind(AIndex : Integer; const AValue : String);
- begin
- If (Fkind=AValue) then exit;
- Fkind:=AValue;
- MarkPropertyChanged(AIndex);
- end;
- Procedure TPathElement.Setname(AIndex : Integer; const AValue : String);
- begin
- If (Fname=AValue) then exit;
- Fname:=AValue;
- MarkPropertyChanged(AIndex);
- end;
- Procedure TPathElement.Setid(AIndex : Integer; const AValue : String);
- begin
- If (Fid=AValue) then exit;
- Fid:=AValue;
- MarkPropertyChanged(AIndex);
- end;
- { --------------------------------------------------------------------
- TRollbackResponse
- --------------------------------------------------------------------}
- { --------------------------------------------------------------------
- TPropertyReference
- --------------------------------------------------------------------}
- Procedure TPropertyReference.Setname(AIndex : Integer; const AValue : String);
- begin
- If (Fname=AValue) then exit;
- Fname:=AValue;
- MarkPropertyChanged(AIndex);
- end;
- { --------------------------------------------------------------------
- TProjection
- --------------------------------------------------------------------}
- Procedure TProjection.Set_property(AIndex : Integer; const AValue : TPropertyReference);
- begin
- If (F_property=AValue) then exit;
- F_property:=AValue;
- MarkPropertyChanged(AIndex);
- end;
- Class Function TProjection.ExportPropertyName(Const AName : String) :String;
- begin
- Case AName of
- '_property' : Result:='property';
- else
- Result:=Inherited ExportPropertyName(AName);
- end;
- end;
- { --------------------------------------------------------------------
- TAllocateIdsResponse
- --------------------------------------------------------------------}
- Procedure TAllocateIdsResponse.Setkeys(AIndex : Integer; const AValue : TAllocateIdsResponseTypekeysArray);
- begin
- If (Fkeys=AValue) then exit;
- Fkeys:=AValue;
- MarkPropertyChanged(AIndex);
- end;
- //2.6.4. bug workaround
- {$IFDEF VER2_6}
- Procedure TAllocateIdsResponse.SetArrayLength(Const AName : String; ALength : Longint);
- begin
- Case AName of
- 'keys' : SetLength(Fkeys,ALength);
- else
- Inherited SetArrayLength(AName,ALength);
- end;
- end;
- {$ENDIF VER2_6}
- { --------------------------------------------------------------------
- TMutationResult
- --------------------------------------------------------------------}
- Procedure TMutationResult.Setkey(AIndex : Integer; const AValue : TKey);
- begin
- If (Fkey=AValue) then exit;
- Fkey:=AValue;
- MarkPropertyChanged(AIndex);
- end;
- { --------------------------------------------------------------------
- TLookupResponse
- --------------------------------------------------------------------}
- Procedure TLookupResponse.Setfound(AIndex : Integer; const AValue : TLookupResponseTypefoundArray);
- begin
- If (Ffound=AValue) then exit;
- Ffound:=AValue;
- MarkPropertyChanged(AIndex);
- end;
- Procedure TLookupResponse.Setdeferred(AIndex : Integer; const AValue : TLookupResponseTypedeferredArray);
- begin
- If (Fdeferred=AValue) then exit;
- Fdeferred:=AValue;
- MarkPropertyChanged(AIndex);
- end;
- Procedure TLookupResponse.Setmissing(AIndex : Integer; const AValue : TLookupResponseTypemissingArray);
- begin
- If (Fmissing=AValue) then exit;
- Fmissing:=AValue;
- MarkPropertyChanged(AIndex);
- end;
- //2.6.4. bug workaround
- {$IFDEF VER2_6}
- Procedure TLookupResponse.SetArrayLength(Const AName : String; ALength : Longint);
- begin
- Case AName of
- 'found' : SetLength(Ffound,ALength);
- 'deferred' : SetLength(Fdeferred,ALength);
- 'missing' : SetLength(Fmissing,ALength);
- else
- Inherited SetArrayLength(AName,ALength);
- end;
- end;
- {$ENDIF VER2_6}
- { --------------------------------------------------------------------
- TBeginTransactionRequest
- --------------------------------------------------------------------}
- { --------------------------------------------------------------------
- TKey
- --------------------------------------------------------------------}
- Procedure TKey.SetpartitionId(AIndex : Integer; const AValue : TPartitionId);
- begin
- If (FpartitionId=AValue) then exit;
- FpartitionId:=AValue;
- MarkPropertyChanged(AIndex);
- end;
- Procedure TKey.Setpath(AIndex : Integer; const AValue : TKeyTypepathArray);
- begin
- If (Fpath=AValue) then exit;
- Fpath:=AValue;
- MarkPropertyChanged(AIndex);
- end;
- //2.6.4. bug workaround
- {$IFDEF VER2_6}
- Procedure TKey.SetArrayLength(Const AName : String; ALength : Longint);
- begin
- Case AName of
- 'path' : SetLength(Fpath,ALength);
- else
- Inherited SetArrayLength(AName,ALength);
- end;
- end;
- {$ENDIF VER2_6}
- { --------------------------------------------------------------------
- TRunQueryResponse
- --------------------------------------------------------------------}
- Procedure TRunQueryResponse.Setbatch(AIndex : Integer; const AValue : TQueryResultBatch);
- begin
- If (Fbatch=AValue) then exit;
- Fbatch:=AValue;
- MarkPropertyChanged(AIndex);
- end;
- Procedure TRunQueryResponse.Setquery(AIndex : Integer; const AValue : TQuery);
- begin
- If (Fquery=AValue) then exit;
- Fquery:=AValue;
- MarkPropertyChanged(AIndex);
- end;
- { --------------------------------------------------------------------
- TEntityTypeproperties
- --------------------------------------------------------------------}
- Class Function TEntityTypeproperties.AllowAdditionalProperties : Boolean;
- begin
- Result:=True;
- end;
- { --------------------------------------------------------------------
- TEntity
- --------------------------------------------------------------------}
- Procedure TEntity.Setproperties(AIndex : Integer; const AValue : TEntityTypeproperties);
- begin
- If (Fproperties=AValue) then exit;
- Fproperties:=AValue;
- MarkPropertyChanged(AIndex);
- end;
- Procedure TEntity.Setkey(AIndex : Integer; const AValue : TKey);
- begin
- If (Fkey=AValue) then exit;
- Fkey:=AValue;
- MarkPropertyChanged(AIndex);
- end;
- { --------------------------------------------------------------------
- TGqlQueryTypenamedBindings
- --------------------------------------------------------------------}
- Class Function TGqlQueryTypenamedBindings.AllowAdditionalProperties : Boolean;
- begin
- Result:=True;
- end;
- { --------------------------------------------------------------------
- TGqlQuery
- --------------------------------------------------------------------}
- Procedure TGqlQuery.SetnamedBindings(AIndex : Integer; const AValue : TGqlQueryTypenamedBindings);
- begin
- If (FnamedBindings=AValue) then exit;
- FnamedBindings:=AValue;
- MarkPropertyChanged(AIndex);
- end;
- Procedure TGqlQuery.SetqueryString(AIndex : Integer; const AValue : String);
- begin
- If (FqueryString=AValue) then exit;
- FqueryString:=AValue;
- MarkPropertyChanged(AIndex);
- end;
- Procedure TGqlQuery.SetallowLiterals(AIndex : Integer; const AValue : boolean);
- begin
- If (FallowLiterals=AValue) then exit;
- FallowLiterals:=AValue;
- MarkPropertyChanged(AIndex);
- end;
- Procedure TGqlQuery.SetpositionalBindings(AIndex : Integer; const AValue : TGqlQueryTypepositionalBindingsArray);
- begin
- If (FpositionalBindings=AValue) then exit;
- FpositionalBindings:=AValue;
- MarkPropertyChanged(AIndex);
- end;
- //2.6.4. bug workaround
- {$IFDEF VER2_6}
- Procedure TGqlQuery.SetArrayLength(Const AName : String; ALength : Longint);
- begin
- Case AName of
- 'positionalbindings' : SetLength(FpositionalBindings,ALength);
- else
- Inherited SetArrayLength(AName,ALength);
- end;
- end;
- {$ENDIF VER2_6}
- { --------------------------------------------------------------------
- TCommitResponse
- --------------------------------------------------------------------}
- Procedure TCommitResponse.SetmutationResults(AIndex : Integer; const AValue : TCommitResponseTypemutationResultsArray);
- begin
- If (FmutationResults=AValue) then exit;
- FmutationResults:=AValue;
- MarkPropertyChanged(AIndex);
- end;
- Procedure TCommitResponse.SetindexUpdates(AIndex : Integer; const AValue : integer);
- begin
- If (FindexUpdates=AValue) then exit;
- FindexUpdates:=AValue;
- MarkPropertyChanged(AIndex);
- end;
- //2.6.4. bug workaround
- {$IFDEF VER2_6}
- Procedure TCommitResponse.SetArrayLength(Const AName : String; ALength : Longint);
- begin
- Case AName of
- 'mutationresults' : SetLength(FmutationResults,ALength);
- else
- Inherited SetArrayLength(AName,ALength);
- end;
- end;
- {$ENDIF VER2_6}
- { --------------------------------------------------------------------
- TMutation
- --------------------------------------------------------------------}
- Procedure TMutation.Setupdate(AIndex : Integer; const AValue : TEntity);
- begin
- If (Fupdate=AValue) then exit;
- Fupdate:=AValue;
- MarkPropertyChanged(AIndex);
- end;
- Procedure TMutation.Setinsert(AIndex : Integer; const AValue : TEntity);
- begin
- If (Finsert=AValue) then exit;
- Finsert:=AValue;
- MarkPropertyChanged(AIndex);
- end;
- Procedure TMutation.Setdelete(AIndex : Integer; const AValue : TKey);
- begin
- If (Fdelete=AValue) then exit;
- Fdelete:=AValue;
- MarkPropertyChanged(AIndex);
- end;
- Procedure TMutation.Setupsert(AIndex : Integer; const AValue : TEntity);
- begin
- If (Fupsert=AValue) then exit;
- Fupsert:=AValue;
- MarkPropertyChanged(AIndex);
- end;
- { --------------------------------------------------------------------
- TRunQueryRequest
- --------------------------------------------------------------------}
- Procedure TRunQueryRequest.SetpartitionId(AIndex : Integer; const AValue : TPartitionId);
- begin
- If (FpartitionId=AValue) then exit;
- FpartitionId:=AValue;
- MarkPropertyChanged(AIndex);
- end;
- Procedure TRunQueryRequest.SetgqlQuery(AIndex : Integer; const AValue : TGqlQuery);
- begin
- If (FgqlQuery=AValue) then exit;
- FgqlQuery:=AValue;
- MarkPropertyChanged(AIndex);
- end;
- Procedure TRunQueryRequest.Setquery(AIndex : Integer; const AValue : TQuery);
- begin
- If (Fquery=AValue) then exit;
- Fquery:=AValue;
- MarkPropertyChanged(AIndex);
- end;
- Procedure TRunQueryRequest.SetreadOptions(AIndex : Integer; const AValue : TReadOptions);
- begin
- If (FreadOptions=AValue) then exit;
- FreadOptions:=AValue;
- MarkPropertyChanged(AIndex);
- end;
- { --------------------------------------------------------------------
- TCompositeFilter
- --------------------------------------------------------------------}
- Procedure TCompositeFilter.Setop(AIndex : Integer; const AValue : String);
- begin
- If (Fop=AValue) then exit;
- Fop:=AValue;
- MarkPropertyChanged(AIndex);
- end;
- Procedure TCompositeFilter.Setfilters(AIndex : Integer; const AValue : TCompositeFilterTypefiltersArray);
- begin
- If (Ffilters=AValue) then exit;
- Ffilters:=AValue;
- MarkPropertyChanged(AIndex);
- end;
- //2.6.4. bug workaround
- {$IFDEF VER2_6}
- Procedure TCompositeFilter.SetArrayLength(Const AName : String; ALength : Longint);
- begin
- Case AName of
- 'filters' : SetLength(Ffilters,ALength);
- else
- Inherited SetArrayLength(AName,ALength);
- end;
- end;
- {$ENDIF VER2_6}
- { --------------------------------------------------------------------
- TLatLng
- --------------------------------------------------------------------}
- Procedure TLatLng.Setlongitude(AIndex : Integer; const AValue : double);
- begin
- If (Flongitude=AValue) then exit;
- Flongitude:=AValue;
- MarkPropertyChanged(AIndex);
- end;
- Procedure TLatLng.Setlatitude(AIndex : Integer; const AValue : double);
- begin
- If (Flatitude=AValue) then exit;
- Flatitude:=AValue;
- MarkPropertyChanged(AIndex);
- end;
- { --------------------------------------------------------------------
- TLookupRequest
- --------------------------------------------------------------------}
- Procedure TLookupRequest.Setkeys(AIndex : Integer; const AValue : TLookupRequestTypekeysArray);
- begin
- If (Fkeys=AValue) then exit;
- Fkeys:=AValue;
- MarkPropertyChanged(AIndex);
- end;
- Procedure TLookupRequest.SetreadOptions(AIndex : Integer; const AValue : TReadOptions);
- begin
- If (FreadOptions=AValue) then exit;
- FreadOptions:=AValue;
- MarkPropertyChanged(AIndex);
- end;
- //2.6.4. bug workaround
- {$IFDEF VER2_6}
- Procedure TLookupRequest.SetArrayLength(Const AName : String; ALength : Longint);
- begin
- Case AName of
- 'keys' : SetLength(Fkeys,ALength);
- else
- Inherited SetArrayLength(AName,ALength);
- end;
- end;
- {$ENDIF VER2_6}
- { --------------------------------------------------------------------
- TProjectsResource
- --------------------------------------------------------------------}
- Class Function TProjectsResource.ResourceName : String;
- begin
- Result:='projects';
- end;
- Class Function TProjectsResource.DefaultAPI : TGoogleAPIClass;
- begin
- Result:=TdatastoreAPI;
- end;
- Function TProjectsResource.RunQuery(projectId: string; aRunQueryRequest : TRunQueryRequest) : TRunQueryResponse;
- Const
- _HTTPMethod = 'POST';
- _Path = 'v1beta3/projects/{projectId}:runQuery';
- _Methodid = 'datastore.projects.runQuery';
- Var
- _P : String;
- begin
- _P:=SubstitutePath(_Path,['projectId',projectId]);
- Result:=ServiceCall(_HTTPMethod,_P,'',aRunQueryRequest,TRunQueryResponse) as TRunQueryResponse;
- end;
- Function TProjectsResource.BeginTransaction(projectId: string; aBeginTransactionRequest : TBeginTransactionRequest) : TBeginTransactionResponse;
- Const
- _HTTPMethod = 'POST';
- _Path = 'v1beta3/projects/{projectId}:beginTransaction';
- _Methodid = 'datastore.projects.beginTransaction';
- Var
- _P : String;
- begin
- _P:=SubstitutePath(_Path,['projectId',projectId]);
- Result:=ServiceCall(_HTTPMethod,_P,'',aBeginTransactionRequest,TBeginTransactionResponse) as TBeginTransactionResponse;
- end;
- Function TProjectsResource.AllocateIds(projectId: string; aAllocateIdsRequest : TAllocateIdsRequest) : TAllocateIdsResponse;
- Const
- _HTTPMethod = 'POST';
- _Path = 'v1beta3/projects/{projectId}:allocateIds';
- _Methodid = 'datastore.projects.allocateIds';
- Var
- _P : String;
- begin
- _P:=SubstitutePath(_Path,['projectId',projectId]);
- Result:=ServiceCall(_HTTPMethod,_P,'',aAllocateIdsRequest,TAllocateIdsResponse) as TAllocateIdsResponse;
- end;
- Function TProjectsResource.Lookup(projectId: string; aLookupRequest : TLookupRequest) : TLookupResponse;
- Const
- _HTTPMethod = 'POST';
- _Path = 'v1beta3/projects/{projectId}:lookup';
- _Methodid = 'datastore.projects.lookup';
- Var
- _P : String;
- begin
- _P:=SubstitutePath(_Path,['projectId',projectId]);
- Result:=ServiceCall(_HTTPMethod,_P,'',aLookupRequest,TLookupResponse) as TLookupResponse;
- end;
- Function TProjectsResource.Commit(projectId: string; aCommitRequest : TCommitRequest) : TCommitResponse;
- Const
- _HTTPMethod = 'POST';
- _Path = 'v1beta3/projects/{projectId}:commit';
- _Methodid = 'datastore.projects.commit';
- Var
- _P : String;
- begin
- _P:=SubstitutePath(_Path,['projectId',projectId]);
- Result:=ServiceCall(_HTTPMethod,_P,'',aCommitRequest,TCommitResponse) as TCommitResponse;
- end;
- Function TProjectsResource.Rollback(projectId: string; aRollbackRequest : TRollbackRequest) : TRollbackResponse;
- Const
- _HTTPMethod = 'POST';
- _Path = 'v1beta3/projects/{projectId}:rollback';
- _Methodid = 'datastore.projects.rollback';
- Var
- _P : String;
- begin
- _P:=SubstitutePath(_Path,['projectId',projectId]);
- Result:=ServiceCall(_HTTPMethod,_P,'',aRollbackRequest,TRollbackResponse) as TRollbackResponse;
- end;
- { --------------------------------------------------------------------
- TDatastoreAPI
- --------------------------------------------------------------------}
- Class Function TDatastoreAPI.APIName : String;
- begin
- Result:='datastore';
- end;
- Class Function TDatastoreAPI.APIVersion : String;
- begin
- Result:='v1beta3';
- end;
- Class Function TDatastoreAPI.APIRevision : String;
- begin
- Result:='20160502';
- end;
- Class Function TDatastoreAPI.APIID : String;
- begin
- Result:='datastore:v1beta3';
- end;
- Class Function TDatastoreAPI.APITitle : String;
- begin
- Result:='Google Cloud Datastore API';
- end;
- Class Function TDatastoreAPI.APIDescription : String;
- begin
- Result:='Accesses the schemaless NoSQL database to provide fully managed, robust, scalable storage for your application.';
- end;
- Class Function TDatastoreAPI.APIOwnerDomain : String;
- begin
- Result:='google.com';
- end;
- Class Function TDatastoreAPI.APIOwnerName : String;
- begin
- Result:='Google';
- end;
- Class Function TDatastoreAPI.APIIcon16 : String;
- begin
- Result:='http://www.google.com/images/icons/product/search-16.gif';
- end;
- Class Function TDatastoreAPI.APIIcon32 : String;
- begin
- Result:='http://www.google.com/images/icons/product/search-32.gif';
- end;
- Class Function TDatastoreAPI.APIdocumentationLink : String;
- begin
- Result:='https://cloud.google.com/datastore/';
- end;
- Class Function TDatastoreAPI.APIrootUrl : string;
- begin
- Result:='https://datastore.googleapis.com/';
- end;
- Class Function TDatastoreAPI.APIbasePath : string;
- begin
- Result:='';
- end;
- Class Function TDatastoreAPI.APIbaseURL : String;
- begin
- Result:='https://datastore.googleapis.com/';
- end;
- Class Function TDatastoreAPI.APIProtocol : string;
- begin
- Result:='rest';
- end;
- Class Function TDatastoreAPI.APIservicePath : string;
- begin
- Result:='';
- end;
- Class Function TDatastoreAPI.APIbatchPath : String;
- begin
- Result:='batch';
- end;
- Class Function TDatastoreAPI.APIAuthScopes : TScopeInfoArray;
- begin
- SetLength(Result,2);
- Result[0].Name:='https://www.googleapis.com/auth/cloud-platform';
- Result[0].Description:='View and manage your data across Google Cloud Platform services';
- Result[1].Name:='https://www.googleapis.com/auth/datastore';
- Result[1].Description:='View and manage your Google Cloud Datastore data';
-
- end;
- Class Function TDatastoreAPI.APINeedsAuth : Boolean;
- begin
- Result:=True;
- end;
- Class Procedure TDatastoreAPI.RegisterAPIResources;
- begin
- TValue.RegisterObject;
- TReadOptions.RegisterObject;
- TPropertyOrder.RegisterObject;
- TCommitRequest.RegisterObject;
- TRollbackRequest.RegisterObject;
- TQuery.RegisterObject;
- TEntityResult.RegisterObject;
- TGqlQueryParameter.RegisterObject;
- TBeginTransactionResponse.RegisterObject;
- TFilter.RegisterObject;
- TArrayValue.RegisterObject;
- TPartitionId.RegisterObject;
- TQueryResultBatch.RegisterObject;
- TAllocateIdsRequest.RegisterObject;
- TPropertyFilter.RegisterObject;
- TKindExpression.RegisterObject;
- TPathElement.RegisterObject;
- TRollbackResponse.RegisterObject;
- TPropertyReference.RegisterObject;
- TProjection.RegisterObject;
- TAllocateIdsResponse.RegisterObject;
- TMutationResult.RegisterObject;
- TLookupResponse.RegisterObject;
- TBeginTransactionRequest.RegisterObject;
- TKey.RegisterObject;
- TRunQueryResponse.RegisterObject;
- TEntityTypeproperties.RegisterObject;
- TEntity.RegisterObject;
- TGqlQueryTypenamedBindings.RegisterObject;
- TGqlQuery.RegisterObject;
- TCommitResponse.RegisterObject;
- TMutation.RegisterObject;
- TRunQueryRequest.RegisterObject;
- TCompositeFilter.RegisterObject;
- TLatLng.RegisterObject;
- TLookupRequest.RegisterObject;
- end;
- Function TDatastoreAPI.GetProjectsInstance : TProjectsResource;
- begin
- if (FProjectsInstance=Nil) then
- FProjectsInstance:=CreateProjectsResource;
- Result:=FProjectsInstance;
- end;
- Function TDatastoreAPI.CreateProjectsResource : TProjectsResource;
- begin
- Result:=CreateProjectsResource(Self);
- end;
- Function TDatastoreAPI.CreateProjectsResource(AOwner : TComponent) : TProjectsResource;
- begin
- Result:=TProjectsResource.Create(AOwner);
- Result.API:=Self.API;
- end;
- initialization
- TDatastoreAPI.RegisterAPI;
- end.
|