googleadsense.pp 173 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349135013511352135313541355135613571358135913601361136213631364136513661367136813691370137113721373137413751376137713781379138013811382138313841385138613871388138913901391139213931394139513961397139813991400140114021403140414051406140714081409141014111412141314141415141614171418141914201421142214231424142514261427142814291430143114321433143414351436143714381439144014411442144314441445144614471448144914501451145214531454145514561457145814591460146114621463146414651466146714681469147014711472147314741475147614771478147914801481148214831484148514861487148814891490149114921493149414951496149714981499150015011502150315041505150615071508150915101511151215131514151515161517151815191520152115221523152415251526152715281529153015311532153315341535153615371538153915401541154215431544154515461547154815491550155115521553155415551556155715581559156015611562156315641565156615671568156915701571157215731574157515761577157815791580158115821583158415851586158715881589159015911592159315941595159615971598159916001601160216031604160516061607160816091610161116121613161416151616161716181619162016211622162316241625162616271628162916301631163216331634163516361637163816391640164116421643164416451646164716481649165016511652165316541655165616571658165916601661166216631664166516661667166816691670167116721673167416751676167716781679168016811682168316841685168616871688168916901691169216931694169516961697169816991700170117021703170417051706170717081709171017111712171317141715171617171718171917201721172217231724172517261727172817291730173117321733173417351736173717381739174017411742174317441745174617471748174917501751175217531754175517561757175817591760176117621763176417651766176717681769177017711772177317741775177617771778177917801781178217831784178517861787178817891790179117921793179417951796179717981799180018011802180318041805180618071808180918101811181218131814181518161817181818191820182118221823182418251826182718281829183018311832183318341835183618371838183918401841184218431844184518461847184818491850185118521853185418551856185718581859186018611862186318641865186618671868186918701871187218731874187518761877187818791880188118821883188418851886188718881889189018911892189318941895189618971898189919001901190219031904190519061907190819091910191119121913191419151916191719181919192019211922192319241925192619271928192919301931193219331934193519361937193819391940194119421943194419451946194719481949195019511952195319541955195619571958195919601961196219631964196519661967196819691970197119721973197419751976197719781979198019811982198319841985198619871988198919901991199219931994199519961997199819992000200120022003200420052006200720082009201020112012201320142015201620172018201920202021202220232024202520262027202820292030203120322033203420352036203720382039204020412042204320442045204620472048204920502051205220532054205520562057205820592060206120622063206420652066206720682069207020712072207320742075207620772078207920802081208220832084208520862087208820892090209120922093209420952096209720982099210021012102210321042105210621072108210921102111211221132114211521162117211821192120212121222123212421252126212721282129213021312132213321342135213621372138213921402141214221432144214521462147214821492150215121522153215421552156215721582159216021612162216321642165216621672168216921702171217221732174217521762177217821792180218121822183218421852186218721882189219021912192219321942195219621972198219922002201220222032204220522062207220822092210221122122213221422152216221722182219222022212222222322242225222622272228222922302231223222332234223522362237223822392240224122422243224422452246224722482249225022512252225322542255225622572258225922602261226222632264226522662267226822692270227122722273227422752276227722782279228022812282228322842285228622872288228922902291229222932294229522962297229822992300230123022303230423052306230723082309231023112312231323142315231623172318231923202321232223232324232523262327232823292330233123322333233423352336233723382339234023412342234323442345234623472348234923502351235223532354235523562357235823592360236123622363236423652366236723682369237023712372237323742375237623772378237923802381238223832384238523862387238823892390239123922393239423952396239723982399240024012402240324042405240624072408240924102411241224132414241524162417241824192420242124222423242424252426242724282429243024312432243324342435243624372438243924402441244224432444244524462447244824492450245124522453245424552456245724582459246024612462246324642465246624672468246924702471247224732474247524762477247824792480248124822483248424852486248724882489249024912492249324942495249624972498249925002501250225032504250525062507250825092510251125122513251425152516251725182519252025212522252325242525252625272528252925302531253225332534253525362537253825392540254125422543254425452546254725482549255025512552255325542555255625572558255925602561256225632564256525662567256825692570257125722573257425752576257725782579258025812582258325842585258625872588258925902591259225932594259525962597259825992600260126022603260426052606260726082609261026112612261326142615261626172618261926202621262226232624262526262627262826292630263126322633263426352636263726382639264026412642264326442645264626472648264926502651265226532654265526562657265826592660266126622663266426652666266726682669267026712672267326742675267626772678267926802681268226832684268526862687268826892690269126922693269426952696269726982699270027012702270327042705270627072708270927102711271227132714271527162717271827192720272127222723272427252726272727282729273027312732273327342735273627372738273927402741274227432744274527462747274827492750275127522753275427552756275727582759276027612762276327642765276627672768276927702771277227732774277527762777277827792780278127822783278427852786278727882789279027912792279327942795279627972798279928002801280228032804280528062807280828092810281128122813281428152816281728182819282028212822282328242825282628272828282928302831283228332834283528362837283828392840284128422843284428452846284728482849285028512852285328542855285628572858285928602861286228632864286528662867286828692870287128722873287428752876287728782879288028812882288328842885288628872888288928902891289228932894289528962897289828992900290129022903290429052906290729082909291029112912291329142915291629172918291929202921292229232924292529262927292829292930293129322933293429352936293729382939294029412942294329442945294629472948294929502951295229532954295529562957295829592960296129622963296429652966296729682969297029712972297329742975297629772978297929802981298229832984298529862987298829892990299129922993299429952996299729982999300030013002300330043005300630073008300930103011301230133014301530163017301830193020302130223023302430253026302730283029303030313032303330343035303630373038303930403041304230433044304530463047304830493050305130523053305430553056305730583059306030613062306330643065306630673068306930703071307230733074307530763077307830793080308130823083308430853086308730883089309030913092309330943095309630973098309931003101310231033104310531063107310831093110311131123113311431153116311731183119312031213122312331243125312631273128312931303131313231333134313531363137313831393140314131423143314431453146314731483149315031513152315331543155315631573158315931603161316231633164316531663167316831693170317131723173317431753176317731783179318031813182318331843185318631873188318931903191319231933194319531963197319831993200320132023203320432053206320732083209321032113212321332143215321632173218321932203221322232233224322532263227322832293230323132323233323432353236323732383239324032413242324332443245324632473248324932503251325232533254325532563257325832593260326132623263326432653266326732683269327032713272327332743275327632773278327932803281328232833284328532863287328832893290329132923293329432953296329732983299330033013302330333043305330633073308330933103311331233133314331533163317331833193320332133223323332433253326332733283329333033313332333333343335333633373338333933403341334233433344334533463347334833493350335133523353335433553356335733583359336033613362336333643365336633673368336933703371337233733374337533763377337833793380338133823383338433853386338733883389339033913392339333943395339633973398339934003401340234033404340534063407340834093410341134123413341434153416341734183419342034213422342334243425342634273428342934303431343234333434343534363437343834393440344134423443344434453446344734483449345034513452345334543455345634573458345934603461346234633464346534663467346834693470347134723473347434753476347734783479348034813482348334843485348634873488348934903491349234933494349534963497349834993500350135023503350435053506350735083509351035113512351335143515351635173518351935203521352235233524352535263527352835293530353135323533353435353536353735383539354035413542354335443545354635473548354935503551355235533554355535563557355835593560356135623563356435653566356735683569357035713572357335743575357635773578357935803581358235833584358535863587358835893590359135923593359435953596359735983599360036013602360336043605360636073608360936103611361236133614361536163617361836193620362136223623362436253626362736283629363036313632363336343635363636373638363936403641364236433644364536463647364836493650365136523653365436553656365736583659366036613662366336643665366636673668366936703671367236733674367536763677367836793680368136823683368436853686368736883689369036913692369336943695369636973698369937003701370237033704370537063707370837093710371137123713371437153716371737183719372037213722372337243725372637273728372937303731373237333734373537363737373837393740374137423743374437453746374737483749375037513752375337543755375637573758375937603761376237633764376537663767376837693770377137723773377437753776377737783779378037813782378337843785378637873788378937903791379237933794379537963797379837993800380138023803380438053806380738083809381038113812381338143815381638173818381938203821382238233824382538263827382838293830383138323833383438353836383738383839384038413842384338443845384638473848384938503851385238533854385538563857385838593860386138623863386438653866386738683869387038713872387338743875387638773878387938803881388238833884388538863887388838893890389138923893389438953896389738983899390039013902390339043905390639073908390939103911391239133914391539163917391839193920392139223923392439253926392739283929393039313932393339343935393639373938393939403941394239433944394539463947394839493950395139523953395439553956395739583959396039613962396339643965396639673968396939703971397239733974397539763977397839793980398139823983398439853986398739883989399039913992399339943995399639973998399940004001400240034004400540064007400840094010401140124013401440154016401740184019402040214022402340244025402640274028402940304031403240334034403540364037403840394040404140424043404440454046404740484049405040514052405340544055405640574058405940604061406240634064406540664067406840694070407140724073407440754076407740784079408040814082408340844085408640874088408940904091409240934094409540964097409840994100410141024103410441054106410741084109411041114112411341144115411641174118411941204121412241234124412541264127412841294130413141324133413441354136413741384139414041414142414341444145414641474148414941504151415241534154415541564157415841594160416141624163416441654166416741684169417041714172417341744175417641774178417941804181418241834184418541864187418841894190419141924193419441954196419741984199420042014202420342044205420642074208420942104211421242134214421542164217421842194220422142224223422442254226422742284229423042314232423342344235423642374238423942404241424242434244424542464247424842494250425142524253425442554256425742584259426042614262426342644265426642674268426942704271427242734274427542764277427842794280428142824283428442854286428742884289429042914292429342944295429642974298429943004301430243034304430543064307430843094310431143124313431443154316431743184319432043214322432343244325432643274328432943304331433243334334433543364337433843394340434143424343434443454346434743484349435043514352435343544355435643574358435943604361436243634364436543664367436843694370437143724373437443754376437743784379438043814382438343844385438643874388438943904391439243934394439543964397439843994400440144024403440444054406440744084409441044114412441344144415441644174418441944204421442244234424442544264427442844294430443144324433443444354436443744384439444044414442444344444445444644474448444944504451445244534454445544564457445844594460446144624463446444654466446744684469447044714472447344744475447644774478447944804481448244834484448544864487448844894490449144924493449444954496449744984499450045014502450345044505450645074508450945104511451245134514451545164517451845194520452145224523452445254526452745284529453045314532453345344535453645374538453945404541454245434544454545464547454845494550455145524553455445554556455745584559456045614562456345644565456645674568456945704571457245734574457545764577457845794580458145824583458445854586458745884589459045914592459345944595459645974598459946004601460246034604460546064607460846094610461146124613461446154616461746184619462046214622462346244625462646274628462946304631463246334634463546364637463846394640464146424643464446454646464746484649465046514652465346544655465646574658465946604661466246634664466546664667466846694670467146724673467446754676467746784679468046814682468346844685468646874688468946904691469246934694469546964697469846994700470147024703470447054706470747084709471047114712471347144715471647174718471947204721472247234724472547264727472847294730473147324733473447354736473747384739474047414742474347444745474647474748474947504751475247534754475547564757475847594760476147624763476447654766476747684769477047714772477347744775477647774778477947804781478247834784478547864787478847894790479147924793479447954796479747984799480048014802480348044805480648074808480948104811481248134814481548164817481848194820482148224823482448254826482748284829483048314832483348344835483648374838483948404841484248434844484548464847484848494850485148524853485448554856485748584859486048614862486348644865486648674868486948704871487248734874487548764877487848794880488148824883488448854886488748884889489048914892489348944895489648974898489949004901490249034904490549064907490849094910491149124913491449154916491749184919492049214922492349244925492649274928492949304931493249334934493549364937493849394940494149424943494449454946494749484949495049514952495349544955495649574958495949604961496249634964496549664967496849694970497149724973497449754976497749784979498049814982498349844985498649874988498949904991499249934994499549964997499849995000500150025003500450055006500750085009501050115012501350145015501650175018501950205021502250235024502550265027502850295030503150325033503450355036503750385039504050415042504350445045504650475048504950505051505250535054505550565057505850595060506150625063506450655066506750685069507050715072507350745075507650775078507950805081508250835084508550865087508850895090509150925093509450955096509750985099510051015102510351045105510651075108510951105111511251135114511551165117511851195120512151225123512451255126512751285129513051315132513351345135513651375138513951405141514251435144514551465147514851495150515151525153515451555156515751585159516051615162516351645165516651675168516951705171517251735174517551765177517851795180518151825183518451855186518751885189519051915192519351945195519651975198519952005201520252035204520552065207520852095210521152125213521452155216521752185219522052215222522352245225522652275228522952305231523252335234523552365237523852395240524152425243524452455246524752485249525052515252525352545255525652575258525952605261526252635264526552665267526852695270527152725273527452755276527752785279528052815282528352845285528652875288528952905291529252935294529552965297529852995300530153025303530453055306530753085309531053115312531353145315531653175318531953205321532253235324532553265327532853295330533153325333533453355336533753385339534053415342534353445345534653475348534953505351535253535354535553565357535853595360536153625363536453655366536753685369537053715372537353745375537653775378537953805381538253835384538553865387538853895390539153925393539453955396539753985399540054015402540354045405540654075408540954105411541254135414541554165417541854195420542154225423542454255426542754285429543054315432543354345435543654375438543954405441544254435444544554465447544854495450545154525453545454555456545754585459546054615462546354645465546654675468546954705471547254735474547554765477547854795480548154825483548454855486548754885489549054915492549354945495549654975498549955005501550255035504550555065507550855095510551155125513551455155516551755185519552055215522552355245525552655275528552955305531553255335534553555365537553855395540554155425543554455455546554755485549555055515552555355545555555655575558555955605561556255635564556555665567556855695570557155725573557455755576557755785579558055815582558355845585558655875588558955905591559255935594559555965597559855995600560156025603560456055606560756085609561056115612561356145615561656175618561956205621562256235624562556265627562856295630563156325633563456355636563756385639564056415642564356445645564656475648564956505651565256535654565556565657565856595660566156625663566456655666566756685669567056715672567356745675567656775678567956805681568256835684568556865687568856895690569156925693569456955696569756985699570057015702570357045705570657075708570957105711571257135714571557165717571857195720572157225723572457255726572757285729573057315732573357345735573657375738573957405741574257435744574557465747574857495750575157525753575457555756575757585759576057615762576357645765576657675768576957705771577257735774577557765777577857795780578157825783578457855786578757885789579057915792579357945795579657975798579958005801580258035804580558065807580858095810581158125813581458155816581758185819582058215822582358245825582658275828582958305831583258335834583558365837583858395840584158425843584458455846584758485849585058515852585358545855585658575858585958605861586258635864586558665867586858695870587158725873587458755876587758785879588058815882588358845885588658875888588958905891589258935894589558965897589858995900590159025903590459055906590759085909591059115912591359145915591659175918591959205921592259235924592559265927592859295930593159325933593459355936593759385939594059415942594359445945594659475948594959505951595259535954595559565957595859595960596159625963596459655966596759685969597059715972597359745975597659775978597959805981598259835984598559865987598859895990599159925993599459955996599759985999600060016002600360046005600660076008600960106011601260136014601560166017601860196020602160226023602460256026602760286029603060316032603360346035603660376038603960406041604260436044604560466047604860496050605160526053605460556056605760586059606060616062606360646065606660676068606960706071607260736074607560766077607860796080608160826083608460856086608760886089609060916092609360946095609660976098609961006101610261036104610561066107610861096110611161126113611461156116611761186119612061216122612361246125612661276128612961306131613261336134613561366137613861396140614161426143614461456146614761486149615061516152
  1. unit googleadsense;
  2. {$MODE objfpc}
  3. {$H+}
  4. interface
  5. uses sysutils, classes, googleservice, restbase, googlebase;
  6. type
  7. //Top-level schema types
  8. TAccount = Class;
  9. TAccounts = Class;
  10. TAdClient = Class;
  11. TAdClients = Class;
  12. TAdCode = Class;
  13. TAdStyle = Class;
  14. TAdUnit = Class;
  15. TAdUnits = Class;
  16. TAdsenseReportsGenerateResponse = Class;
  17. TAlert = Class;
  18. TAlerts = Class;
  19. TCustomChannel = Class;
  20. TCustomChannels = Class;
  21. TMetadata = Class;
  22. TPayment = Class;
  23. TPayments = Class;
  24. TReportingMetadataEntry = Class;
  25. TSavedAdStyle = Class;
  26. TSavedAdStyles = Class;
  27. TSavedReport = Class;
  28. TSavedReports = Class;
  29. TUrlChannel = Class;
  30. TUrlChannels = Class;
  31. TAccountArray = Array of TAccount;
  32. TAccountsArray = Array of TAccounts;
  33. TAdClientArray = Array of TAdClient;
  34. TAdClientsArray = Array of TAdClients;
  35. TAdCodeArray = Array of TAdCode;
  36. TAdStyleArray = Array of TAdStyle;
  37. TAdUnitArray = Array of TAdUnit;
  38. TAdUnitsArray = Array of TAdUnits;
  39. TAdsenseReportsGenerateResponseArray = Array of TAdsenseReportsGenerateResponse;
  40. TAlertArray = Array of TAlert;
  41. TAlertsArray = Array of TAlerts;
  42. TCustomChannelArray = Array of TCustomChannel;
  43. TCustomChannelsArray = Array of TCustomChannels;
  44. TMetadataArray = Array of TMetadata;
  45. TPaymentArray = Array of TPayment;
  46. TPaymentsArray = Array of TPayments;
  47. TReportingMetadataEntryArray = Array of TReportingMetadataEntry;
  48. TSavedAdStyleArray = Array of TSavedAdStyle;
  49. TSavedAdStylesArray = Array of TSavedAdStyles;
  50. TSavedReportArray = Array of TSavedReport;
  51. TSavedReportsArray = Array of TSavedReports;
  52. TUrlChannelArray = Array of TUrlChannel;
  53. TUrlChannelsArray = Array of TUrlChannels;
  54. //Anonymous types, using auto-generated names
  55. TAdStyleTypecolors = Class;
  56. TAdStyleTypefont = Class;
  57. TAdUnitTypecontentAdsSettingsTypebackupOption = Class;
  58. TAdUnitTypecontentAdsSettings = Class;
  59. TAdUnitTypefeedAdsSettings = Class;
  60. TAdUnitTypemobileContentAdsSettings = Class;
  61. TAdsenseReportsGenerateResponseTypeheadersItem = Class;
  62. TCustomChannelTypetargetingInfo = Class;
  63. TAccountTypesubAccountsArray = Array of TAccount;
  64. TAccountsTypeitemsArray = Array of TAccount;
  65. TAdClientsTypeitemsArray = Array of TAdClient;
  66. TAdUnitsTypeitemsArray = Array of TAdUnit;
  67. TAdsenseReportsGenerateResponseTypeheadersArray = Array of TAdsenseReportsGenerateResponseTypeheadersItem;
  68. TAdsenseReportsGenerateResponseTyperowsArray = Array of TStringArray;
  69. TAlertsTypeitemsArray = Array of TAlert;
  70. TCustomChannelsTypeitemsArray = Array of TCustomChannel;
  71. TMetadataTypeitemsArray = Array of TReportingMetadataEntry;
  72. TPaymentsTypeitemsArray = Array of TPayment;
  73. TSavedAdStylesTypeitemsArray = Array of TSavedAdStyle;
  74. TSavedReportsTypeitemsArray = Array of TSavedReport;
  75. TUrlChannelsTypeitemsArray = Array of TUrlChannel;
  76. { --------------------------------------------------------------------
  77. TAccount
  78. --------------------------------------------------------------------}
  79. TAccount = Class(TGoogleBaseObject)
  80. Private
  81. Fcreation_time : String;
  82. Fid : String;
  83. Fkind : String;
  84. Fname : String;
  85. Fpremium : boolean;
  86. FsubAccounts : TAccountTypesubAccountsArray;
  87. Ftimezone : String;
  88. Protected
  89. //Property setters
  90. Procedure Setcreation_time(AIndex : Integer; const AValue : String); virtual;
  91. Procedure Setid(AIndex : Integer; const AValue : String); virtual;
  92. Procedure Setkind(AIndex : Integer; const AValue : String); virtual;
  93. Procedure Setname(AIndex : Integer; const AValue : String); virtual;
  94. Procedure Setpremium(AIndex : Integer; const AValue : boolean); virtual;
  95. Procedure SetsubAccounts(AIndex : Integer; const AValue : TAccountTypesubAccountsArray); virtual;
  96. Procedure Settimezone(AIndex : Integer; const AValue : String); virtual;
  97. //2.6.4. bug workaround
  98. {$IFDEF VER2_6}
  99. Procedure SetArrayLength(Const AName : String; ALength : Longint); override;
  100. {$ENDIF VER2_6}
  101. Public
  102. Published
  103. Property creation_time : String Index 0 Read Fcreation_time Write Setcreation_time;
  104. Property id : String Index 8 Read Fid Write Setid;
  105. Property kind : String Index 16 Read Fkind Write Setkind;
  106. Property name : String Index 24 Read Fname Write Setname;
  107. Property premium : boolean Index 32 Read Fpremium Write Setpremium;
  108. Property subAccounts : TAccountTypesubAccountsArray Index 40 Read FsubAccounts Write SetsubAccounts;
  109. Property timezone : String Index 48 Read Ftimezone Write Settimezone;
  110. end;
  111. TAccountClass = Class of TAccount;
  112. { --------------------------------------------------------------------
  113. TAccounts
  114. --------------------------------------------------------------------}
  115. TAccounts = Class(TGoogleBaseObject)
  116. Private
  117. Fetag : String;
  118. Fitems : TAccountsTypeitemsArray;
  119. Fkind : String;
  120. FnextPageToken : String;
  121. Protected
  122. //Property setters
  123. Procedure Setetag(AIndex : Integer; const AValue : String); virtual;
  124. Procedure Setitems(AIndex : Integer; const AValue : TAccountsTypeitemsArray); virtual;
  125. Procedure Setkind(AIndex : Integer; const AValue : String); virtual;
  126. Procedure SetnextPageToken(AIndex : Integer; const AValue : String); virtual;
  127. //2.6.4. bug workaround
  128. {$IFDEF VER2_6}
  129. Procedure SetArrayLength(Const AName : String; ALength : Longint); override;
  130. {$ENDIF VER2_6}
  131. Public
  132. Published
  133. Property etag : String Index 0 Read Fetag Write Setetag;
  134. Property items : TAccountsTypeitemsArray Index 8 Read Fitems Write Setitems;
  135. Property kind : String Index 16 Read Fkind Write Setkind;
  136. Property nextPageToken : String Index 24 Read FnextPageToken Write SetnextPageToken;
  137. end;
  138. TAccountsClass = Class of TAccounts;
  139. { --------------------------------------------------------------------
  140. TAdClient
  141. --------------------------------------------------------------------}
  142. TAdClient = Class(TGoogleBaseObject)
  143. Private
  144. FarcOptIn : boolean;
  145. Fid : String;
  146. Fkind : String;
  147. FproductCode : String;
  148. FsupportsReporting : boolean;
  149. Protected
  150. //Property setters
  151. Procedure SetarcOptIn(AIndex : Integer; const AValue : boolean); virtual;
  152. Procedure Setid(AIndex : Integer; const AValue : String); virtual;
  153. Procedure Setkind(AIndex : Integer; const AValue : String); virtual;
  154. Procedure SetproductCode(AIndex : Integer; const AValue : String); virtual;
  155. Procedure SetsupportsReporting(AIndex : Integer; const AValue : boolean); virtual;
  156. Public
  157. Published
  158. Property arcOptIn : boolean Index 0 Read FarcOptIn Write SetarcOptIn;
  159. Property id : String Index 8 Read Fid Write Setid;
  160. Property kind : String Index 16 Read Fkind Write Setkind;
  161. Property productCode : String Index 24 Read FproductCode Write SetproductCode;
  162. Property supportsReporting : boolean Index 32 Read FsupportsReporting Write SetsupportsReporting;
  163. end;
  164. TAdClientClass = Class of TAdClient;
  165. { --------------------------------------------------------------------
  166. TAdClients
  167. --------------------------------------------------------------------}
  168. TAdClients = Class(TGoogleBaseObject)
  169. Private
  170. Fetag : String;
  171. Fitems : TAdClientsTypeitemsArray;
  172. Fkind : String;
  173. FnextPageToken : String;
  174. Protected
  175. //Property setters
  176. Procedure Setetag(AIndex : Integer; const AValue : String); virtual;
  177. Procedure Setitems(AIndex : Integer; const AValue : TAdClientsTypeitemsArray); virtual;
  178. Procedure Setkind(AIndex : Integer; const AValue : String); virtual;
  179. Procedure SetnextPageToken(AIndex : Integer; const AValue : String); virtual;
  180. //2.6.4. bug workaround
  181. {$IFDEF VER2_6}
  182. Procedure SetArrayLength(Const AName : String; ALength : Longint); override;
  183. {$ENDIF VER2_6}
  184. Public
  185. Published
  186. Property etag : String Index 0 Read Fetag Write Setetag;
  187. Property items : TAdClientsTypeitemsArray Index 8 Read Fitems Write Setitems;
  188. Property kind : String Index 16 Read Fkind Write Setkind;
  189. Property nextPageToken : String Index 24 Read FnextPageToken Write SetnextPageToken;
  190. end;
  191. TAdClientsClass = Class of TAdClients;
  192. { --------------------------------------------------------------------
  193. TAdCode
  194. --------------------------------------------------------------------}
  195. TAdCode = Class(TGoogleBaseObject)
  196. Private
  197. FadCode : String;
  198. Fkind : String;
  199. Protected
  200. //Property setters
  201. Procedure SetadCode(AIndex : Integer; const AValue : String); virtual;
  202. Procedure Setkind(AIndex : Integer; const AValue : String); virtual;
  203. Public
  204. Published
  205. Property adCode : String Index 0 Read FadCode Write SetadCode;
  206. Property kind : String Index 8 Read Fkind Write Setkind;
  207. end;
  208. TAdCodeClass = Class of TAdCode;
  209. { --------------------------------------------------------------------
  210. TAdStyleTypecolors
  211. --------------------------------------------------------------------}
  212. TAdStyleTypecolors = Class(TGoogleBaseObject)
  213. Private
  214. Fbackground : String;
  215. Fborder : String;
  216. Ftext : String;
  217. Ftitle : String;
  218. Furl : String;
  219. Protected
  220. //Property setters
  221. Procedure Setbackground(AIndex : Integer; const AValue : String); virtual;
  222. Procedure Setborder(AIndex : Integer; const AValue : String); virtual;
  223. Procedure Settext(AIndex : Integer; const AValue : String); virtual;
  224. Procedure Settitle(AIndex : Integer; const AValue : String); virtual;
  225. Procedure Seturl(AIndex : Integer; const AValue : String); virtual;
  226. Public
  227. Published
  228. Property background : String Index 0 Read Fbackground Write Setbackground;
  229. Property border : String Index 8 Read Fborder Write Setborder;
  230. Property text : String Index 16 Read Ftext Write Settext;
  231. Property title : String Index 24 Read Ftitle Write Settitle;
  232. Property url : String Index 32 Read Furl Write Seturl;
  233. end;
  234. TAdStyleTypecolorsClass = Class of TAdStyleTypecolors;
  235. { --------------------------------------------------------------------
  236. TAdStyleTypefont
  237. --------------------------------------------------------------------}
  238. TAdStyleTypefont = Class(TGoogleBaseObject)
  239. Private
  240. Ffamily : String;
  241. Fsize : String;
  242. Protected
  243. //Property setters
  244. Procedure Setfamily(AIndex : Integer; const AValue : String); virtual;
  245. Procedure Setsize(AIndex : Integer; const AValue : String); virtual;
  246. Public
  247. Published
  248. Property family : String Index 0 Read Ffamily Write Setfamily;
  249. Property size : String Index 8 Read Fsize Write Setsize;
  250. end;
  251. TAdStyleTypefontClass = Class of TAdStyleTypefont;
  252. { --------------------------------------------------------------------
  253. TAdStyle
  254. --------------------------------------------------------------------}
  255. TAdStyle = Class(TGoogleBaseObject)
  256. Private
  257. Fcolors : TAdStyleTypecolors;
  258. Fcorners : String;
  259. Ffont : TAdStyleTypefont;
  260. Fkind : String;
  261. Protected
  262. //Property setters
  263. Procedure Setcolors(AIndex : Integer; const AValue : TAdStyleTypecolors); virtual;
  264. Procedure Setcorners(AIndex : Integer; const AValue : String); virtual;
  265. Procedure Setfont(AIndex : Integer; const AValue : TAdStyleTypefont); virtual;
  266. Procedure Setkind(AIndex : Integer; const AValue : String); virtual;
  267. Public
  268. Published
  269. Property colors : TAdStyleTypecolors Index 0 Read Fcolors Write Setcolors;
  270. Property corners : String Index 8 Read Fcorners Write Setcorners;
  271. Property font : TAdStyleTypefont Index 16 Read Ffont Write Setfont;
  272. Property kind : String Index 24 Read Fkind Write Setkind;
  273. end;
  274. TAdStyleClass = Class of TAdStyle;
  275. { --------------------------------------------------------------------
  276. TAdUnitTypecontentAdsSettingsTypebackupOption
  277. --------------------------------------------------------------------}
  278. TAdUnitTypecontentAdsSettingsTypebackupOption = Class(TGoogleBaseObject)
  279. Private
  280. Fcolor : String;
  281. F_type : String;
  282. Furl : String;
  283. Protected
  284. Class Function ExportPropertyName(Const AName : String) : string; override;
  285. //Property setters
  286. Procedure Setcolor(AIndex : Integer; const AValue : String); virtual;
  287. Procedure Set_type(AIndex : Integer; const AValue : String); virtual;
  288. Procedure Seturl(AIndex : Integer; const AValue : String); virtual;
  289. Public
  290. Published
  291. Property color : String Index 0 Read Fcolor Write Setcolor;
  292. Property _type : String Index 8 Read F_type Write Set_type;
  293. Property url : String Index 16 Read Furl Write Seturl;
  294. end;
  295. TAdUnitTypecontentAdsSettingsTypebackupOptionClass = Class of TAdUnitTypecontentAdsSettingsTypebackupOption;
  296. { --------------------------------------------------------------------
  297. TAdUnitTypecontentAdsSettings
  298. --------------------------------------------------------------------}
  299. TAdUnitTypecontentAdsSettings = Class(TGoogleBaseObject)
  300. Private
  301. FbackupOption : TAdUnitTypecontentAdsSettingsTypebackupOption;
  302. Fsize : String;
  303. F_type : String;
  304. Protected
  305. Class Function ExportPropertyName(Const AName : String) : string; override;
  306. //Property setters
  307. Procedure SetbackupOption(AIndex : Integer; const AValue : TAdUnitTypecontentAdsSettingsTypebackupOption); virtual;
  308. Procedure Setsize(AIndex : Integer; const AValue : String); virtual;
  309. Procedure Set_type(AIndex : Integer; const AValue : String); virtual;
  310. Public
  311. Published
  312. Property backupOption : TAdUnitTypecontentAdsSettingsTypebackupOption Index 0 Read FbackupOption Write SetbackupOption;
  313. Property size : String Index 8 Read Fsize Write Setsize;
  314. Property _type : String Index 16 Read F_type Write Set_type;
  315. end;
  316. TAdUnitTypecontentAdsSettingsClass = Class of TAdUnitTypecontentAdsSettings;
  317. { --------------------------------------------------------------------
  318. TAdUnitTypefeedAdsSettings
  319. --------------------------------------------------------------------}
  320. TAdUnitTypefeedAdsSettings = Class(TGoogleBaseObject)
  321. Private
  322. FadPosition : String;
  323. Ffrequency : integer;
  324. FminimumWordCount : integer;
  325. F_type : String;
  326. Protected
  327. Class Function ExportPropertyName(Const AName : String) : string; override;
  328. //Property setters
  329. Procedure SetadPosition(AIndex : Integer; const AValue : String); virtual;
  330. Procedure Setfrequency(AIndex : Integer; const AValue : integer); virtual;
  331. Procedure SetminimumWordCount(AIndex : Integer; const AValue : integer); virtual;
  332. Procedure Set_type(AIndex : Integer; const AValue : String); virtual;
  333. Public
  334. Published
  335. Property adPosition : String Index 0 Read FadPosition Write SetadPosition;
  336. Property frequency : integer Index 8 Read Ffrequency Write Setfrequency;
  337. Property minimumWordCount : integer Index 16 Read FminimumWordCount Write SetminimumWordCount;
  338. Property _type : String Index 24 Read F_type Write Set_type;
  339. end;
  340. TAdUnitTypefeedAdsSettingsClass = Class of TAdUnitTypefeedAdsSettings;
  341. { --------------------------------------------------------------------
  342. TAdUnitTypemobileContentAdsSettings
  343. --------------------------------------------------------------------}
  344. TAdUnitTypemobileContentAdsSettings = Class(TGoogleBaseObject)
  345. Private
  346. FmarkupLanguage : String;
  347. FscriptingLanguage : String;
  348. Fsize : String;
  349. F_type : String;
  350. Protected
  351. Class Function ExportPropertyName(Const AName : String) : string; override;
  352. //Property setters
  353. Procedure SetmarkupLanguage(AIndex : Integer; const AValue : String); virtual;
  354. Procedure SetscriptingLanguage(AIndex : Integer; const AValue : String); virtual;
  355. Procedure Setsize(AIndex : Integer; const AValue : String); virtual;
  356. Procedure Set_type(AIndex : Integer; const AValue : String); virtual;
  357. Public
  358. Published
  359. Property markupLanguage : String Index 0 Read FmarkupLanguage Write SetmarkupLanguage;
  360. Property scriptingLanguage : String Index 8 Read FscriptingLanguage Write SetscriptingLanguage;
  361. Property size : String Index 16 Read Fsize Write Setsize;
  362. Property _type : String Index 24 Read F_type Write Set_type;
  363. end;
  364. TAdUnitTypemobileContentAdsSettingsClass = Class of TAdUnitTypemobileContentAdsSettings;
  365. { --------------------------------------------------------------------
  366. TAdUnit
  367. --------------------------------------------------------------------}
  368. TAdUnit = Class(TGoogleBaseObject)
  369. Private
  370. Fcode : String;
  371. FcontentAdsSettings : TAdUnitTypecontentAdsSettings;
  372. FcustomStyle : TAdStyle;
  373. FfeedAdsSettings : TAdUnitTypefeedAdsSettings;
  374. Fid : String;
  375. Fkind : String;
  376. FmobileContentAdsSettings : TAdUnitTypemobileContentAdsSettings;
  377. Fname : String;
  378. FsavedStyleId : String;
  379. Fstatus : String;
  380. Protected
  381. //Property setters
  382. Procedure Setcode(AIndex : Integer; const AValue : String); virtual;
  383. Procedure SetcontentAdsSettings(AIndex : Integer; const AValue : TAdUnitTypecontentAdsSettings); virtual;
  384. Procedure SetcustomStyle(AIndex : Integer; const AValue : TAdStyle); virtual;
  385. Procedure SetfeedAdsSettings(AIndex : Integer; const AValue : TAdUnitTypefeedAdsSettings); virtual;
  386. Procedure Setid(AIndex : Integer; const AValue : String); virtual;
  387. Procedure Setkind(AIndex : Integer; const AValue : String); virtual;
  388. Procedure SetmobileContentAdsSettings(AIndex : Integer; const AValue : TAdUnitTypemobileContentAdsSettings); virtual;
  389. Procedure Setname(AIndex : Integer; const AValue : String); virtual;
  390. Procedure SetsavedStyleId(AIndex : Integer; const AValue : String); virtual;
  391. Procedure Setstatus(AIndex : Integer; const AValue : String); virtual;
  392. Public
  393. Published
  394. Property code : String Index 0 Read Fcode Write Setcode;
  395. Property contentAdsSettings : TAdUnitTypecontentAdsSettings Index 8 Read FcontentAdsSettings Write SetcontentAdsSettings;
  396. Property customStyle : TAdStyle Index 16 Read FcustomStyle Write SetcustomStyle;
  397. Property feedAdsSettings : TAdUnitTypefeedAdsSettings Index 24 Read FfeedAdsSettings Write SetfeedAdsSettings;
  398. Property id : String Index 32 Read Fid Write Setid;
  399. Property kind : String Index 40 Read Fkind Write Setkind;
  400. Property mobileContentAdsSettings : TAdUnitTypemobileContentAdsSettings Index 48 Read FmobileContentAdsSettings Write SetmobileContentAdsSettings;
  401. Property name : String Index 56 Read Fname Write Setname;
  402. Property savedStyleId : String Index 64 Read FsavedStyleId Write SetsavedStyleId;
  403. Property status : String Index 72 Read Fstatus Write Setstatus;
  404. end;
  405. TAdUnitClass = Class of TAdUnit;
  406. { --------------------------------------------------------------------
  407. TAdUnits
  408. --------------------------------------------------------------------}
  409. TAdUnits = Class(TGoogleBaseObject)
  410. Private
  411. Fetag : String;
  412. Fitems : TAdUnitsTypeitemsArray;
  413. Fkind : String;
  414. FnextPageToken : String;
  415. Protected
  416. //Property setters
  417. Procedure Setetag(AIndex : Integer; const AValue : String); virtual;
  418. Procedure Setitems(AIndex : Integer; const AValue : TAdUnitsTypeitemsArray); virtual;
  419. Procedure Setkind(AIndex : Integer; const AValue : String); virtual;
  420. Procedure SetnextPageToken(AIndex : Integer; const AValue : String); virtual;
  421. //2.6.4. bug workaround
  422. {$IFDEF VER2_6}
  423. Procedure SetArrayLength(Const AName : String; ALength : Longint); override;
  424. {$ENDIF VER2_6}
  425. Public
  426. Published
  427. Property etag : String Index 0 Read Fetag Write Setetag;
  428. Property items : TAdUnitsTypeitemsArray Index 8 Read Fitems Write Setitems;
  429. Property kind : String Index 16 Read Fkind Write Setkind;
  430. Property nextPageToken : String Index 24 Read FnextPageToken Write SetnextPageToken;
  431. end;
  432. TAdUnitsClass = Class of TAdUnits;
  433. { --------------------------------------------------------------------
  434. TAdsenseReportsGenerateResponseTypeheadersItem
  435. --------------------------------------------------------------------}
  436. TAdsenseReportsGenerateResponseTypeheadersItem = Class(TGoogleBaseObject)
  437. Private
  438. Fcurrency : String;
  439. Fname : String;
  440. F_type : String;
  441. Protected
  442. Class Function ExportPropertyName(Const AName : String) : string; override;
  443. //Property setters
  444. Procedure Setcurrency(AIndex : Integer; const AValue : String); virtual;
  445. Procedure Setname(AIndex : Integer; const AValue : String); virtual;
  446. Procedure Set_type(AIndex : Integer; const AValue : String); virtual;
  447. Public
  448. Published
  449. Property currency : String Index 0 Read Fcurrency Write Setcurrency;
  450. Property name : String Index 8 Read Fname Write Setname;
  451. Property _type : String Index 16 Read F_type Write Set_type;
  452. end;
  453. TAdsenseReportsGenerateResponseTypeheadersItemClass = Class of TAdsenseReportsGenerateResponseTypeheadersItem;
  454. { --------------------------------------------------------------------
  455. TAdsenseReportsGenerateResponse
  456. --------------------------------------------------------------------}
  457. TAdsenseReportsGenerateResponse = Class(TGoogleBaseObject)
  458. Private
  459. Faverages : TStringArray;
  460. FendDate : String;
  461. Fheaders : TAdsenseReportsGenerateResponseTypeheadersArray;
  462. Fkind : String;
  463. Frows : TAdsenseReportsGenerateResponseTyperowsArray;
  464. FstartDate : String;
  465. FtotalMatchedRows : String;
  466. Ftotals : TStringArray;
  467. Fwarnings : TStringArray;
  468. Protected
  469. //Property setters
  470. Procedure Setaverages(AIndex : Integer; const AValue : TStringArray); virtual;
  471. Procedure SetendDate(AIndex : Integer; const AValue : String); virtual;
  472. Procedure Setheaders(AIndex : Integer; const AValue : TAdsenseReportsGenerateResponseTypeheadersArray); virtual;
  473. Procedure Setkind(AIndex : Integer; const AValue : String); virtual;
  474. Procedure Setrows(AIndex : Integer; const AValue : TAdsenseReportsGenerateResponseTyperowsArray); virtual;
  475. Procedure SetstartDate(AIndex : Integer; const AValue : String); virtual;
  476. Procedure SettotalMatchedRows(AIndex : Integer; const AValue : String); virtual;
  477. Procedure Settotals(AIndex : Integer; const AValue : TStringArray); virtual;
  478. Procedure Setwarnings(AIndex : Integer; const AValue : TStringArray); virtual;
  479. //2.6.4. bug workaround
  480. {$IFDEF VER2_6}
  481. Procedure SetArrayLength(Const AName : String; ALength : Longint); override;
  482. {$ENDIF VER2_6}
  483. Public
  484. Published
  485. Property averages : TStringArray Index 0 Read Faverages Write Setaverages;
  486. Property endDate : String Index 8 Read FendDate Write SetendDate;
  487. Property headers : TAdsenseReportsGenerateResponseTypeheadersArray Index 16 Read Fheaders Write Setheaders;
  488. Property kind : String Index 24 Read Fkind Write Setkind;
  489. Property rows : TAdsenseReportsGenerateResponseTyperowsArray Index 32 Read Frows Write Setrows;
  490. Property startDate : String Index 40 Read FstartDate Write SetstartDate;
  491. Property totalMatchedRows : String Index 48 Read FtotalMatchedRows Write SettotalMatchedRows;
  492. Property totals : TStringArray Index 56 Read Ftotals Write Settotals;
  493. Property warnings : TStringArray Index 64 Read Fwarnings Write Setwarnings;
  494. end;
  495. TAdsenseReportsGenerateResponseClass = Class of TAdsenseReportsGenerateResponse;
  496. { --------------------------------------------------------------------
  497. TAlert
  498. --------------------------------------------------------------------}
  499. TAlert = Class(TGoogleBaseObject)
  500. Private
  501. Fid : String;
  502. FisDismissible : boolean;
  503. Fkind : String;
  504. Fmessage : String;
  505. Fseverity : String;
  506. F_type : String;
  507. Protected
  508. Class Function ExportPropertyName(Const AName : String) : string; override;
  509. //Property setters
  510. Procedure Setid(AIndex : Integer; const AValue : String); virtual;
  511. Procedure SetisDismissible(AIndex : Integer; const AValue : boolean); virtual;
  512. Procedure Setkind(AIndex : Integer; const AValue : String); virtual;
  513. Procedure Setmessage(AIndex : Integer; const AValue : String); virtual;
  514. Procedure Setseverity(AIndex : Integer; const AValue : String); virtual;
  515. Procedure Set_type(AIndex : Integer; const AValue : String); virtual;
  516. Public
  517. Published
  518. Property id : String Index 0 Read Fid Write Setid;
  519. Property isDismissible : boolean Index 8 Read FisDismissible Write SetisDismissible;
  520. Property kind : String Index 16 Read Fkind Write Setkind;
  521. Property message : String Index 24 Read Fmessage Write Setmessage;
  522. Property severity : String Index 32 Read Fseverity Write Setseverity;
  523. Property _type : String Index 40 Read F_type Write Set_type;
  524. end;
  525. TAlertClass = Class of TAlert;
  526. { --------------------------------------------------------------------
  527. TAlerts
  528. --------------------------------------------------------------------}
  529. TAlerts = Class(TGoogleBaseObject)
  530. Private
  531. Fitems : TAlertsTypeitemsArray;
  532. Fkind : String;
  533. Protected
  534. //Property setters
  535. Procedure Setitems(AIndex : Integer; const AValue : TAlertsTypeitemsArray); virtual;
  536. Procedure Setkind(AIndex : Integer; const AValue : String); virtual;
  537. //2.6.4. bug workaround
  538. {$IFDEF VER2_6}
  539. Procedure SetArrayLength(Const AName : String; ALength : Longint); override;
  540. {$ENDIF VER2_6}
  541. Public
  542. Published
  543. Property items : TAlertsTypeitemsArray Index 0 Read Fitems Write Setitems;
  544. Property kind : String Index 8 Read Fkind Write Setkind;
  545. end;
  546. TAlertsClass = Class of TAlerts;
  547. { --------------------------------------------------------------------
  548. TCustomChannelTypetargetingInfo
  549. --------------------------------------------------------------------}
  550. TCustomChannelTypetargetingInfo = Class(TGoogleBaseObject)
  551. Private
  552. FadsAppearOn : String;
  553. Fdescription : String;
  554. Flocation : String;
  555. FsiteLanguage : String;
  556. Protected
  557. //Property setters
  558. Procedure SetadsAppearOn(AIndex : Integer; const AValue : String); virtual;
  559. Procedure Setdescription(AIndex : Integer; const AValue : String); virtual;
  560. Procedure Setlocation(AIndex : Integer; const AValue : String); virtual;
  561. Procedure SetsiteLanguage(AIndex : Integer; const AValue : String); virtual;
  562. Public
  563. Published
  564. Property adsAppearOn : String Index 0 Read FadsAppearOn Write SetadsAppearOn;
  565. Property description : String Index 8 Read Fdescription Write Setdescription;
  566. Property location : String Index 16 Read Flocation Write Setlocation;
  567. Property siteLanguage : String Index 24 Read FsiteLanguage Write SetsiteLanguage;
  568. end;
  569. TCustomChannelTypetargetingInfoClass = Class of TCustomChannelTypetargetingInfo;
  570. { --------------------------------------------------------------------
  571. TCustomChannel
  572. --------------------------------------------------------------------}
  573. TCustomChannel = Class(TGoogleBaseObject)
  574. Private
  575. Fcode : String;
  576. Fid : String;
  577. Fkind : String;
  578. Fname : String;
  579. FtargetingInfo : TCustomChannelTypetargetingInfo;
  580. Protected
  581. //Property setters
  582. Procedure Setcode(AIndex : Integer; const AValue : String); virtual;
  583. Procedure Setid(AIndex : Integer; const AValue : String); virtual;
  584. Procedure Setkind(AIndex : Integer; const AValue : String); virtual;
  585. Procedure Setname(AIndex : Integer; const AValue : String); virtual;
  586. Procedure SettargetingInfo(AIndex : Integer; const AValue : TCustomChannelTypetargetingInfo); virtual;
  587. Public
  588. Published
  589. Property code : String Index 0 Read Fcode Write Setcode;
  590. Property id : String Index 8 Read Fid Write Setid;
  591. Property kind : String Index 16 Read Fkind Write Setkind;
  592. Property name : String Index 24 Read Fname Write Setname;
  593. Property targetingInfo : TCustomChannelTypetargetingInfo Index 32 Read FtargetingInfo Write SettargetingInfo;
  594. end;
  595. TCustomChannelClass = Class of TCustomChannel;
  596. { --------------------------------------------------------------------
  597. TCustomChannels
  598. --------------------------------------------------------------------}
  599. TCustomChannels = Class(TGoogleBaseObject)
  600. Private
  601. Fetag : String;
  602. Fitems : TCustomChannelsTypeitemsArray;
  603. Fkind : String;
  604. FnextPageToken : String;
  605. Protected
  606. //Property setters
  607. Procedure Setetag(AIndex : Integer; const AValue : String); virtual;
  608. Procedure Setitems(AIndex : Integer; const AValue : TCustomChannelsTypeitemsArray); virtual;
  609. Procedure Setkind(AIndex : Integer; const AValue : String); virtual;
  610. Procedure SetnextPageToken(AIndex : Integer; const AValue : String); virtual;
  611. //2.6.4. bug workaround
  612. {$IFDEF VER2_6}
  613. Procedure SetArrayLength(Const AName : String; ALength : Longint); override;
  614. {$ENDIF VER2_6}
  615. Public
  616. Published
  617. Property etag : String Index 0 Read Fetag Write Setetag;
  618. Property items : TCustomChannelsTypeitemsArray Index 8 Read Fitems Write Setitems;
  619. Property kind : String Index 16 Read Fkind Write Setkind;
  620. Property nextPageToken : String Index 24 Read FnextPageToken Write SetnextPageToken;
  621. end;
  622. TCustomChannelsClass = Class of TCustomChannels;
  623. { --------------------------------------------------------------------
  624. TMetadata
  625. --------------------------------------------------------------------}
  626. TMetadata = Class(TGoogleBaseObject)
  627. Private
  628. Fitems : TMetadataTypeitemsArray;
  629. Fkind : String;
  630. Protected
  631. //Property setters
  632. Procedure Setitems(AIndex : Integer; const AValue : TMetadataTypeitemsArray); virtual;
  633. Procedure Setkind(AIndex : Integer; const AValue : String); virtual;
  634. //2.6.4. bug workaround
  635. {$IFDEF VER2_6}
  636. Procedure SetArrayLength(Const AName : String; ALength : Longint); override;
  637. {$ENDIF VER2_6}
  638. Public
  639. Published
  640. Property items : TMetadataTypeitemsArray Index 0 Read Fitems Write Setitems;
  641. Property kind : String Index 8 Read Fkind Write Setkind;
  642. end;
  643. TMetadataClass = Class of TMetadata;
  644. { --------------------------------------------------------------------
  645. TPayment
  646. --------------------------------------------------------------------}
  647. TPayment = Class(TGoogleBaseObject)
  648. Private
  649. Fid : String;
  650. Fkind : String;
  651. FpaymentAmount : String;
  652. FpaymentAmountCurrencyCode : String;
  653. FpaymentDate : String;
  654. Protected
  655. //Property setters
  656. Procedure Setid(AIndex : Integer; const AValue : String); virtual;
  657. Procedure Setkind(AIndex : Integer; const AValue : String); virtual;
  658. Procedure SetpaymentAmount(AIndex : Integer; const AValue : String); virtual;
  659. Procedure SetpaymentAmountCurrencyCode(AIndex : Integer; const AValue : String); virtual;
  660. Procedure SetpaymentDate(AIndex : Integer; const AValue : String); virtual;
  661. Public
  662. Published
  663. Property id : String Index 0 Read Fid Write Setid;
  664. Property kind : String Index 8 Read Fkind Write Setkind;
  665. Property paymentAmount : String Index 16 Read FpaymentAmount Write SetpaymentAmount;
  666. Property paymentAmountCurrencyCode : String Index 24 Read FpaymentAmountCurrencyCode Write SetpaymentAmountCurrencyCode;
  667. Property paymentDate : String Index 32 Read FpaymentDate Write SetpaymentDate;
  668. end;
  669. TPaymentClass = Class of TPayment;
  670. { --------------------------------------------------------------------
  671. TPayments
  672. --------------------------------------------------------------------}
  673. TPayments = Class(TGoogleBaseObject)
  674. Private
  675. Fitems : TPaymentsTypeitemsArray;
  676. Fkind : String;
  677. Protected
  678. //Property setters
  679. Procedure Setitems(AIndex : Integer; const AValue : TPaymentsTypeitemsArray); virtual;
  680. Procedure Setkind(AIndex : Integer; const AValue : String); virtual;
  681. //2.6.4. bug workaround
  682. {$IFDEF VER2_6}
  683. Procedure SetArrayLength(Const AName : String; ALength : Longint); override;
  684. {$ENDIF VER2_6}
  685. Public
  686. Published
  687. Property items : TPaymentsTypeitemsArray Index 0 Read Fitems Write Setitems;
  688. Property kind : String Index 8 Read Fkind Write Setkind;
  689. end;
  690. TPaymentsClass = Class of TPayments;
  691. { --------------------------------------------------------------------
  692. TReportingMetadataEntry
  693. --------------------------------------------------------------------}
  694. TReportingMetadataEntry = Class(TGoogleBaseObject)
  695. Private
  696. FcompatibleDimensions : TStringArray;
  697. FcompatibleMetrics : TStringArray;
  698. Fid : String;
  699. Fkind : String;
  700. FrequiredDimensions : TStringArray;
  701. FrequiredMetrics : TStringArray;
  702. FsupportedProducts : TStringArray;
  703. Protected
  704. //Property setters
  705. Procedure SetcompatibleDimensions(AIndex : Integer; const AValue : TStringArray); virtual;
  706. Procedure SetcompatibleMetrics(AIndex : Integer; const AValue : TStringArray); virtual;
  707. Procedure Setid(AIndex : Integer; const AValue : String); virtual;
  708. Procedure Setkind(AIndex : Integer; const AValue : String); virtual;
  709. Procedure SetrequiredDimensions(AIndex : Integer; const AValue : TStringArray); virtual;
  710. Procedure SetrequiredMetrics(AIndex : Integer; const AValue : TStringArray); virtual;
  711. Procedure SetsupportedProducts(AIndex : Integer; const AValue : TStringArray); virtual;
  712. //2.6.4. bug workaround
  713. {$IFDEF VER2_6}
  714. Procedure SetArrayLength(Const AName : String; ALength : Longint); override;
  715. {$ENDIF VER2_6}
  716. Public
  717. Published
  718. Property compatibleDimensions : TStringArray Index 0 Read FcompatibleDimensions Write SetcompatibleDimensions;
  719. Property compatibleMetrics : TStringArray Index 8 Read FcompatibleMetrics Write SetcompatibleMetrics;
  720. Property id : String Index 16 Read Fid Write Setid;
  721. Property kind : String Index 24 Read Fkind Write Setkind;
  722. Property requiredDimensions : TStringArray Index 32 Read FrequiredDimensions Write SetrequiredDimensions;
  723. Property requiredMetrics : TStringArray Index 40 Read FrequiredMetrics Write SetrequiredMetrics;
  724. Property supportedProducts : TStringArray Index 48 Read FsupportedProducts Write SetsupportedProducts;
  725. end;
  726. TReportingMetadataEntryClass = Class of TReportingMetadataEntry;
  727. { --------------------------------------------------------------------
  728. TSavedAdStyle
  729. --------------------------------------------------------------------}
  730. TSavedAdStyle = Class(TGoogleBaseObject)
  731. Private
  732. FadStyle : TAdStyle;
  733. Fid : String;
  734. Fkind : String;
  735. Fname : String;
  736. Protected
  737. //Property setters
  738. Procedure SetadStyle(AIndex : Integer; const AValue : TAdStyle); virtual;
  739. Procedure Setid(AIndex : Integer; const AValue : String); virtual;
  740. Procedure Setkind(AIndex : Integer; const AValue : String); virtual;
  741. Procedure Setname(AIndex : Integer; const AValue : String); virtual;
  742. Public
  743. Published
  744. Property adStyle : TAdStyle Index 0 Read FadStyle Write SetadStyle;
  745. Property id : String Index 8 Read Fid Write Setid;
  746. Property kind : String Index 16 Read Fkind Write Setkind;
  747. Property name : String Index 24 Read Fname Write Setname;
  748. end;
  749. TSavedAdStyleClass = Class of TSavedAdStyle;
  750. { --------------------------------------------------------------------
  751. TSavedAdStyles
  752. --------------------------------------------------------------------}
  753. TSavedAdStyles = Class(TGoogleBaseObject)
  754. Private
  755. Fetag : String;
  756. Fitems : TSavedAdStylesTypeitemsArray;
  757. Fkind : String;
  758. FnextPageToken : String;
  759. Protected
  760. //Property setters
  761. Procedure Setetag(AIndex : Integer; const AValue : String); virtual;
  762. Procedure Setitems(AIndex : Integer; const AValue : TSavedAdStylesTypeitemsArray); virtual;
  763. Procedure Setkind(AIndex : Integer; const AValue : String); virtual;
  764. Procedure SetnextPageToken(AIndex : Integer; const AValue : String); virtual;
  765. //2.6.4. bug workaround
  766. {$IFDEF VER2_6}
  767. Procedure SetArrayLength(Const AName : String; ALength : Longint); override;
  768. {$ENDIF VER2_6}
  769. Public
  770. Published
  771. Property etag : String Index 0 Read Fetag Write Setetag;
  772. Property items : TSavedAdStylesTypeitemsArray Index 8 Read Fitems Write Setitems;
  773. Property kind : String Index 16 Read Fkind Write Setkind;
  774. Property nextPageToken : String Index 24 Read FnextPageToken Write SetnextPageToken;
  775. end;
  776. TSavedAdStylesClass = Class of TSavedAdStyles;
  777. { --------------------------------------------------------------------
  778. TSavedReport
  779. --------------------------------------------------------------------}
  780. TSavedReport = Class(TGoogleBaseObject)
  781. Private
  782. Fid : String;
  783. Fkind : String;
  784. Fname : String;
  785. Protected
  786. //Property setters
  787. Procedure Setid(AIndex : Integer; const AValue : String); virtual;
  788. Procedure Setkind(AIndex : Integer; const AValue : String); virtual;
  789. Procedure Setname(AIndex : Integer; const AValue : String); virtual;
  790. Public
  791. Published
  792. Property id : String Index 0 Read Fid Write Setid;
  793. Property kind : String Index 8 Read Fkind Write Setkind;
  794. Property name : String Index 16 Read Fname Write Setname;
  795. end;
  796. TSavedReportClass = Class of TSavedReport;
  797. { --------------------------------------------------------------------
  798. TSavedReports
  799. --------------------------------------------------------------------}
  800. TSavedReports = Class(TGoogleBaseObject)
  801. Private
  802. Fetag : String;
  803. Fitems : TSavedReportsTypeitemsArray;
  804. Fkind : String;
  805. FnextPageToken : String;
  806. Protected
  807. //Property setters
  808. Procedure Setetag(AIndex : Integer; const AValue : String); virtual;
  809. Procedure Setitems(AIndex : Integer; const AValue : TSavedReportsTypeitemsArray); virtual;
  810. Procedure Setkind(AIndex : Integer; const AValue : String); virtual;
  811. Procedure SetnextPageToken(AIndex : Integer; const AValue : String); virtual;
  812. //2.6.4. bug workaround
  813. {$IFDEF VER2_6}
  814. Procedure SetArrayLength(Const AName : String; ALength : Longint); override;
  815. {$ENDIF VER2_6}
  816. Public
  817. Published
  818. Property etag : String Index 0 Read Fetag Write Setetag;
  819. Property items : TSavedReportsTypeitemsArray Index 8 Read Fitems Write Setitems;
  820. Property kind : String Index 16 Read Fkind Write Setkind;
  821. Property nextPageToken : String Index 24 Read FnextPageToken Write SetnextPageToken;
  822. end;
  823. TSavedReportsClass = Class of TSavedReports;
  824. { --------------------------------------------------------------------
  825. TUrlChannel
  826. --------------------------------------------------------------------}
  827. TUrlChannel = Class(TGoogleBaseObject)
  828. Private
  829. Fid : String;
  830. Fkind : String;
  831. FurlPattern : String;
  832. Protected
  833. //Property setters
  834. Procedure Setid(AIndex : Integer; const AValue : String); virtual;
  835. Procedure Setkind(AIndex : Integer; const AValue : String); virtual;
  836. Procedure SeturlPattern(AIndex : Integer; const AValue : String); virtual;
  837. Public
  838. Published
  839. Property id : String Index 0 Read Fid Write Setid;
  840. Property kind : String Index 8 Read Fkind Write Setkind;
  841. Property urlPattern : String Index 16 Read FurlPattern Write SeturlPattern;
  842. end;
  843. TUrlChannelClass = Class of TUrlChannel;
  844. { --------------------------------------------------------------------
  845. TUrlChannels
  846. --------------------------------------------------------------------}
  847. TUrlChannels = Class(TGoogleBaseObject)
  848. Private
  849. Fetag : String;
  850. Fitems : TUrlChannelsTypeitemsArray;
  851. Fkind : String;
  852. FnextPageToken : String;
  853. Protected
  854. //Property setters
  855. Procedure Setetag(AIndex : Integer; const AValue : String); virtual;
  856. Procedure Setitems(AIndex : Integer; const AValue : TUrlChannelsTypeitemsArray); virtual;
  857. Procedure Setkind(AIndex : Integer; const AValue : String); virtual;
  858. Procedure SetnextPageToken(AIndex : Integer; const AValue : String); virtual;
  859. //2.6.4. bug workaround
  860. {$IFDEF VER2_6}
  861. Procedure SetArrayLength(Const AName : String; ALength : Longint); override;
  862. {$ENDIF VER2_6}
  863. Public
  864. Published
  865. Property etag : String Index 0 Read Fetag Write Setetag;
  866. Property items : TUrlChannelsTypeitemsArray Index 8 Read Fitems Write Setitems;
  867. Property kind : String Index 16 Read Fkind Write Setkind;
  868. Property nextPageToken : String Index 24 Read FnextPageToken Write SetnextPageToken;
  869. end;
  870. TUrlChannelsClass = Class of TUrlChannels;
  871. { --------------------------------------------------------------------
  872. TAccountsAdclientsResource
  873. --------------------------------------------------------------------}
  874. //Optional query Options for TAccountsAdclientsResource, method List
  875. TAccountsAdclientsListOptions = Record
  876. maxResults : integer;
  877. pageToken : String;
  878. end;
  879. TAccountsAdclientsResource = Class(TGoogleResource)
  880. Public
  881. Class Function ResourceName : String; override;
  882. Class Function DefaultAPI : TGoogleAPIClass; override;
  883. Function List(accountId: string; AQuery : string = '') : TAdClients;
  884. Function List(accountId: string; AQuery : TAccountsAdclientslistOptions) : TAdClients;
  885. end;
  886. { --------------------------------------------------------------------
  887. TAccountsAdunitsCustomchannelsResource
  888. --------------------------------------------------------------------}
  889. //Optional query Options for TAccountsAdunitsCustomchannelsResource, method List
  890. TAccountsAdunitsCustomchannelsListOptions = Record
  891. maxResults : integer;
  892. pageToken : String;
  893. end;
  894. TAccountsAdunitsCustomchannelsResource = Class(TGoogleResource)
  895. Public
  896. Class Function ResourceName : String; override;
  897. Class Function DefaultAPI : TGoogleAPIClass; override;
  898. Function List(accountId: string; adClientId: string; adUnitId: string; AQuery : string = '') : TCustomChannels;
  899. Function List(accountId: string; adClientId: string; adUnitId: string; AQuery : TAccountsAdunitsCustomchannelslistOptions) : TCustomChannels;
  900. end;
  901. { --------------------------------------------------------------------
  902. TAccountsAdunitsResource
  903. --------------------------------------------------------------------}
  904. //Optional query Options for TAccountsAdunitsResource, method List
  905. TAccountsAdunitsListOptions = Record
  906. includeInactive : boolean;
  907. maxResults : integer;
  908. pageToken : String;
  909. end;
  910. TAccountsAdunitsResource = Class(TGoogleResource)
  911. Private
  912. FCustomchannelsInstance : TAccountsAdunitsCustomchannelsResource;
  913. Function GetCustomchannelsInstance : TAccountsAdunitsCustomchannelsResource;virtual;
  914. Public
  915. Class Function ResourceName : String; override;
  916. Class Function DefaultAPI : TGoogleAPIClass; override;
  917. Function Get(accountId: string; adClientId: string; adUnitId: string) : TAdUnit;
  918. Function GetAdCode(accountId: string; adClientId: string; adUnitId: string) : TAdCode;
  919. Function List(accountId: string; adClientId: string; AQuery : string = '') : TAdUnits;
  920. Function List(accountId: string; adClientId: string; AQuery : TAccountsAdunitslistOptions) : TAdUnits;
  921. Function CreateCustomchannelsResource(AOwner : TComponent) : TAccountsAdunitsCustomchannelsResource;virtual;overload;
  922. Function CreateCustomchannelsResource : TAccountsAdunitsCustomchannelsResource;virtual;overload;
  923. Property CustomchannelsResource : TAccountsAdunitsCustomchannelsResource Read GetCustomchannelsInstance;
  924. end;
  925. { --------------------------------------------------------------------
  926. TAccountsAlertsResource
  927. --------------------------------------------------------------------}
  928. //Optional query Options for TAccountsAlertsResource, method List
  929. TAccountsAlertsListOptions = Record
  930. locale : String;
  931. end;
  932. TAccountsAlertsResource = Class(TGoogleResource)
  933. Public
  934. Class Function ResourceName : String; override;
  935. Class Function DefaultAPI : TGoogleAPIClass; override;
  936. Procedure Delete(accountId: string; alertId: string);
  937. Function List(accountId: string; AQuery : string = '') : TAlerts;
  938. Function List(accountId: string; AQuery : TAccountsAlertslistOptions) : TAlerts;
  939. end;
  940. { --------------------------------------------------------------------
  941. TAccountsCustomchannelsAdunitsResource
  942. --------------------------------------------------------------------}
  943. //Optional query Options for TAccountsCustomchannelsAdunitsResource, method List
  944. TAccountsCustomchannelsAdunitsListOptions = Record
  945. includeInactive : boolean;
  946. maxResults : integer;
  947. pageToken : String;
  948. end;
  949. TAccountsCustomchannelsAdunitsResource = Class(TGoogleResource)
  950. Public
  951. Class Function ResourceName : String; override;
  952. Class Function DefaultAPI : TGoogleAPIClass; override;
  953. Function List(accountId: string; adClientId: string; customChannelId: string; AQuery : string = '') : TAdUnits;
  954. Function List(accountId: string; adClientId: string; customChannelId: string; AQuery : TAccountsCustomchannelsAdunitslistOptions) : TAdUnits;
  955. end;
  956. { --------------------------------------------------------------------
  957. TAccountsCustomchannelsResource
  958. --------------------------------------------------------------------}
  959. //Optional query Options for TAccountsCustomchannelsResource, method List
  960. TAccountsCustomchannelsListOptions = Record
  961. maxResults : integer;
  962. pageToken : String;
  963. end;
  964. TAccountsCustomchannelsResource = Class(TGoogleResource)
  965. Private
  966. FAdunitsInstance : TAccountsCustomchannelsAdunitsResource;
  967. Function GetAdunitsInstance : TAccountsCustomchannelsAdunitsResource;virtual;
  968. Public
  969. Class Function ResourceName : String; override;
  970. Class Function DefaultAPI : TGoogleAPIClass; override;
  971. Function Get(accountId: string; adClientId: string; customChannelId: string) : TCustomChannel;
  972. Function List(accountId: string; adClientId: string; AQuery : string = '') : TCustomChannels;
  973. Function List(accountId: string; adClientId: string; AQuery : TAccountsCustomchannelslistOptions) : TCustomChannels;
  974. Function CreateAdunitsResource(AOwner : TComponent) : TAccountsCustomchannelsAdunitsResource;virtual;overload;
  975. Function CreateAdunitsResource : TAccountsCustomchannelsAdunitsResource;virtual;overload;
  976. Property AdunitsResource : TAccountsCustomchannelsAdunitsResource Read GetAdunitsInstance;
  977. end;
  978. { --------------------------------------------------------------------
  979. TAccountsPaymentsResource
  980. --------------------------------------------------------------------}
  981. TAccountsPaymentsResource = Class(TGoogleResource)
  982. Public
  983. Class Function ResourceName : String; override;
  984. Class Function DefaultAPI : TGoogleAPIClass; override;
  985. Function List(accountId: string) : TPayments;
  986. end;
  987. { --------------------------------------------------------------------
  988. TAccountsReportsSavedResource
  989. --------------------------------------------------------------------}
  990. //Optional query Options for TAccountsReportsSavedResource, method Generate
  991. TAccountsReportsSavedGenerateOptions = Record
  992. locale : String;
  993. maxResults : integer;
  994. startIndex : integer;
  995. end;
  996. //Optional query Options for TAccountsReportsSavedResource, method List
  997. TAccountsReportsSavedListOptions = Record
  998. maxResults : integer;
  999. pageToken : String;
  1000. end;
  1001. TAccountsReportsSavedResource = Class(TGoogleResource)
  1002. Public
  1003. Class Function ResourceName : String; override;
  1004. Class Function DefaultAPI : TGoogleAPIClass; override;
  1005. Function Generate(accountId: string; savedReportId: string; AQuery : string = '') : TAdsenseReportsGenerateResponse;
  1006. Function Generate(accountId: string; savedReportId: string; AQuery : TAccountsReportsSavedgenerateOptions) : TAdsenseReportsGenerateResponse;
  1007. Function List(accountId: string; AQuery : string = '') : TSavedReports;
  1008. Function List(accountId: string; AQuery : TAccountsReportsSavedlistOptions) : TSavedReports;
  1009. end;
  1010. { --------------------------------------------------------------------
  1011. TAccountsReportsResource
  1012. --------------------------------------------------------------------}
  1013. //Optional query Options for TAccountsReportsResource, method Generate
  1014. TAccountsReportsGenerateOptions = Record
  1015. currency : String;
  1016. dimension : String;
  1017. endDate : String;
  1018. filter : String;
  1019. locale : String;
  1020. maxResults : integer;
  1021. metric : String;
  1022. sort : String;
  1023. startDate : String;
  1024. startIndex : integer;
  1025. useTimezoneReporting : boolean;
  1026. end;
  1027. TAccountsReportsResource = Class(TGoogleResource)
  1028. Private
  1029. FSavedInstance : TAccountsReportsSavedResource;
  1030. Function GetSavedInstance : TAccountsReportsSavedResource;virtual;
  1031. Public
  1032. Class Function ResourceName : String; override;
  1033. Class Function DefaultAPI : TGoogleAPIClass; override;
  1034. Function Generate(accountId: string; AQuery : string = '') : TAdsenseReportsGenerateResponse;
  1035. Function Generate(accountId: string; AQuery : TAccountsReportsgenerateOptions) : TAdsenseReportsGenerateResponse;
  1036. Function CreateSavedResource(AOwner : TComponent) : TAccountsReportsSavedResource;virtual;overload;
  1037. Function CreateSavedResource : TAccountsReportsSavedResource;virtual;overload;
  1038. Property SavedResource : TAccountsReportsSavedResource Read GetSavedInstance;
  1039. end;
  1040. { --------------------------------------------------------------------
  1041. TAccountsSavedadstylesResource
  1042. --------------------------------------------------------------------}
  1043. //Optional query Options for TAccountsSavedadstylesResource, method List
  1044. TAccountsSavedadstylesListOptions = Record
  1045. maxResults : integer;
  1046. pageToken : String;
  1047. end;
  1048. TAccountsSavedadstylesResource = Class(TGoogleResource)
  1049. Public
  1050. Class Function ResourceName : String; override;
  1051. Class Function DefaultAPI : TGoogleAPIClass; override;
  1052. Function Get(accountId: string; savedAdStyleId: string) : TSavedAdStyle;
  1053. Function List(accountId: string; AQuery : string = '') : TSavedAdStyles;
  1054. Function List(accountId: string; AQuery : TAccountsSavedadstyleslistOptions) : TSavedAdStyles;
  1055. end;
  1056. { --------------------------------------------------------------------
  1057. TAccountsUrlchannelsResource
  1058. --------------------------------------------------------------------}
  1059. //Optional query Options for TAccountsUrlchannelsResource, method List
  1060. TAccountsUrlchannelsListOptions = Record
  1061. maxResults : integer;
  1062. pageToken : String;
  1063. end;
  1064. TAccountsUrlchannelsResource = Class(TGoogleResource)
  1065. Public
  1066. Class Function ResourceName : String; override;
  1067. Class Function DefaultAPI : TGoogleAPIClass; override;
  1068. Function List(accountId: string; adClientId: string; AQuery : string = '') : TUrlChannels;
  1069. Function List(accountId: string; adClientId: string; AQuery : TAccountsUrlchannelslistOptions) : TUrlChannels;
  1070. end;
  1071. { --------------------------------------------------------------------
  1072. TAccountsResource
  1073. --------------------------------------------------------------------}
  1074. //Optional query Options for TAccountsResource, method Get
  1075. TAccountsGetOptions = Record
  1076. tree : boolean;
  1077. end;
  1078. //Optional query Options for TAccountsResource, method List
  1079. TAccountsListOptions = Record
  1080. maxResults : integer;
  1081. pageToken : String;
  1082. end;
  1083. TAccountsResource = Class(TGoogleResource)
  1084. Private
  1085. FAdclientsInstance : TAccountsAdclientsResource;
  1086. FAdunitsCustomchannelsInstance : TAccountsAdunitsCustomchannelsResource;
  1087. FAdunitsInstance : TAccountsAdunitsResource;
  1088. FAlertsInstance : TAccountsAlertsResource;
  1089. FCustomchannelsAdunitsInstance : TAccountsCustomchannelsAdunitsResource;
  1090. FCustomchannelsInstance : TAccountsCustomchannelsResource;
  1091. FPaymentsInstance : TAccountsPaymentsResource;
  1092. FReportsSavedInstance : TAccountsReportsSavedResource;
  1093. FReportsInstance : TAccountsReportsResource;
  1094. FSavedadstylesInstance : TAccountsSavedadstylesResource;
  1095. FUrlchannelsInstance : TAccountsUrlchannelsResource;
  1096. Function GetAdclientsInstance : TAccountsAdclientsResource;virtual;
  1097. Function GetAdunitsCustomchannelsInstance : TAccountsAdunitsCustomchannelsResource;virtual;
  1098. Function GetAdunitsInstance : TAccountsAdunitsResource;virtual;
  1099. Function GetAlertsInstance : TAccountsAlertsResource;virtual;
  1100. Function GetCustomchannelsAdunitsInstance : TAccountsCustomchannelsAdunitsResource;virtual;
  1101. Function GetCustomchannelsInstance : TAccountsCustomchannelsResource;virtual;
  1102. Function GetPaymentsInstance : TAccountsPaymentsResource;virtual;
  1103. Function GetReportsSavedInstance : TAccountsReportsSavedResource;virtual;
  1104. Function GetReportsInstance : TAccountsReportsResource;virtual;
  1105. Function GetSavedadstylesInstance : TAccountsSavedadstylesResource;virtual;
  1106. Function GetUrlchannelsInstance : TAccountsUrlchannelsResource;virtual;
  1107. Public
  1108. Class Function ResourceName : String; override;
  1109. Class Function DefaultAPI : TGoogleAPIClass; override;
  1110. Function Get(accountId: string; AQuery : string = '') : TAccount;
  1111. Function Get(accountId: string; AQuery : TAccountsgetOptions) : TAccount;
  1112. Function List(AQuery : string = '') : TAccounts;
  1113. Function List(AQuery : TAccountslistOptions) : TAccounts;
  1114. Function CreateAdclientsResource(AOwner : TComponent) : TAccountsAdclientsResource;virtual;overload;
  1115. Function CreateAdclientsResource : TAccountsAdclientsResource;virtual;overload;
  1116. Function CreateAdunitsCustomchannelsResource(AOwner : TComponent) : TAccountsAdunitsCustomchannelsResource;virtual;overload;
  1117. Function CreateAdunitsCustomchannelsResource : TAccountsAdunitsCustomchannelsResource;virtual;overload;
  1118. Function CreateAdunitsResource(AOwner : TComponent) : TAccountsAdunitsResource;virtual;overload;
  1119. Function CreateAdunitsResource : TAccountsAdunitsResource;virtual;overload;
  1120. Function CreateAlertsResource(AOwner : TComponent) : TAccountsAlertsResource;virtual;overload;
  1121. Function CreateAlertsResource : TAccountsAlertsResource;virtual;overload;
  1122. Function CreateCustomchannelsAdunitsResource(AOwner : TComponent) : TAccountsCustomchannelsAdunitsResource;virtual;overload;
  1123. Function CreateCustomchannelsAdunitsResource : TAccountsCustomchannelsAdunitsResource;virtual;overload;
  1124. Function CreateCustomchannelsResource(AOwner : TComponent) : TAccountsCustomchannelsResource;virtual;overload;
  1125. Function CreateCustomchannelsResource : TAccountsCustomchannelsResource;virtual;overload;
  1126. Function CreatePaymentsResource(AOwner : TComponent) : TAccountsPaymentsResource;virtual;overload;
  1127. Function CreatePaymentsResource : TAccountsPaymentsResource;virtual;overload;
  1128. Function CreateReportsSavedResource(AOwner : TComponent) : TAccountsReportsSavedResource;virtual;overload;
  1129. Function CreateReportsSavedResource : TAccountsReportsSavedResource;virtual;overload;
  1130. Function CreateReportsResource(AOwner : TComponent) : TAccountsReportsResource;virtual;overload;
  1131. Function CreateReportsResource : TAccountsReportsResource;virtual;overload;
  1132. Function CreateSavedadstylesResource(AOwner : TComponent) : TAccountsSavedadstylesResource;virtual;overload;
  1133. Function CreateSavedadstylesResource : TAccountsSavedadstylesResource;virtual;overload;
  1134. Function CreateUrlchannelsResource(AOwner : TComponent) : TAccountsUrlchannelsResource;virtual;overload;
  1135. Function CreateUrlchannelsResource : TAccountsUrlchannelsResource;virtual;overload;
  1136. Property AdclientsResource : TAccountsAdclientsResource Read GetAdclientsInstance;
  1137. Property AdunitsCustomchannelsResource : TAccountsAdunitsCustomchannelsResource Read GetAdunitsCustomchannelsInstance;
  1138. Property AdunitsResource : TAccountsAdunitsResource Read GetAdunitsInstance;
  1139. Property AlertsResource : TAccountsAlertsResource Read GetAlertsInstance;
  1140. Property CustomchannelsAdunitsResource : TAccountsCustomchannelsAdunitsResource Read GetCustomchannelsAdunitsInstance;
  1141. Property CustomchannelsResource : TAccountsCustomchannelsResource Read GetCustomchannelsInstance;
  1142. Property PaymentsResource : TAccountsPaymentsResource Read GetPaymentsInstance;
  1143. Property ReportsSavedResource : TAccountsReportsSavedResource Read GetReportsSavedInstance;
  1144. Property ReportsResource : TAccountsReportsResource Read GetReportsInstance;
  1145. Property SavedadstylesResource : TAccountsSavedadstylesResource Read GetSavedadstylesInstance;
  1146. Property UrlchannelsResource : TAccountsUrlchannelsResource Read GetUrlchannelsInstance;
  1147. end;
  1148. { --------------------------------------------------------------------
  1149. TAdclientsResource
  1150. --------------------------------------------------------------------}
  1151. //Optional query Options for TAdclientsResource, method List
  1152. TAdclientsListOptions = Record
  1153. maxResults : integer;
  1154. pageToken : String;
  1155. end;
  1156. TAdclientsResource = Class(TGoogleResource)
  1157. Public
  1158. Class Function ResourceName : String; override;
  1159. Class Function DefaultAPI : TGoogleAPIClass; override;
  1160. Function List(AQuery : string = '') : TAdClients;
  1161. Function List(AQuery : TAdclientslistOptions) : TAdClients;
  1162. end;
  1163. { --------------------------------------------------------------------
  1164. TAdunitsCustomchannelsResource
  1165. --------------------------------------------------------------------}
  1166. //Optional query Options for TAdunitsCustomchannelsResource, method List
  1167. TAdunitsCustomchannelsListOptions = Record
  1168. maxResults : integer;
  1169. pageToken : String;
  1170. end;
  1171. TAdunitsCustomchannelsResource = Class(TGoogleResource)
  1172. Public
  1173. Class Function ResourceName : String; override;
  1174. Class Function DefaultAPI : TGoogleAPIClass; override;
  1175. Function List(adClientId: string; adUnitId: string; AQuery : string = '') : TCustomChannels;
  1176. Function List(adClientId: string; adUnitId: string; AQuery : TAdunitsCustomchannelslistOptions) : TCustomChannels;
  1177. end;
  1178. { --------------------------------------------------------------------
  1179. TAdunitsResource
  1180. --------------------------------------------------------------------}
  1181. //Optional query Options for TAdunitsResource, method List
  1182. TAdunitsListOptions = Record
  1183. includeInactive : boolean;
  1184. maxResults : integer;
  1185. pageToken : String;
  1186. end;
  1187. TAdunitsResource = Class(TGoogleResource)
  1188. Private
  1189. FCustomchannelsInstance : TAdunitsCustomchannelsResource;
  1190. Function GetCustomchannelsInstance : TAdunitsCustomchannelsResource;virtual;
  1191. Public
  1192. Class Function ResourceName : String; override;
  1193. Class Function DefaultAPI : TGoogleAPIClass; override;
  1194. Function Get(adClientId: string; adUnitId: string) : TAdUnit;
  1195. Function GetAdCode(adClientId: string; adUnitId: string) : TAdCode;
  1196. Function List(adClientId: string; AQuery : string = '') : TAdUnits;
  1197. Function List(adClientId: string; AQuery : TAdunitslistOptions) : TAdUnits;
  1198. Function CreateCustomchannelsResource(AOwner : TComponent) : TAdunitsCustomchannelsResource;virtual;overload;
  1199. Function CreateCustomchannelsResource : TAdunitsCustomchannelsResource;virtual;overload;
  1200. Property CustomchannelsResource : TAdunitsCustomchannelsResource Read GetCustomchannelsInstance;
  1201. end;
  1202. { --------------------------------------------------------------------
  1203. TAlertsResource
  1204. --------------------------------------------------------------------}
  1205. //Optional query Options for TAlertsResource, method List
  1206. TAlertsListOptions = Record
  1207. locale : String;
  1208. end;
  1209. TAlertsResource = Class(TGoogleResource)
  1210. Public
  1211. Class Function ResourceName : String; override;
  1212. Class Function DefaultAPI : TGoogleAPIClass; override;
  1213. Procedure Delete(alertId: string);
  1214. Function List(AQuery : string = '') : TAlerts;
  1215. Function List(AQuery : TAlertslistOptions) : TAlerts;
  1216. end;
  1217. { --------------------------------------------------------------------
  1218. TCustomchannelsAdunitsResource
  1219. --------------------------------------------------------------------}
  1220. //Optional query Options for TCustomchannelsAdunitsResource, method List
  1221. TCustomchannelsAdunitsListOptions = Record
  1222. includeInactive : boolean;
  1223. maxResults : integer;
  1224. pageToken : String;
  1225. end;
  1226. TCustomchannelsAdunitsResource = Class(TGoogleResource)
  1227. Public
  1228. Class Function ResourceName : String; override;
  1229. Class Function DefaultAPI : TGoogleAPIClass; override;
  1230. Function List(adClientId: string; customChannelId: string; AQuery : string = '') : TAdUnits;
  1231. Function List(adClientId: string; customChannelId: string; AQuery : TCustomchannelsAdunitslistOptions) : TAdUnits;
  1232. end;
  1233. { --------------------------------------------------------------------
  1234. TCustomchannelsResource
  1235. --------------------------------------------------------------------}
  1236. //Optional query Options for TCustomchannelsResource, method List
  1237. TCustomchannelsListOptions = Record
  1238. maxResults : integer;
  1239. pageToken : String;
  1240. end;
  1241. TCustomchannelsResource = Class(TGoogleResource)
  1242. Private
  1243. FAdunitsInstance : TCustomchannelsAdunitsResource;
  1244. Function GetAdunitsInstance : TCustomchannelsAdunitsResource;virtual;
  1245. Public
  1246. Class Function ResourceName : String; override;
  1247. Class Function DefaultAPI : TGoogleAPIClass; override;
  1248. Function Get(adClientId: string; customChannelId: string) : TCustomChannel;
  1249. Function List(adClientId: string; AQuery : string = '') : TCustomChannels;
  1250. Function List(adClientId: string; AQuery : TCustomchannelslistOptions) : TCustomChannels;
  1251. Function CreateAdunitsResource(AOwner : TComponent) : TCustomchannelsAdunitsResource;virtual;overload;
  1252. Function CreateAdunitsResource : TCustomchannelsAdunitsResource;virtual;overload;
  1253. Property AdunitsResource : TCustomchannelsAdunitsResource Read GetAdunitsInstance;
  1254. end;
  1255. { --------------------------------------------------------------------
  1256. TMetadataDimensionsResource
  1257. --------------------------------------------------------------------}
  1258. TMetadataDimensionsResource = Class(TGoogleResource)
  1259. Public
  1260. Class Function ResourceName : String; override;
  1261. Class Function DefaultAPI : TGoogleAPIClass; override;
  1262. Function List : TMetadata;
  1263. end;
  1264. { --------------------------------------------------------------------
  1265. TMetadataMetricsResource
  1266. --------------------------------------------------------------------}
  1267. TMetadataMetricsResource = Class(TGoogleResource)
  1268. Public
  1269. Class Function ResourceName : String; override;
  1270. Class Function DefaultAPI : TGoogleAPIClass; override;
  1271. Function List : TMetadata;
  1272. end;
  1273. { --------------------------------------------------------------------
  1274. TMetadataResource
  1275. --------------------------------------------------------------------}
  1276. TMetadataResource = Class(TGoogleResource)
  1277. Private
  1278. FDimensionsInstance : TMetadataDimensionsResource;
  1279. FMetricsInstance : TMetadataMetricsResource;
  1280. Function GetDimensionsInstance : TMetadataDimensionsResource;virtual;
  1281. Function GetMetricsInstance : TMetadataMetricsResource;virtual;
  1282. Public
  1283. Class Function ResourceName : String; override;
  1284. Class Function DefaultAPI : TGoogleAPIClass; override;
  1285. Function CreateDimensionsResource(AOwner : TComponent) : TMetadataDimensionsResource;virtual;overload;
  1286. Function CreateDimensionsResource : TMetadataDimensionsResource;virtual;overload;
  1287. Function CreateMetricsResource(AOwner : TComponent) : TMetadataMetricsResource;virtual;overload;
  1288. Function CreateMetricsResource : TMetadataMetricsResource;virtual;overload;
  1289. Property DimensionsResource : TMetadataDimensionsResource Read GetDimensionsInstance;
  1290. Property MetricsResource : TMetadataMetricsResource Read GetMetricsInstance;
  1291. end;
  1292. { --------------------------------------------------------------------
  1293. TPaymentsResource
  1294. --------------------------------------------------------------------}
  1295. TPaymentsResource = Class(TGoogleResource)
  1296. Public
  1297. Class Function ResourceName : String; override;
  1298. Class Function DefaultAPI : TGoogleAPIClass; override;
  1299. Function List : TPayments;
  1300. end;
  1301. { --------------------------------------------------------------------
  1302. TReportsSavedResource
  1303. --------------------------------------------------------------------}
  1304. //Optional query Options for TReportsSavedResource, method Generate
  1305. TReportsSavedGenerateOptions = Record
  1306. locale : String;
  1307. maxResults : integer;
  1308. startIndex : integer;
  1309. end;
  1310. //Optional query Options for TReportsSavedResource, method List
  1311. TReportsSavedListOptions = Record
  1312. maxResults : integer;
  1313. pageToken : String;
  1314. end;
  1315. TReportsSavedResource = Class(TGoogleResource)
  1316. Public
  1317. Class Function ResourceName : String; override;
  1318. Class Function DefaultAPI : TGoogleAPIClass; override;
  1319. Function Generate(savedReportId: string; AQuery : string = '') : TAdsenseReportsGenerateResponse;
  1320. Function Generate(savedReportId: string; AQuery : TReportsSavedgenerateOptions) : TAdsenseReportsGenerateResponse;
  1321. Function List(AQuery : string = '') : TSavedReports;
  1322. Function List(AQuery : TReportsSavedlistOptions) : TSavedReports;
  1323. end;
  1324. { --------------------------------------------------------------------
  1325. TReportsResource
  1326. --------------------------------------------------------------------}
  1327. //Optional query Options for TReportsResource, method Generate
  1328. TReportsGenerateOptions = Record
  1329. accountId : String;
  1330. currency : String;
  1331. dimension : String;
  1332. endDate : String;
  1333. filter : String;
  1334. locale : String;
  1335. maxResults : integer;
  1336. metric : String;
  1337. sort : String;
  1338. startDate : String;
  1339. startIndex : integer;
  1340. useTimezoneReporting : boolean;
  1341. end;
  1342. TReportsResource = Class(TGoogleResource)
  1343. Private
  1344. FSavedInstance : TReportsSavedResource;
  1345. Function GetSavedInstance : TReportsSavedResource;virtual;
  1346. Public
  1347. Class Function ResourceName : String; override;
  1348. Class Function DefaultAPI : TGoogleAPIClass; override;
  1349. Function Generate(AQuery : string = '') : TAdsenseReportsGenerateResponse;
  1350. Function Generate(AQuery : TReportsgenerateOptions) : TAdsenseReportsGenerateResponse;
  1351. Function CreateSavedResource(AOwner : TComponent) : TReportsSavedResource;virtual;overload;
  1352. Function CreateSavedResource : TReportsSavedResource;virtual;overload;
  1353. Property SavedResource : TReportsSavedResource Read GetSavedInstance;
  1354. end;
  1355. { --------------------------------------------------------------------
  1356. TSavedadstylesResource
  1357. --------------------------------------------------------------------}
  1358. //Optional query Options for TSavedadstylesResource, method List
  1359. TSavedadstylesListOptions = Record
  1360. maxResults : integer;
  1361. pageToken : String;
  1362. end;
  1363. TSavedadstylesResource = Class(TGoogleResource)
  1364. Public
  1365. Class Function ResourceName : String; override;
  1366. Class Function DefaultAPI : TGoogleAPIClass; override;
  1367. Function Get(savedAdStyleId: string) : TSavedAdStyle;
  1368. Function List(AQuery : string = '') : TSavedAdStyles;
  1369. Function List(AQuery : TSavedadstyleslistOptions) : TSavedAdStyles;
  1370. end;
  1371. { --------------------------------------------------------------------
  1372. TUrlchannelsResource
  1373. --------------------------------------------------------------------}
  1374. //Optional query Options for TUrlchannelsResource, method List
  1375. TUrlchannelsListOptions = Record
  1376. maxResults : integer;
  1377. pageToken : String;
  1378. end;
  1379. TUrlchannelsResource = Class(TGoogleResource)
  1380. Public
  1381. Class Function ResourceName : String; override;
  1382. Class Function DefaultAPI : TGoogleAPIClass; override;
  1383. Function List(adClientId: string; AQuery : string = '') : TUrlChannels;
  1384. Function List(adClientId: string; AQuery : TUrlchannelslistOptions) : TUrlChannels;
  1385. end;
  1386. { --------------------------------------------------------------------
  1387. TAdsenseAPI
  1388. --------------------------------------------------------------------}
  1389. TAdsenseAPI = Class(TGoogleAPI)
  1390. Private
  1391. FAccountsAdclientsInstance : TAccountsAdclientsResource;
  1392. FAccountsAdunitsCustomchannelsInstance : TAccountsAdunitsCustomchannelsResource;
  1393. FAccountsAdunitsInstance : TAccountsAdunitsResource;
  1394. FAccountsAlertsInstance : TAccountsAlertsResource;
  1395. FAccountsCustomchannelsAdunitsInstance : TAccountsCustomchannelsAdunitsResource;
  1396. FAccountsCustomchannelsInstance : TAccountsCustomchannelsResource;
  1397. FAccountsPaymentsInstance : TAccountsPaymentsResource;
  1398. FAccountsReportsSavedInstance : TAccountsReportsSavedResource;
  1399. FAccountsReportsInstance : TAccountsReportsResource;
  1400. FAccountsSavedadstylesInstance : TAccountsSavedadstylesResource;
  1401. FAccountsUrlchannelsInstance : TAccountsUrlchannelsResource;
  1402. FAccountsInstance : TAccountsResource;
  1403. FAdclientsInstance : TAdclientsResource;
  1404. FAdunitsCustomchannelsInstance : TAdunitsCustomchannelsResource;
  1405. FAdunitsInstance : TAdunitsResource;
  1406. FAlertsInstance : TAlertsResource;
  1407. FCustomchannelsAdunitsInstance : TCustomchannelsAdunitsResource;
  1408. FCustomchannelsInstance : TCustomchannelsResource;
  1409. FMetadataDimensionsInstance : TMetadataDimensionsResource;
  1410. FMetadataMetricsInstance : TMetadataMetricsResource;
  1411. FMetadataInstance : TMetadataResource;
  1412. FPaymentsInstance : TPaymentsResource;
  1413. FReportsSavedInstance : TReportsSavedResource;
  1414. FReportsInstance : TReportsResource;
  1415. FSavedadstylesInstance : TSavedadstylesResource;
  1416. FUrlchannelsInstance : TUrlchannelsResource;
  1417. Function GetAccountsAdclientsInstance : TAccountsAdclientsResource;virtual;
  1418. Function GetAccountsAdunitsCustomchannelsInstance : TAccountsAdunitsCustomchannelsResource;virtual;
  1419. Function GetAccountsAdunitsInstance : TAccountsAdunitsResource;virtual;
  1420. Function GetAccountsAlertsInstance : TAccountsAlertsResource;virtual;
  1421. Function GetAccountsCustomchannelsAdunitsInstance : TAccountsCustomchannelsAdunitsResource;virtual;
  1422. Function GetAccountsCustomchannelsInstance : TAccountsCustomchannelsResource;virtual;
  1423. Function GetAccountsPaymentsInstance : TAccountsPaymentsResource;virtual;
  1424. Function GetAccountsReportsSavedInstance : TAccountsReportsSavedResource;virtual;
  1425. Function GetAccountsReportsInstance : TAccountsReportsResource;virtual;
  1426. Function GetAccountsSavedadstylesInstance : TAccountsSavedadstylesResource;virtual;
  1427. Function GetAccountsUrlchannelsInstance : TAccountsUrlchannelsResource;virtual;
  1428. Function GetAccountsInstance : TAccountsResource;virtual;
  1429. Function GetAdclientsInstance : TAdclientsResource;virtual;
  1430. Function GetAdunitsCustomchannelsInstance : TAdunitsCustomchannelsResource;virtual;
  1431. Function GetAdunitsInstance : TAdunitsResource;virtual;
  1432. Function GetAlertsInstance : TAlertsResource;virtual;
  1433. Function GetCustomchannelsAdunitsInstance : TCustomchannelsAdunitsResource;virtual;
  1434. Function GetCustomchannelsInstance : TCustomchannelsResource;virtual;
  1435. Function GetMetadataDimensionsInstance : TMetadataDimensionsResource;virtual;
  1436. Function GetMetadataMetricsInstance : TMetadataMetricsResource;virtual;
  1437. Function GetMetadataInstance : TMetadataResource;virtual;
  1438. Function GetPaymentsInstance : TPaymentsResource;virtual;
  1439. Function GetReportsSavedInstance : TReportsSavedResource;virtual;
  1440. Function GetReportsInstance : TReportsResource;virtual;
  1441. Function GetSavedadstylesInstance : TSavedadstylesResource;virtual;
  1442. Function GetUrlchannelsInstance : TUrlchannelsResource;virtual;
  1443. Public
  1444. //Override class functions with API info
  1445. Class Function APIName : String; override;
  1446. Class Function APIVersion : String; override;
  1447. Class Function APIRevision : String; override;
  1448. Class Function APIID : String; override;
  1449. Class Function APITitle : String; override;
  1450. Class Function APIDescription : String; override;
  1451. Class Function APIOwnerDomain : String; override;
  1452. Class Function APIOwnerName : String; override;
  1453. Class Function APIIcon16 : String; override;
  1454. Class Function APIIcon32 : String; override;
  1455. Class Function APIdocumentationLink : String; override;
  1456. Class Function APIrootUrl : string; override;
  1457. Class Function APIbasePath : string;override;
  1458. Class Function APIbaseURL : String;override;
  1459. Class Function APIProtocol : string;override;
  1460. Class Function APIservicePath : string;override;
  1461. Class Function APIbatchPath : String;override;
  1462. Class Function APIAuthScopes : TScopeInfoArray;override;
  1463. Class Function APINeedsAuth : Boolean;override;
  1464. Class Procedure RegisterAPIResources; override;
  1465. //Add create function for resources
  1466. Function CreateAccountsAdclientsResource(AOwner : TComponent) : TAccountsAdclientsResource;virtual;overload;
  1467. Function CreateAccountsAdclientsResource : TAccountsAdclientsResource;virtual;overload;
  1468. Function CreateAccountsAdunitsCustomchannelsResource(AOwner : TComponent) : TAccountsAdunitsCustomchannelsResource;virtual;overload;
  1469. Function CreateAccountsAdunitsCustomchannelsResource : TAccountsAdunitsCustomchannelsResource;virtual;overload;
  1470. Function CreateAccountsAdunitsResource(AOwner : TComponent) : TAccountsAdunitsResource;virtual;overload;
  1471. Function CreateAccountsAdunitsResource : TAccountsAdunitsResource;virtual;overload;
  1472. Function CreateAccountsAlertsResource(AOwner : TComponent) : TAccountsAlertsResource;virtual;overload;
  1473. Function CreateAccountsAlertsResource : TAccountsAlertsResource;virtual;overload;
  1474. Function CreateAccountsCustomchannelsAdunitsResource(AOwner : TComponent) : TAccountsCustomchannelsAdunitsResource;virtual;overload;
  1475. Function CreateAccountsCustomchannelsAdunitsResource : TAccountsCustomchannelsAdunitsResource;virtual;overload;
  1476. Function CreateAccountsCustomchannelsResource(AOwner : TComponent) : TAccountsCustomchannelsResource;virtual;overload;
  1477. Function CreateAccountsCustomchannelsResource : TAccountsCustomchannelsResource;virtual;overload;
  1478. Function CreateAccountsPaymentsResource(AOwner : TComponent) : TAccountsPaymentsResource;virtual;overload;
  1479. Function CreateAccountsPaymentsResource : TAccountsPaymentsResource;virtual;overload;
  1480. Function CreateAccountsReportsSavedResource(AOwner : TComponent) : TAccountsReportsSavedResource;virtual;overload;
  1481. Function CreateAccountsReportsSavedResource : TAccountsReportsSavedResource;virtual;overload;
  1482. Function CreateAccountsReportsResource(AOwner : TComponent) : TAccountsReportsResource;virtual;overload;
  1483. Function CreateAccountsReportsResource : TAccountsReportsResource;virtual;overload;
  1484. Function CreateAccountsSavedadstylesResource(AOwner : TComponent) : TAccountsSavedadstylesResource;virtual;overload;
  1485. Function CreateAccountsSavedadstylesResource : TAccountsSavedadstylesResource;virtual;overload;
  1486. Function CreateAccountsUrlchannelsResource(AOwner : TComponent) : TAccountsUrlchannelsResource;virtual;overload;
  1487. Function CreateAccountsUrlchannelsResource : TAccountsUrlchannelsResource;virtual;overload;
  1488. Function CreateAccountsResource(AOwner : TComponent) : TAccountsResource;virtual;overload;
  1489. Function CreateAccountsResource : TAccountsResource;virtual;overload;
  1490. Function CreateAdclientsResource(AOwner : TComponent) : TAdclientsResource;virtual;overload;
  1491. Function CreateAdclientsResource : TAdclientsResource;virtual;overload;
  1492. Function CreateAdunitsCustomchannelsResource(AOwner : TComponent) : TAdunitsCustomchannelsResource;virtual;overload;
  1493. Function CreateAdunitsCustomchannelsResource : TAdunitsCustomchannelsResource;virtual;overload;
  1494. Function CreateAdunitsResource(AOwner : TComponent) : TAdunitsResource;virtual;overload;
  1495. Function CreateAdunitsResource : TAdunitsResource;virtual;overload;
  1496. Function CreateAlertsResource(AOwner : TComponent) : TAlertsResource;virtual;overload;
  1497. Function CreateAlertsResource : TAlertsResource;virtual;overload;
  1498. Function CreateCustomchannelsAdunitsResource(AOwner : TComponent) : TCustomchannelsAdunitsResource;virtual;overload;
  1499. Function CreateCustomchannelsAdunitsResource : TCustomchannelsAdunitsResource;virtual;overload;
  1500. Function CreateCustomchannelsResource(AOwner : TComponent) : TCustomchannelsResource;virtual;overload;
  1501. Function CreateCustomchannelsResource : TCustomchannelsResource;virtual;overload;
  1502. Function CreateMetadataDimensionsResource(AOwner : TComponent) : TMetadataDimensionsResource;virtual;overload;
  1503. Function CreateMetadataDimensionsResource : TMetadataDimensionsResource;virtual;overload;
  1504. Function CreateMetadataMetricsResource(AOwner : TComponent) : TMetadataMetricsResource;virtual;overload;
  1505. Function CreateMetadataMetricsResource : TMetadataMetricsResource;virtual;overload;
  1506. Function CreateMetadataResource(AOwner : TComponent) : TMetadataResource;virtual;overload;
  1507. Function CreateMetadataResource : TMetadataResource;virtual;overload;
  1508. Function CreatePaymentsResource(AOwner : TComponent) : TPaymentsResource;virtual;overload;
  1509. Function CreatePaymentsResource : TPaymentsResource;virtual;overload;
  1510. Function CreateReportsSavedResource(AOwner : TComponent) : TReportsSavedResource;virtual;overload;
  1511. Function CreateReportsSavedResource : TReportsSavedResource;virtual;overload;
  1512. Function CreateReportsResource(AOwner : TComponent) : TReportsResource;virtual;overload;
  1513. Function CreateReportsResource : TReportsResource;virtual;overload;
  1514. Function CreateSavedadstylesResource(AOwner : TComponent) : TSavedadstylesResource;virtual;overload;
  1515. Function CreateSavedadstylesResource : TSavedadstylesResource;virtual;overload;
  1516. Function CreateUrlchannelsResource(AOwner : TComponent) : TUrlchannelsResource;virtual;overload;
  1517. Function CreateUrlchannelsResource : TUrlchannelsResource;virtual;overload;
  1518. //Add default on-demand instances for resources
  1519. Property AccountsAdclientsResource : TAccountsAdclientsResource Read GetAccountsAdclientsInstance;
  1520. Property AccountsAdunitsCustomchannelsResource : TAccountsAdunitsCustomchannelsResource Read GetAccountsAdunitsCustomchannelsInstance;
  1521. Property AccountsAdunitsResource : TAccountsAdunitsResource Read GetAccountsAdunitsInstance;
  1522. Property AccountsAlertsResource : TAccountsAlertsResource Read GetAccountsAlertsInstance;
  1523. Property AccountsCustomchannelsAdunitsResource : TAccountsCustomchannelsAdunitsResource Read GetAccountsCustomchannelsAdunitsInstance;
  1524. Property AccountsCustomchannelsResource : TAccountsCustomchannelsResource Read GetAccountsCustomchannelsInstance;
  1525. Property AccountsPaymentsResource : TAccountsPaymentsResource Read GetAccountsPaymentsInstance;
  1526. Property AccountsReportsSavedResource : TAccountsReportsSavedResource Read GetAccountsReportsSavedInstance;
  1527. Property AccountsReportsResource : TAccountsReportsResource Read GetAccountsReportsInstance;
  1528. Property AccountsSavedadstylesResource : TAccountsSavedadstylesResource Read GetAccountsSavedadstylesInstance;
  1529. Property AccountsUrlchannelsResource : TAccountsUrlchannelsResource Read GetAccountsUrlchannelsInstance;
  1530. Property AccountsResource : TAccountsResource Read GetAccountsInstance;
  1531. Property AdclientsResource : TAdclientsResource Read GetAdclientsInstance;
  1532. Property AdunitsCustomchannelsResource : TAdunitsCustomchannelsResource Read GetAdunitsCustomchannelsInstance;
  1533. Property AdunitsResource : TAdunitsResource Read GetAdunitsInstance;
  1534. Property AlertsResource : TAlertsResource Read GetAlertsInstance;
  1535. Property CustomchannelsAdunitsResource : TCustomchannelsAdunitsResource Read GetCustomchannelsAdunitsInstance;
  1536. Property CustomchannelsResource : TCustomchannelsResource Read GetCustomchannelsInstance;
  1537. Property MetadataDimensionsResource : TMetadataDimensionsResource Read GetMetadataDimensionsInstance;
  1538. Property MetadataMetricsResource : TMetadataMetricsResource Read GetMetadataMetricsInstance;
  1539. Property MetadataResource : TMetadataResource Read GetMetadataInstance;
  1540. Property PaymentsResource : TPaymentsResource Read GetPaymentsInstance;
  1541. Property ReportsSavedResource : TReportsSavedResource Read GetReportsSavedInstance;
  1542. Property ReportsResource : TReportsResource Read GetReportsInstance;
  1543. Property SavedadstylesResource : TSavedadstylesResource Read GetSavedadstylesInstance;
  1544. Property UrlchannelsResource : TUrlchannelsResource Read GetUrlchannelsInstance;
  1545. end;
  1546. implementation
  1547. { --------------------------------------------------------------------
  1548. TAccount
  1549. --------------------------------------------------------------------}
  1550. Procedure TAccount.Setcreation_time(AIndex : Integer; const AValue : String);
  1551. begin
  1552. If (Fcreation_time=AValue) then exit;
  1553. Fcreation_time:=AValue;
  1554. MarkPropertyChanged(AIndex);
  1555. end;
  1556. Procedure TAccount.Setid(AIndex : Integer; const AValue : String);
  1557. begin
  1558. If (Fid=AValue) then exit;
  1559. Fid:=AValue;
  1560. MarkPropertyChanged(AIndex);
  1561. end;
  1562. Procedure TAccount.Setkind(AIndex : Integer; const AValue : String);
  1563. begin
  1564. If (Fkind=AValue) then exit;
  1565. Fkind:=AValue;
  1566. MarkPropertyChanged(AIndex);
  1567. end;
  1568. Procedure TAccount.Setname(AIndex : Integer; const AValue : String);
  1569. begin
  1570. If (Fname=AValue) then exit;
  1571. Fname:=AValue;
  1572. MarkPropertyChanged(AIndex);
  1573. end;
  1574. Procedure TAccount.Setpremium(AIndex : Integer; const AValue : boolean);
  1575. begin
  1576. If (Fpremium=AValue) then exit;
  1577. Fpremium:=AValue;
  1578. MarkPropertyChanged(AIndex);
  1579. end;
  1580. Procedure TAccount.SetsubAccounts(AIndex : Integer; const AValue : TAccountTypesubAccountsArray);
  1581. begin
  1582. If (FsubAccounts=AValue) then exit;
  1583. FsubAccounts:=AValue;
  1584. MarkPropertyChanged(AIndex);
  1585. end;
  1586. Procedure TAccount.Settimezone(AIndex : Integer; const AValue : String);
  1587. begin
  1588. If (Ftimezone=AValue) then exit;
  1589. Ftimezone:=AValue;
  1590. MarkPropertyChanged(AIndex);
  1591. end;
  1592. //2.6.4. bug workaround
  1593. {$IFDEF VER2_6}
  1594. Procedure TAccount.SetArrayLength(Const AName : String; ALength : Longint);
  1595. begin
  1596. Case AName of
  1597. 'subaccounts' : SetLength(FsubAccounts,ALength);
  1598. else
  1599. Inherited SetArrayLength(AName,ALength);
  1600. end;
  1601. end;
  1602. {$ENDIF VER2_6}
  1603. { --------------------------------------------------------------------
  1604. TAccounts
  1605. --------------------------------------------------------------------}
  1606. Procedure TAccounts.Setetag(AIndex : Integer; const AValue : String);
  1607. begin
  1608. If (Fetag=AValue) then exit;
  1609. Fetag:=AValue;
  1610. MarkPropertyChanged(AIndex);
  1611. end;
  1612. Procedure TAccounts.Setitems(AIndex : Integer; const AValue : TAccountsTypeitemsArray);
  1613. begin
  1614. If (Fitems=AValue) then exit;
  1615. Fitems:=AValue;
  1616. MarkPropertyChanged(AIndex);
  1617. end;
  1618. Procedure TAccounts.Setkind(AIndex : Integer; const AValue : String);
  1619. begin
  1620. If (Fkind=AValue) then exit;
  1621. Fkind:=AValue;
  1622. MarkPropertyChanged(AIndex);
  1623. end;
  1624. Procedure TAccounts.SetnextPageToken(AIndex : Integer; const AValue : String);
  1625. begin
  1626. If (FnextPageToken=AValue) then exit;
  1627. FnextPageToken:=AValue;
  1628. MarkPropertyChanged(AIndex);
  1629. end;
  1630. //2.6.4. bug workaround
  1631. {$IFDEF VER2_6}
  1632. Procedure TAccounts.SetArrayLength(Const AName : String; ALength : Longint);
  1633. begin
  1634. Case AName of
  1635. 'items' : SetLength(Fitems,ALength);
  1636. else
  1637. Inherited SetArrayLength(AName,ALength);
  1638. end;
  1639. end;
  1640. {$ENDIF VER2_6}
  1641. { --------------------------------------------------------------------
  1642. TAdClient
  1643. --------------------------------------------------------------------}
  1644. Procedure TAdClient.SetarcOptIn(AIndex : Integer; const AValue : boolean);
  1645. begin
  1646. If (FarcOptIn=AValue) then exit;
  1647. FarcOptIn:=AValue;
  1648. MarkPropertyChanged(AIndex);
  1649. end;
  1650. Procedure TAdClient.Setid(AIndex : Integer; const AValue : String);
  1651. begin
  1652. If (Fid=AValue) then exit;
  1653. Fid:=AValue;
  1654. MarkPropertyChanged(AIndex);
  1655. end;
  1656. Procedure TAdClient.Setkind(AIndex : Integer; const AValue : String);
  1657. begin
  1658. If (Fkind=AValue) then exit;
  1659. Fkind:=AValue;
  1660. MarkPropertyChanged(AIndex);
  1661. end;
  1662. Procedure TAdClient.SetproductCode(AIndex : Integer; const AValue : String);
  1663. begin
  1664. If (FproductCode=AValue) then exit;
  1665. FproductCode:=AValue;
  1666. MarkPropertyChanged(AIndex);
  1667. end;
  1668. Procedure TAdClient.SetsupportsReporting(AIndex : Integer; const AValue : boolean);
  1669. begin
  1670. If (FsupportsReporting=AValue) then exit;
  1671. FsupportsReporting:=AValue;
  1672. MarkPropertyChanged(AIndex);
  1673. end;
  1674. { --------------------------------------------------------------------
  1675. TAdClients
  1676. --------------------------------------------------------------------}
  1677. Procedure TAdClients.Setetag(AIndex : Integer; const AValue : String);
  1678. begin
  1679. If (Fetag=AValue) then exit;
  1680. Fetag:=AValue;
  1681. MarkPropertyChanged(AIndex);
  1682. end;
  1683. Procedure TAdClients.Setitems(AIndex : Integer; const AValue : TAdClientsTypeitemsArray);
  1684. begin
  1685. If (Fitems=AValue) then exit;
  1686. Fitems:=AValue;
  1687. MarkPropertyChanged(AIndex);
  1688. end;
  1689. Procedure TAdClients.Setkind(AIndex : Integer; const AValue : String);
  1690. begin
  1691. If (Fkind=AValue) then exit;
  1692. Fkind:=AValue;
  1693. MarkPropertyChanged(AIndex);
  1694. end;
  1695. Procedure TAdClients.SetnextPageToken(AIndex : Integer; const AValue : String);
  1696. begin
  1697. If (FnextPageToken=AValue) then exit;
  1698. FnextPageToken:=AValue;
  1699. MarkPropertyChanged(AIndex);
  1700. end;
  1701. //2.6.4. bug workaround
  1702. {$IFDEF VER2_6}
  1703. Procedure TAdClients.SetArrayLength(Const AName : String; ALength : Longint);
  1704. begin
  1705. Case AName of
  1706. 'items' : SetLength(Fitems,ALength);
  1707. else
  1708. Inherited SetArrayLength(AName,ALength);
  1709. end;
  1710. end;
  1711. {$ENDIF VER2_6}
  1712. { --------------------------------------------------------------------
  1713. TAdCode
  1714. --------------------------------------------------------------------}
  1715. Procedure TAdCode.SetadCode(AIndex : Integer; const AValue : String);
  1716. begin
  1717. If (FadCode=AValue) then exit;
  1718. FadCode:=AValue;
  1719. MarkPropertyChanged(AIndex);
  1720. end;
  1721. Procedure TAdCode.Setkind(AIndex : Integer; const AValue : String);
  1722. begin
  1723. If (Fkind=AValue) then exit;
  1724. Fkind:=AValue;
  1725. MarkPropertyChanged(AIndex);
  1726. end;
  1727. { --------------------------------------------------------------------
  1728. TAdStyleTypecolors
  1729. --------------------------------------------------------------------}
  1730. Procedure TAdStyleTypecolors.Setbackground(AIndex : Integer; const AValue : String);
  1731. begin
  1732. If (Fbackground=AValue) then exit;
  1733. Fbackground:=AValue;
  1734. MarkPropertyChanged(AIndex);
  1735. end;
  1736. Procedure TAdStyleTypecolors.Setborder(AIndex : Integer; const AValue : String);
  1737. begin
  1738. If (Fborder=AValue) then exit;
  1739. Fborder:=AValue;
  1740. MarkPropertyChanged(AIndex);
  1741. end;
  1742. Procedure TAdStyleTypecolors.Settext(AIndex : Integer; const AValue : String);
  1743. begin
  1744. If (Ftext=AValue) then exit;
  1745. Ftext:=AValue;
  1746. MarkPropertyChanged(AIndex);
  1747. end;
  1748. Procedure TAdStyleTypecolors.Settitle(AIndex : Integer; const AValue : String);
  1749. begin
  1750. If (Ftitle=AValue) then exit;
  1751. Ftitle:=AValue;
  1752. MarkPropertyChanged(AIndex);
  1753. end;
  1754. Procedure TAdStyleTypecolors.Seturl(AIndex : Integer; const AValue : String);
  1755. begin
  1756. If (Furl=AValue) then exit;
  1757. Furl:=AValue;
  1758. MarkPropertyChanged(AIndex);
  1759. end;
  1760. { --------------------------------------------------------------------
  1761. TAdStyleTypefont
  1762. --------------------------------------------------------------------}
  1763. Procedure TAdStyleTypefont.Setfamily(AIndex : Integer; const AValue : String);
  1764. begin
  1765. If (Ffamily=AValue) then exit;
  1766. Ffamily:=AValue;
  1767. MarkPropertyChanged(AIndex);
  1768. end;
  1769. Procedure TAdStyleTypefont.Setsize(AIndex : Integer; const AValue : String);
  1770. begin
  1771. If (Fsize=AValue) then exit;
  1772. Fsize:=AValue;
  1773. MarkPropertyChanged(AIndex);
  1774. end;
  1775. { --------------------------------------------------------------------
  1776. TAdStyle
  1777. --------------------------------------------------------------------}
  1778. Procedure TAdStyle.Setcolors(AIndex : Integer; const AValue : TAdStyleTypecolors);
  1779. begin
  1780. If (Fcolors=AValue) then exit;
  1781. Fcolors:=AValue;
  1782. MarkPropertyChanged(AIndex);
  1783. end;
  1784. Procedure TAdStyle.Setcorners(AIndex : Integer; const AValue : String);
  1785. begin
  1786. If (Fcorners=AValue) then exit;
  1787. Fcorners:=AValue;
  1788. MarkPropertyChanged(AIndex);
  1789. end;
  1790. Procedure TAdStyle.Setfont(AIndex : Integer; const AValue : TAdStyleTypefont);
  1791. begin
  1792. If (Ffont=AValue) then exit;
  1793. Ffont:=AValue;
  1794. MarkPropertyChanged(AIndex);
  1795. end;
  1796. Procedure TAdStyle.Setkind(AIndex : Integer; const AValue : String);
  1797. begin
  1798. If (Fkind=AValue) then exit;
  1799. Fkind:=AValue;
  1800. MarkPropertyChanged(AIndex);
  1801. end;
  1802. { --------------------------------------------------------------------
  1803. TAdUnitTypecontentAdsSettingsTypebackupOption
  1804. --------------------------------------------------------------------}
  1805. Procedure TAdUnitTypecontentAdsSettingsTypebackupOption.Setcolor(AIndex : Integer; const AValue : String);
  1806. begin
  1807. If (Fcolor=AValue) then exit;
  1808. Fcolor:=AValue;
  1809. MarkPropertyChanged(AIndex);
  1810. end;
  1811. Procedure TAdUnitTypecontentAdsSettingsTypebackupOption.Set_type(AIndex : Integer; const AValue : String);
  1812. begin
  1813. If (F_type=AValue) then exit;
  1814. F_type:=AValue;
  1815. MarkPropertyChanged(AIndex);
  1816. end;
  1817. Procedure TAdUnitTypecontentAdsSettingsTypebackupOption.Seturl(AIndex : Integer; const AValue : String);
  1818. begin
  1819. If (Furl=AValue) then exit;
  1820. Furl:=AValue;
  1821. MarkPropertyChanged(AIndex);
  1822. end;
  1823. Class Function TAdUnitTypecontentAdsSettingsTypebackupOption.ExportPropertyName(Const AName : String) :String;
  1824. begin
  1825. Case AName of
  1826. '_type' : Result:='type';
  1827. else
  1828. Result:=Inherited ExportPropertyName(AName);
  1829. end;
  1830. end;
  1831. { --------------------------------------------------------------------
  1832. TAdUnitTypecontentAdsSettings
  1833. --------------------------------------------------------------------}
  1834. Procedure TAdUnitTypecontentAdsSettings.SetbackupOption(AIndex : Integer; const AValue : TAdUnitTypecontentAdsSettingsTypebackupOption);
  1835. begin
  1836. If (FbackupOption=AValue) then exit;
  1837. FbackupOption:=AValue;
  1838. MarkPropertyChanged(AIndex);
  1839. end;
  1840. Procedure TAdUnitTypecontentAdsSettings.Setsize(AIndex : Integer; const AValue : String);
  1841. begin
  1842. If (Fsize=AValue) then exit;
  1843. Fsize:=AValue;
  1844. MarkPropertyChanged(AIndex);
  1845. end;
  1846. Procedure TAdUnitTypecontentAdsSettings.Set_type(AIndex : Integer; const AValue : String);
  1847. begin
  1848. If (F_type=AValue) then exit;
  1849. F_type:=AValue;
  1850. MarkPropertyChanged(AIndex);
  1851. end;
  1852. Class Function TAdUnitTypecontentAdsSettings.ExportPropertyName(Const AName : String) :String;
  1853. begin
  1854. Case AName of
  1855. '_type' : Result:='type';
  1856. else
  1857. Result:=Inherited ExportPropertyName(AName);
  1858. end;
  1859. end;
  1860. { --------------------------------------------------------------------
  1861. TAdUnitTypefeedAdsSettings
  1862. --------------------------------------------------------------------}
  1863. Procedure TAdUnitTypefeedAdsSettings.SetadPosition(AIndex : Integer; const AValue : String);
  1864. begin
  1865. If (FadPosition=AValue) then exit;
  1866. FadPosition:=AValue;
  1867. MarkPropertyChanged(AIndex);
  1868. end;
  1869. Procedure TAdUnitTypefeedAdsSettings.Setfrequency(AIndex : Integer; const AValue : integer);
  1870. begin
  1871. If (Ffrequency=AValue) then exit;
  1872. Ffrequency:=AValue;
  1873. MarkPropertyChanged(AIndex);
  1874. end;
  1875. Procedure TAdUnitTypefeedAdsSettings.SetminimumWordCount(AIndex : Integer; const AValue : integer);
  1876. begin
  1877. If (FminimumWordCount=AValue) then exit;
  1878. FminimumWordCount:=AValue;
  1879. MarkPropertyChanged(AIndex);
  1880. end;
  1881. Procedure TAdUnitTypefeedAdsSettings.Set_type(AIndex : Integer; const AValue : String);
  1882. begin
  1883. If (F_type=AValue) then exit;
  1884. F_type:=AValue;
  1885. MarkPropertyChanged(AIndex);
  1886. end;
  1887. Class Function TAdUnitTypefeedAdsSettings.ExportPropertyName(Const AName : String) :String;
  1888. begin
  1889. Case AName of
  1890. '_type' : Result:='type';
  1891. else
  1892. Result:=Inherited ExportPropertyName(AName);
  1893. end;
  1894. end;
  1895. { --------------------------------------------------------------------
  1896. TAdUnitTypemobileContentAdsSettings
  1897. --------------------------------------------------------------------}
  1898. Procedure TAdUnitTypemobileContentAdsSettings.SetmarkupLanguage(AIndex : Integer; const AValue : String);
  1899. begin
  1900. If (FmarkupLanguage=AValue) then exit;
  1901. FmarkupLanguage:=AValue;
  1902. MarkPropertyChanged(AIndex);
  1903. end;
  1904. Procedure TAdUnitTypemobileContentAdsSettings.SetscriptingLanguage(AIndex : Integer; const AValue : String);
  1905. begin
  1906. If (FscriptingLanguage=AValue) then exit;
  1907. FscriptingLanguage:=AValue;
  1908. MarkPropertyChanged(AIndex);
  1909. end;
  1910. Procedure TAdUnitTypemobileContentAdsSettings.Setsize(AIndex : Integer; const AValue : String);
  1911. begin
  1912. If (Fsize=AValue) then exit;
  1913. Fsize:=AValue;
  1914. MarkPropertyChanged(AIndex);
  1915. end;
  1916. Procedure TAdUnitTypemobileContentAdsSettings.Set_type(AIndex : Integer; const AValue : String);
  1917. begin
  1918. If (F_type=AValue) then exit;
  1919. F_type:=AValue;
  1920. MarkPropertyChanged(AIndex);
  1921. end;
  1922. Class Function TAdUnitTypemobileContentAdsSettings.ExportPropertyName(Const AName : String) :String;
  1923. begin
  1924. Case AName of
  1925. '_type' : Result:='type';
  1926. else
  1927. Result:=Inherited ExportPropertyName(AName);
  1928. end;
  1929. end;
  1930. { --------------------------------------------------------------------
  1931. TAdUnit
  1932. --------------------------------------------------------------------}
  1933. Procedure TAdUnit.Setcode(AIndex : Integer; const AValue : String);
  1934. begin
  1935. If (Fcode=AValue) then exit;
  1936. Fcode:=AValue;
  1937. MarkPropertyChanged(AIndex);
  1938. end;
  1939. Procedure TAdUnit.SetcontentAdsSettings(AIndex : Integer; const AValue : TAdUnitTypecontentAdsSettings);
  1940. begin
  1941. If (FcontentAdsSettings=AValue) then exit;
  1942. FcontentAdsSettings:=AValue;
  1943. MarkPropertyChanged(AIndex);
  1944. end;
  1945. Procedure TAdUnit.SetcustomStyle(AIndex : Integer; const AValue : TAdStyle);
  1946. begin
  1947. If (FcustomStyle=AValue) then exit;
  1948. FcustomStyle:=AValue;
  1949. MarkPropertyChanged(AIndex);
  1950. end;
  1951. Procedure TAdUnit.SetfeedAdsSettings(AIndex : Integer; const AValue : TAdUnitTypefeedAdsSettings);
  1952. begin
  1953. If (FfeedAdsSettings=AValue) then exit;
  1954. FfeedAdsSettings:=AValue;
  1955. MarkPropertyChanged(AIndex);
  1956. end;
  1957. Procedure TAdUnit.Setid(AIndex : Integer; const AValue : String);
  1958. begin
  1959. If (Fid=AValue) then exit;
  1960. Fid:=AValue;
  1961. MarkPropertyChanged(AIndex);
  1962. end;
  1963. Procedure TAdUnit.Setkind(AIndex : Integer; const AValue : String);
  1964. begin
  1965. If (Fkind=AValue) then exit;
  1966. Fkind:=AValue;
  1967. MarkPropertyChanged(AIndex);
  1968. end;
  1969. Procedure TAdUnit.SetmobileContentAdsSettings(AIndex : Integer; const AValue : TAdUnitTypemobileContentAdsSettings);
  1970. begin
  1971. If (FmobileContentAdsSettings=AValue) then exit;
  1972. FmobileContentAdsSettings:=AValue;
  1973. MarkPropertyChanged(AIndex);
  1974. end;
  1975. Procedure TAdUnit.Setname(AIndex : Integer; const AValue : String);
  1976. begin
  1977. If (Fname=AValue) then exit;
  1978. Fname:=AValue;
  1979. MarkPropertyChanged(AIndex);
  1980. end;
  1981. Procedure TAdUnit.SetsavedStyleId(AIndex : Integer; const AValue : String);
  1982. begin
  1983. If (FsavedStyleId=AValue) then exit;
  1984. FsavedStyleId:=AValue;
  1985. MarkPropertyChanged(AIndex);
  1986. end;
  1987. Procedure TAdUnit.Setstatus(AIndex : Integer; const AValue : String);
  1988. begin
  1989. If (Fstatus=AValue) then exit;
  1990. Fstatus:=AValue;
  1991. MarkPropertyChanged(AIndex);
  1992. end;
  1993. { --------------------------------------------------------------------
  1994. TAdUnits
  1995. --------------------------------------------------------------------}
  1996. Procedure TAdUnits.Setetag(AIndex : Integer; const AValue : String);
  1997. begin
  1998. If (Fetag=AValue) then exit;
  1999. Fetag:=AValue;
  2000. MarkPropertyChanged(AIndex);
  2001. end;
  2002. Procedure TAdUnits.Setitems(AIndex : Integer; const AValue : TAdUnitsTypeitemsArray);
  2003. begin
  2004. If (Fitems=AValue) then exit;
  2005. Fitems:=AValue;
  2006. MarkPropertyChanged(AIndex);
  2007. end;
  2008. Procedure TAdUnits.Setkind(AIndex : Integer; const AValue : String);
  2009. begin
  2010. If (Fkind=AValue) then exit;
  2011. Fkind:=AValue;
  2012. MarkPropertyChanged(AIndex);
  2013. end;
  2014. Procedure TAdUnits.SetnextPageToken(AIndex : Integer; const AValue : String);
  2015. begin
  2016. If (FnextPageToken=AValue) then exit;
  2017. FnextPageToken:=AValue;
  2018. MarkPropertyChanged(AIndex);
  2019. end;
  2020. //2.6.4. bug workaround
  2021. {$IFDEF VER2_6}
  2022. Procedure TAdUnits.SetArrayLength(Const AName : String; ALength : Longint);
  2023. begin
  2024. Case AName of
  2025. 'items' : SetLength(Fitems,ALength);
  2026. else
  2027. Inherited SetArrayLength(AName,ALength);
  2028. end;
  2029. end;
  2030. {$ENDIF VER2_6}
  2031. { --------------------------------------------------------------------
  2032. TAdsenseReportsGenerateResponseTypeheadersItem
  2033. --------------------------------------------------------------------}
  2034. Procedure TAdsenseReportsGenerateResponseTypeheadersItem.Setcurrency(AIndex : Integer; const AValue : String);
  2035. begin
  2036. If (Fcurrency=AValue) then exit;
  2037. Fcurrency:=AValue;
  2038. MarkPropertyChanged(AIndex);
  2039. end;
  2040. Procedure TAdsenseReportsGenerateResponseTypeheadersItem.Setname(AIndex : Integer; const AValue : String);
  2041. begin
  2042. If (Fname=AValue) then exit;
  2043. Fname:=AValue;
  2044. MarkPropertyChanged(AIndex);
  2045. end;
  2046. Procedure TAdsenseReportsGenerateResponseTypeheadersItem.Set_type(AIndex : Integer; const AValue : String);
  2047. begin
  2048. If (F_type=AValue) then exit;
  2049. F_type:=AValue;
  2050. MarkPropertyChanged(AIndex);
  2051. end;
  2052. Class Function TAdsenseReportsGenerateResponseTypeheadersItem.ExportPropertyName(Const AName : String) :String;
  2053. begin
  2054. Case AName of
  2055. '_type' : Result:='type';
  2056. else
  2057. Result:=Inherited ExportPropertyName(AName);
  2058. end;
  2059. end;
  2060. { --------------------------------------------------------------------
  2061. TAdsenseReportsGenerateResponse
  2062. --------------------------------------------------------------------}
  2063. Procedure TAdsenseReportsGenerateResponse.Setaverages(AIndex : Integer; const AValue : TStringArray);
  2064. begin
  2065. If (Faverages=AValue) then exit;
  2066. Faverages:=AValue;
  2067. MarkPropertyChanged(AIndex);
  2068. end;
  2069. Procedure TAdsenseReportsGenerateResponse.SetendDate(AIndex : Integer; const AValue : String);
  2070. begin
  2071. If (FendDate=AValue) then exit;
  2072. FendDate:=AValue;
  2073. MarkPropertyChanged(AIndex);
  2074. end;
  2075. Procedure TAdsenseReportsGenerateResponse.Setheaders(AIndex : Integer; const AValue : TAdsenseReportsGenerateResponseTypeheadersArray);
  2076. begin
  2077. If (Fheaders=AValue) then exit;
  2078. Fheaders:=AValue;
  2079. MarkPropertyChanged(AIndex);
  2080. end;
  2081. Procedure TAdsenseReportsGenerateResponse.Setkind(AIndex : Integer; const AValue : String);
  2082. begin
  2083. If (Fkind=AValue) then exit;
  2084. Fkind:=AValue;
  2085. MarkPropertyChanged(AIndex);
  2086. end;
  2087. Procedure TAdsenseReportsGenerateResponse.Setrows(AIndex : Integer; const AValue : TAdsenseReportsGenerateResponseTyperowsArray);
  2088. begin
  2089. If (Frows=AValue) then exit;
  2090. Frows:=AValue;
  2091. MarkPropertyChanged(AIndex);
  2092. end;
  2093. Procedure TAdsenseReportsGenerateResponse.SetstartDate(AIndex : Integer; const AValue : String);
  2094. begin
  2095. If (FstartDate=AValue) then exit;
  2096. FstartDate:=AValue;
  2097. MarkPropertyChanged(AIndex);
  2098. end;
  2099. Procedure TAdsenseReportsGenerateResponse.SettotalMatchedRows(AIndex : Integer; const AValue : String);
  2100. begin
  2101. If (FtotalMatchedRows=AValue) then exit;
  2102. FtotalMatchedRows:=AValue;
  2103. MarkPropertyChanged(AIndex);
  2104. end;
  2105. Procedure TAdsenseReportsGenerateResponse.Settotals(AIndex : Integer; const AValue : TStringArray);
  2106. begin
  2107. If (Ftotals=AValue) then exit;
  2108. Ftotals:=AValue;
  2109. MarkPropertyChanged(AIndex);
  2110. end;
  2111. Procedure TAdsenseReportsGenerateResponse.Setwarnings(AIndex : Integer; const AValue : TStringArray);
  2112. begin
  2113. If (Fwarnings=AValue) then exit;
  2114. Fwarnings:=AValue;
  2115. MarkPropertyChanged(AIndex);
  2116. end;
  2117. //2.6.4. bug workaround
  2118. {$IFDEF VER2_6}
  2119. Procedure TAdsenseReportsGenerateResponse.SetArrayLength(Const AName : String; ALength : Longint);
  2120. begin
  2121. Case AName of
  2122. 'averages' : SetLength(Faverages,ALength);
  2123. 'headers' : SetLength(Fheaders,ALength);
  2124. 'rows' : SetLength(Frows,ALength);
  2125. 'totals' : SetLength(Ftotals,ALength);
  2126. 'warnings' : SetLength(Fwarnings,ALength);
  2127. else
  2128. Inherited SetArrayLength(AName,ALength);
  2129. end;
  2130. end;
  2131. {$ENDIF VER2_6}
  2132. { --------------------------------------------------------------------
  2133. TAlert
  2134. --------------------------------------------------------------------}
  2135. Procedure TAlert.Setid(AIndex : Integer; const AValue : String);
  2136. begin
  2137. If (Fid=AValue) then exit;
  2138. Fid:=AValue;
  2139. MarkPropertyChanged(AIndex);
  2140. end;
  2141. Procedure TAlert.SetisDismissible(AIndex : Integer; const AValue : boolean);
  2142. begin
  2143. If (FisDismissible=AValue) then exit;
  2144. FisDismissible:=AValue;
  2145. MarkPropertyChanged(AIndex);
  2146. end;
  2147. Procedure TAlert.Setkind(AIndex : Integer; const AValue : String);
  2148. begin
  2149. If (Fkind=AValue) then exit;
  2150. Fkind:=AValue;
  2151. MarkPropertyChanged(AIndex);
  2152. end;
  2153. Procedure TAlert.Setmessage(AIndex : Integer; const AValue : String);
  2154. begin
  2155. If (Fmessage=AValue) then exit;
  2156. Fmessage:=AValue;
  2157. MarkPropertyChanged(AIndex);
  2158. end;
  2159. Procedure TAlert.Setseverity(AIndex : Integer; const AValue : String);
  2160. begin
  2161. If (Fseverity=AValue) then exit;
  2162. Fseverity:=AValue;
  2163. MarkPropertyChanged(AIndex);
  2164. end;
  2165. Procedure TAlert.Set_type(AIndex : Integer; const AValue : String);
  2166. begin
  2167. If (F_type=AValue) then exit;
  2168. F_type:=AValue;
  2169. MarkPropertyChanged(AIndex);
  2170. end;
  2171. Class Function TAlert.ExportPropertyName(Const AName : String) :String;
  2172. begin
  2173. Case AName of
  2174. '_type' : Result:='type';
  2175. else
  2176. Result:=Inherited ExportPropertyName(AName);
  2177. end;
  2178. end;
  2179. { --------------------------------------------------------------------
  2180. TAlerts
  2181. --------------------------------------------------------------------}
  2182. Procedure TAlerts.Setitems(AIndex : Integer; const AValue : TAlertsTypeitemsArray);
  2183. begin
  2184. If (Fitems=AValue) then exit;
  2185. Fitems:=AValue;
  2186. MarkPropertyChanged(AIndex);
  2187. end;
  2188. Procedure TAlerts.Setkind(AIndex : Integer; const AValue : String);
  2189. begin
  2190. If (Fkind=AValue) then exit;
  2191. Fkind:=AValue;
  2192. MarkPropertyChanged(AIndex);
  2193. end;
  2194. //2.6.4. bug workaround
  2195. {$IFDEF VER2_6}
  2196. Procedure TAlerts.SetArrayLength(Const AName : String; ALength : Longint);
  2197. begin
  2198. Case AName of
  2199. 'items' : SetLength(Fitems,ALength);
  2200. else
  2201. Inherited SetArrayLength(AName,ALength);
  2202. end;
  2203. end;
  2204. {$ENDIF VER2_6}
  2205. { --------------------------------------------------------------------
  2206. TCustomChannelTypetargetingInfo
  2207. --------------------------------------------------------------------}
  2208. Procedure TCustomChannelTypetargetingInfo.SetadsAppearOn(AIndex : Integer; const AValue : String);
  2209. begin
  2210. If (FadsAppearOn=AValue) then exit;
  2211. FadsAppearOn:=AValue;
  2212. MarkPropertyChanged(AIndex);
  2213. end;
  2214. Procedure TCustomChannelTypetargetingInfo.Setdescription(AIndex : Integer; const AValue : String);
  2215. begin
  2216. If (Fdescription=AValue) then exit;
  2217. Fdescription:=AValue;
  2218. MarkPropertyChanged(AIndex);
  2219. end;
  2220. Procedure TCustomChannelTypetargetingInfo.Setlocation(AIndex : Integer; const AValue : String);
  2221. begin
  2222. If (Flocation=AValue) then exit;
  2223. Flocation:=AValue;
  2224. MarkPropertyChanged(AIndex);
  2225. end;
  2226. Procedure TCustomChannelTypetargetingInfo.SetsiteLanguage(AIndex : Integer; const AValue : String);
  2227. begin
  2228. If (FsiteLanguage=AValue) then exit;
  2229. FsiteLanguage:=AValue;
  2230. MarkPropertyChanged(AIndex);
  2231. end;
  2232. { --------------------------------------------------------------------
  2233. TCustomChannel
  2234. --------------------------------------------------------------------}
  2235. Procedure TCustomChannel.Setcode(AIndex : Integer; const AValue : String);
  2236. begin
  2237. If (Fcode=AValue) then exit;
  2238. Fcode:=AValue;
  2239. MarkPropertyChanged(AIndex);
  2240. end;
  2241. Procedure TCustomChannel.Setid(AIndex : Integer; const AValue : String);
  2242. begin
  2243. If (Fid=AValue) then exit;
  2244. Fid:=AValue;
  2245. MarkPropertyChanged(AIndex);
  2246. end;
  2247. Procedure TCustomChannel.Setkind(AIndex : Integer; const AValue : String);
  2248. begin
  2249. If (Fkind=AValue) then exit;
  2250. Fkind:=AValue;
  2251. MarkPropertyChanged(AIndex);
  2252. end;
  2253. Procedure TCustomChannel.Setname(AIndex : Integer; const AValue : String);
  2254. begin
  2255. If (Fname=AValue) then exit;
  2256. Fname:=AValue;
  2257. MarkPropertyChanged(AIndex);
  2258. end;
  2259. Procedure TCustomChannel.SettargetingInfo(AIndex : Integer; const AValue : TCustomChannelTypetargetingInfo);
  2260. begin
  2261. If (FtargetingInfo=AValue) then exit;
  2262. FtargetingInfo:=AValue;
  2263. MarkPropertyChanged(AIndex);
  2264. end;
  2265. { --------------------------------------------------------------------
  2266. TCustomChannels
  2267. --------------------------------------------------------------------}
  2268. Procedure TCustomChannels.Setetag(AIndex : Integer; const AValue : String);
  2269. begin
  2270. If (Fetag=AValue) then exit;
  2271. Fetag:=AValue;
  2272. MarkPropertyChanged(AIndex);
  2273. end;
  2274. Procedure TCustomChannels.Setitems(AIndex : Integer; const AValue : TCustomChannelsTypeitemsArray);
  2275. begin
  2276. If (Fitems=AValue) then exit;
  2277. Fitems:=AValue;
  2278. MarkPropertyChanged(AIndex);
  2279. end;
  2280. Procedure TCustomChannels.Setkind(AIndex : Integer; const AValue : String);
  2281. begin
  2282. If (Fkind=AValue) then exit;
  2283. Fkind:=AValue;
  2284. MarkPropertyChanged(AIndex);
  2285. end;
  2286. Procedure TCustomChannels.SetnextPageToken(AIndex : Integer; const AValue : String);
  2287. begin
  2288. If (FnextPageToken=AValue) then exit;
  2289. FnextPageToken:=AValue;
  2290. MarkPropertyChanged(AIndex);
  2291. end;
  2292. //2.6.4. bug workaround
  2293. {$IFDEF VER2_6}
  2294. Procedure TCustomChannels.SetArrayLength(Const AName : String; ALength : Longint);
  2295. begin
  2296. Case AName of
  2297. 'items' : SetLength(Fitems,ALength);
  2298. else
  2299. Inherited SetArrayLength(AName,ALength);
  2300. end;
  2301. end;
  2302. {$ENDIF VER2_6}
  2303. { --------------------------------------------------------------------
  2304. TMetadata
  2305. --------------------------------------------------------------------}
  2306. Procedure TMetadata.Setitems(AIndex : Integer; const AValue : TMetadataTypeitemsArray);
  2307. begin
  2308. If (Fitems=AValue) then exit;
  2309. Fitems:=AValue;
  2310. MarkPropertyChanged(AIndex);
  2311. end;
  2312. Procedure TMetadata.Setkind(AIndex : Integer; const AValue : String);
  2313. begin
  2314. If (Fkind=AValue) then exit;
  2315. Fkind:=AValue;
  2316. MarkPropertyChanged(AIndex);
  2317. end;
  2318. //2.6.4. bug workaround
  2319. {$IFDEF VER2_6}
  2320. Procedure TMetadata.SetArrayLength(Const AName : String; ALength : Longint);
  2321. begin
  2322. Case AName of
  2323. 'items' : SetLength(Fitems,ALength);
  2324. else
  2325. Inherited SetArrayLength(AName,ALength);
  2326. end;
  2327. end;
  2328. {$ENDIF VER2_6}
  2329. { --------------------------------------------------------------------
  2330. TPayment
  2331. --------------------------------------------------------------------}
  2332. Procedure TPayment.Setid(AIndex : Integer; const AValue : String);
  2333. begin
  2334. If (Fid=AValue) then exit;
  2335. Fid:=AValue;
  2336. MarkPropertyChanged(AIndex);
  2337. end;
  2338. Procedure TPayment.Setkind(AIndex : Integer; const AValue : String);
  2339. begin
  2340. If (Fkind=AValue) then exit;
  2341. Fkind:=AValue;
  2342. MarkPropertyChanged(AIndex);
  2343. end;
  2344. Procedure TPayment.SetpaymentAmount(AIndex : Integer; const AValue : String);
  2345. begin
  2346. If (FpaymentAmount=AValue) then exit;
  2347. FpaymentAmount:=AValue;
  2348. MarkPropertyChanged(AIndex);
  2349. end;
  2350. Procedure TPayment.SetpaymentAmountCurrencyCode(AIndex : Integer; const AValue : String);
  2351. begin
  2352. If (FpaymentAmountCurrencyCode=AValue) then exit;
  2353. FpaymentAmountCurrencyCode:=AValue;
  2354. MarkPropertyChanged(AIndex);
  2355. end;
  2356. Procedure TPayment.SetpaymentDate(AIndex : Integer; const AValue : String);
  2357. begin
  2358. If (FpaymentDate=AValue) then exit;
  2359. FpaymentDate:=AValue;
  2360. MarkPropertyChanged(AIndex);
  2361. end;
  2362. { --------------------------------------------------------------------
  2363. TPayments
  2364. --------------------------------------------------------------------}
  2365. Procedure TPayments.Setitems(AIndex : Integer; const AValue : TPaymentsTypeitemsArray);
  2366. begin
  2367. If (Fitems=AValue) then exit;
  2368. Fitems:=AValue;
  2369. MarkPropertyChanged(AIndex);
  2370. end;
  2371. Procedure TPayments.Setkind(AIndex : Integer; const AValue : String);
  2372. begin
  2373. If (Fkind=AValue) then exit;
  2374. Fkind:=AValue;
  2375. MarkPropertyChanged(AIndex);
  2376. end;
  2377. //2.6.4. bug workaround
  2378. {$IFDEF VER2_6}
  2379. Procedure TPayments.SetArrayLength(Const AName : String; ALength : Longint);
  2380. begin
  2381. Case AName of
  2382. 'items' : SetLength(Fitems,ALength);
  2383. else
  2384. Inherited SetArrayLength(AName,ALength);
  2385. end;
  2386. end;
  2387. {$ENDIF VER2_6}
  2388. { --------------------------------------------------------------------
  2389. TReportingMetadataEntry
  2390. --------------------------------------------------------------------}
  2391. Procedure TReportingMetadataEntry.SetcompatibleDimensions(AIndex : Integer; const AValue : TStringArray);
  2392. begin
  2393. If (FcompatibleDimensions=AValue) then exit;
  2394. FcompatibleDimensions:=AValue;
  2395. MarkPropertyChanged(AIndex);
  2396. end;
  2397. Procedure TReportingMetadataEntry.SetcompatibleMetrics(AIndex : Integer; const AValue : TStringArray);
  2398. begin
  2399. If (FcompatibleMetrics=AValue) then exit;
  2400. FcompatibleMetrics:=AValue;
  2401. MarkPropertyChanged(AIndex);
  2402. end;
  2403. Procedure TReportingMetadataEntry.Setid(AIndex : Integer; const AValue : String);
  2404. begin
  2405. If (Fid=AValue) then exit;
  2406. Fid:=AValue;
  2407. MarkPropertyChanged(AIndex);
  2408. end;
  2409. Procedure TReportingMetadataEntry.Setkind(AIndex : Integer; const AValue : String);
  2410. begin
  2411. If (Fkind=AValue) then exit;
  2412. Fkind:=AValue;
  2413. MarkPropertyChanged(AIndex);
  2414. end;
  2415. Procedure TReportingMetadataEntry.SetrequiredDimensions(AIndex : Integer; const AValue : TStringArray);
  2416. begin
  2417. If (FrequiredDimensions=AValue) then exit;
  2418. FrequiredDimensions:=AValue;
  2419. MarkPropertyChanged(AIndex);
  2420. end;
  2421. Procedure TReportingMetadataEntry.SetrequiredMetrics(AIndex : Integer; const AValue : TStringArray);
  2422. begin
  2423. If (FrequiredMetrics=AValue) then exit;
  2424. FrequiredMetrics:=AValue;
  2425. MarkPropertyChanged(AIndex);
  2426. end;
  2427. Procedure TReportingMetadataEntry.SetsupportedProducts(AIndex : Integer; const AValue : TStringArray);
  2428. begin
  2429. If (FsupportedProducts=AValue) then exit;
  2430. FsupportedProducts:=AValue;
  2431. MarkPropertyChanged(AIndex);
  2432. end;
  2433. //2.6.4. bug workaround
  2434. {$IFDEF VER2_6}
  2435. Procedure TReportingMetadataEntry.SetArrayLength(Const AName : String; ALength : Longint);
  2436. begin
  2437. Case AName of
  2438. 'compatibledimensions' : SetLength(FcompatibleDimensions,ALength);
  2439. 'compatiblemetrics' : SetLength(FcompatibleMetrics,ALength);
  2440. 'requireddimensions' : SetLength(FrequiredDimensions,ALength);
  2441. 'requiredmetrics' : SetLength(FrequiredMetrics,ALength);
  2442. 'supportedproducts' : SetLength(FsupportedProducts,ALength);
  2443. else
  2444. Inherited SetArrayLength(AName,ALength);
  2445. end;
  2446. end;
  2447. {$ENDIF VER2_6}
  2448. { --------------------------------------------------------------------
  2449. TSavedAdStyle
  2450. --------------------------------------------------------------------}
  2451. Procedure TSavedAdStyle.SetadStyle(AIndex : Integer; const AValue : TAdStyle);
  2452. begin
  2453. If (FadStyle=AValue) then exit;
  2454. FadStyle:=AValue;
  2455. MarkPropertyChanged(AIndex);
  2456. end;
  2457. Procedure TSavedAdStyle.Setid(AIndex : Integer; const AValue : String);
  2458. begin
  2459. If (Fid=AValue) then exit;
  2460. Fid:=AValue;
  2461. MarkPropertyChanged(AIndex);
  2462. end;
  2463. Procedure TSavedAdStyle.Setkind(AIndex : Integer; const AValue : String);
  2464. begin
  2465. If (Fkind=AValue) then exit;
  2466. Fkind:=AValue;
  2467. MarkPropertyChanged(AIndex);
  2468. end;
  2469. Procedure TSavedAdStyle.Setname(AIndex : Integer; const AValue : String);
  2470. begin
  2471. If (Fname=AValue) then exit;
  2472. Fname:=AValue;
  2473. MarkPropertyChanged(AIndex);
  2474. end;
  2475. { --------------------------------------------------------------------
  2476. TSavedAdStyles
  2477. --------------------------------------------------------------------}
  2478. Procedure TSavedAdStyles.Setetag(AIndex : Integer; const AValue : String);
  2479. begin
  2480. If (Fetag=AValue) then exit;
  2481. Fetag:=AValue;
  2482. MarkPropertyChanged(AIndex);
  2483. end;
  2484. Procedure TSavedAdStyles.Setitems(AIndex : Integer; const AValue : TSavedAdStylesTypeitemsArray);
  2485. begin
  2486. If (Fitems=AValue) then exit;
  2487. Fitems:=AValue;
  2488. MarkPropertyChanged(AIndex);
  2489. end;
  2490. Procedure TSavedAdStyles.Setkind(AIndex : Integer; const AValue : String);
  2491. begin
  2492. If (Fkind=AValue) then exit;
  2493. Fkind:=AValue;
  2494. MarkPropertyChanged(AIndex);
  2495. end;
  2496. Procedure TSavedAdStyles.SetnextPageToken(AIndex : Integer; const AValue : String);
  2497. begin
  2498. If (FnextPageToken=AValue) then exit;
  2499. FnextPageToken:=AValue;
  2500. MarkPropertyChanged(AIndex);
  2501. end;
  2502. //2.6.4. bug workaround
  2503. {$IFDEF VER2_6}
  2504. Procedure TSavedAdStyles.SetArrayLength(Const AName : String; ALength : Longint);
  2505. begin
  2506. Case AName of
  2507. 'items' : SetLength(Fitems,ALength);
  2508. else
  2509. Inherited SetArrayLength(AName,ALength);
  2510. end;
  2511. end;
  2512. {$ENDIF VER2_6}
  2513. { --------------------------------------------------------------------
  2514. TSavedReport
  2515. --------------------------------------------------------------------}
  2516. Procedure TSavedReport.Setid(AIndex : Integer; const AValue : String);
  2517. begin
  2518. If (Fid=AValue) then exit;
  2519. Fid:=AValue;
  2520. MarkPropertyChanged(AIndex);
  2521. end;
  2522. Procedure TSavedReport.Setkind(AIndex : Integer; const AValue : String);
  2523. begin
  2524. If (Fkind=AValue) then exit;
  2525. Fkind:=AValue;
  2526. MarkPropertyChanged(AIndex);
  2527. end;
  2528. Procedure TSavedReport.Setname(AIndex : Integer; const AValue : String);
  2529. begin
  2530. If (Fname=AValue) then exit;
  2531. Fname:=AValue;
  2532. MarkPropertyChanged(AIndex);
  2533. end;
  2534. { --------------------------------------------------------------------
  2535. TSavedReports
  2536. --------------------------------------------------------------------}
  2537. Procedure TSavedReports.Setetag(AIndex : Integer; const AValue : String);
  2538. begin
  2539. If (Fetag=AValue) then exit;
  2540. Fetag:=AValue;
  2541. MarkPropertyChanged(AIndex);
  2542. end;
  2543. Procedure TSavedReports.Setitems(AIndex : Integer; const AValue : TSavedReportsTypeitemsArray);
  2544. begin
  2545. If (Fitems=AValue) then exit;
  2546. Fitems:=AValue;
  2547. MarkPropertyChanged(AIndex);
  2548. end;
  2549. Procedure TSavedReports.Setkind(AIndex : Integer; const AValue : String);
  2550. begin
  2551. If (Fkind=AValue) then exit;
  2552. Fkind:=AValue;
  2553. MarkPropertyChanged(AIndex);
  2554. end;
  2555. Procedure TSavedReports.SetnextPageToken(AIndex : Integer; const AValue : String);
  2556. begin
  2557. If (FnextPageToken=AValue) then exit;
  2558. FnextPageToken:=AValue;
  2559. MarkPropertyChanged(AIndex);
  2560. end;
  2561. //2.6.4. bug workaround
  2562. {$IFDEF VER2_6}
  2563. Procedure TSavedReports.SetArrayLength(Const AName : String; ALength : Longint);
  2564. begin
  2565. Case AName of
  2566. 'items' : SetLength(Fitems,ALength);
  2567. else
  2568. Inherited SetArrayLength(AName,ALength);
  2569. end;
  2570. end;
  2571. {$ENDIF VER2_6}
  2572. { --------------------------------------------------------------------
  2573. TUrlChannel
  2574. --------------------------------------------------------------------}
  2575. Procedure TUrlChannel.Setid(AIndex : Integer; const AValue : String);
  2576. begin
  2577. If (Fid=AValue) then exit;
  2578. Fid:=AValue;
  2579. MarkPropertyChanged(AIndex);
  2580. end;
  2581. Procedure TUrlChannel.Setkind(AIndex : Integer; const AValue : String);
  2582. begin
  2583. If (Fkind=AValue) then exit;
  2584. Fkind:=AValue;
  2585. MarkPropertyChanged(AIndex);
  2586. end;
  2587. Procedure TUrlChannel.SeturlPattern(AIndex : Integer; const AValue : String);
  2588. begin
  2589. If (FurlPattern=AValue) then exit;
  2590. FurlPattern:=AValue;
  2591. MarkPropertyChanged(AIndex);
  2592. end;
  2593. { --------------------------------------------------------------------
  2594. TUrlChannels
  2595. --------------------------------------------------------------------}
  2596. Procedure TUrlChannels.Setetag(AIndex : Integer; const AValue : String);
  2597. begin
  2598. If (Fetag=AValue) then exit;
  2599. Fetag:=AValue;
  2600. MarkPropertyChanged(AIndex);
  2601. end;
  2602. Procedure TUrlChannels.Setitems(AIndex : Integer; const AValue : TUrlChannelsTypeitemsArray);
  2603. begin
  2604. If (Fitems=AValue) then exit;
  2605. Fitems:=AValue;
  2606. MarkPropertyChanged(AIndex);
  2607. end;
  2608. Procedure TUrlChannels.Setkind(AIndex : Integer; const AValue : String);
  2609. begin
  2610. If (Fkind=AValue) then exit;
  2611. Fkind:=AValue;
  2612. MarkPropertyChanged(AIndex);
  2613. end;
  2614. Procedure TUrlChannels.SetnextPageToken(AIndex : Integer; const AValue : String);
  2615. begin
  2616. If (FnextPageToken=AValue) then exit;
  2617. FnextPageToken:=AValue;
  2618. MarkPropertyChanged(AIndex);
  2619. end;
  2620. //2.6.4. bug workaround
  2621. {$IFDEF VER2_6}
  2622. Procedure TUrlChannels.SetArrayLength(Const AName : String; ALength : Longint);
  2623. begin
  2624. Case AName of
  2625. 'items' : SetLength(Fitems,ALength);
  2626. else
  2627. Inherited SetArrayLength(AName,ALength);
  2628. end;
  2629. end;
  2630. {$ENDIF VER2_6}
  2631. { --------------------------------------------------------------------
  2632. TAccountsAdclientsResource
  2633. --------------------------------------------------------------------}
  2634. Class Function TAccountsAdclientsResource.ResourceName : String;
  2635. begin
  2636. Result:='adclients';
  2637. end;
  2638. Class Function TAccountsAdclientsResource.DefaultAPI : TGoogleAPIClass;
  2639. begin
  2640. Result:=TadsenseAPI;
  2641. end;
  2642. Function TAccountsAdclientsResource.List(accountId: string; AQuery : string = '') : TAdClients;
  2643. Const
  2644. _HTTPMethod = 'GET';
  2645. _Path = 'accounts/{accountId}/adclients';
  2646. _Methodid = 'adsense.accounts.adclients.list';
  2647. Var
  2648. _P : String;
  2649. begin
  2650. _P:=SubstitutePath(_Path,['accountId',accountId]);
  2651. Result:=ServiceCall(_HTTPMethod,_P,AQuery,Nil,TAdClients) as TAdClients;
  2652. end;
  2653. Function TAccountsAdclientsResource.List(accountId: string; AQuery : TAccountsAdclientslistOptions) : TAdClients;
  2654. Var
  2655. _Q : String;
  2656. begin
  2657. _Q:='';
  2658. AddToQuery(_Q,'maxResults',AQuery.maxResults);
  2659. AddToQuery(_Q,'pageToken',AQuery.pageToken);
  2660. Result:=List(accountId,_Q);
  2661. end;
  2662. { --------------------------------------------------------------------
  2663. TAccountsAdunitsCustomchannelsResource
  2664. --------------------------------------------------------------------}
  2665. Class Function TAccountsAdunitsCustomchannelsResource.ResourceName : String;
  2666. begin
  2667. Result:='customchannels';
  2668. end;
  2669. Class Function TAccountsAdunitsCustomchannelsResource.DefaultAPI : TGoogleAPIClass;
  2670. begin
  2671. Result:=TadsenseAPI;
  2672. end;
  2673. Function TAccountsAdunitsCustomchannelsResource.List(accountId: string; adClientId: string; adUnitId: string; AQuery : string = '') : TCustomChannels;
  2674. Const
  2675. _HTTPMethod = 'GET';
  2676. _Path = 'accounts/{accountId}/adclients/{adClientId}/adunits/{adUnitId}/customchannels';
  2677. _Methodid = 'adsense.accounts.adunits.customchannels.list';
  2678. Var
  2679. _P : String;
  2680. begin
  2681. _P:=SubstitutePath(_Path,['accountId',accountId,'adClientId',adClientId,'adUnitId',adUnitId]);
  2682. Result:=ServiceCall(_HTTPMethod,_P,AQuery,Nil,TCustomChannels) as TCustomChannels;
  2683. end;
  2684. Function TAccountsAdunitsCustomchannelsResource.List(accountId: string; adClientId: string; adUnitId: string; AQuery : TAccountsAdunitsCustomchannelslistOptions) : TCustomChannels;
  2685. Var
  2686. _Q : String;
  2687. begin
  2688. _Q:='';
  2689. AddToQuery(_Q,'maxResults',AQuery.maxResults);
  2690. AddToQuery(_Q,'pageToken',AQuery.pageToken);
  2691. Result:=List(accountId,adClientId,adUnitId,_Q);
  2692. end;
  2693. { --------------------------------------------------------------------
  2694. TAccountsAdunitsResource
  2695. --------------------------------------------------------------------}
  2696. Class Function TAccountsAdunitsResource.ResourceName : String;
  2697. begin
  2698. Result:='adunits';
  2699. end;
  2700. Class Function TAccountsAdunitsResource.DefaultAPI : TGoogleAPIClass;
  2701. begin
  2702. Result:=TadsenseAPI;
  2703. end;
  2704. Function TAccountsAdunitsResource.Get(accountId: string; adClientId: string; adUnitId: string) : TAdUnit;
  2705. Const
  2706. _HTTPMethod = 'GET';
  2707. _Path = 'accounts/{accountId}/adclients/{adClientId}/adunits/{adUnitId}';
  2708. _Methodid = 'adsense.accounts.adunits.get';
  2709. Var
  2710. _P : String;
  2711. begin
  2712. _P:=SubstitutePath(_Path,['accountId',accountId,'adClientId',adClientId,'adUnitId',adUnitId]);
  2713. Result:=ServiceCall(_HTTPMethod,_P,'',Nil,TAdUnit) as TAdUnit;
  2714. end;
  2715. Function TAccountsAdunitsResource.GetAdCode(accountId: string; adClientId: string; adUnitId: string) : TAdCode;
  2716. Const
  2717. _HTTPMethod = 'GET';
  2718. _Path = 'accounts/{accountId}/adclients/{adClientId}/adunits/{adUnitId}/adcode';
  2719. _Methodid = 'adsense.accounts.adunits.getAdCode';
  2720. Var
  2721. _P : String;
  2722. begin
  2723. _P:=SubstitutePath(_Path,['accountId',accountId,'adClientId',adClientId,'adUnitId',adUnitId]);
  2724. Result:=ServiceCall(_HTTPMethod,_P,'',Nil,TAdCode) as TAdCode;
  2725. end;
  2726. Function TAccountsAdunitsResource.List(accountId: string; adClientId: string; AQuery : string = '') : TAdUnits;
  2727. Const
  2728. _HTTPMethod = 'GET';
  2729. _Path = 'accounts/{accountId}/adclients/{adClientId}/adunits';
  2730. _Methodid = 'adsense.accounts.adunits.list';
  2731. Var
  2732. _P : String;
  2733. begin
  2734. _P:=SubstitutePath(_Path,['accountId',accountId,'adClientId',adClientId]);
  2735. Result:=ServiceCall(_HTTPMethod,_P,AQuery,Nil,TAdUnits) as TAdUnits;
  2736. end;
  2737. Function TAccountsAdunitsResource.List(accountId: string; adClientId: string; AQuery : TAccountsAdunitslistOptions) : TAdUnits;
  2738. Var
  2739. _Q : String;
  2740. begin
  2741. _Q:='';
  2742. AddToQuery(_Q,'includeInactive',AQuery.includeInactive);
  2743. AddToQuery(_Q,'maxResults',AQuery.maxResults);
  2744. AddToQuery(_Q,'pageToken',AQuery.pageToken);
  2745. Result:=List(accountId,adClientId,_Q);
  2746. end;
  2747. Function TAccountsAdunitsResource.GetCustomchannelsInstance : TAccountsAdunitsCustomchannelsResource;
  2748. begin
  2749. if (FCustomchannelsInstance=Nil) then
  2750. FCustomchannelsInstance:=CreateCustomchannelsResource;
  2751. Result:=FCustomchannelsInstance;
  2752. end;
  2753. Function TAccountsAdunitsResource.CreateCustomchannelsResource : TAccountsAdunitsCustomchannelsResource;
  2754. begin
  2755. Result:=CreateCustomchannelsResource(Self);
  2756. end;
  2757. Function TAccountsAdunitsResource.CreateCustomchannelsResource(AOwner : TComponent) : TAccountsAdunitsCustomchannelsResource;
  2758. begin
  2759. Result:=TAccountsAdunitsCustomchannelsResource.Create(AOwner);
  2760. Result.API:=Self.API;
  2761. end;
  2762. { --------------------------------------------------------------------
  2763. TAccountsAlertsResource
  2764. --------------------------------------------------------------------}
  2765. Class Function TAccountsAlertsResource.ResourceName : String;
  2766. begin
  2767. Result:='alerts';
  2768. end;
  2769. Class Function TAccountsAlertsResource.DefaultAPI : TGoogleAPIClass;
  2770. begin
  2771. Result:=TadsenseAPI;
  2772. end;
  2773. Procedure TAccountsAlertsResource.Delete(accountId: string; alertId: string);
  2774. Const
  2775. _HTTPMethod = 'DELETE';
  2776. _Path = 'accounts/{accountId}/alerts/{alertId}';
  2777. _Methodid = 'adsense.accounts.alerts.delete';
  2778. Var
  2779. _P : String;
  2780. begin
  2781. _P:=SubstitutePath(_Path,['accountId',accountId,'alertId',alertId]);
  2782. ServiceCall(_HTTPMethod,_P,'',Nil,Nil);
  2783. end;
  2784. Function TAccountsAlertsResource.List(accountId: string; AQuery : string = '') : TAlerts;
  2785. Const
  2786. _HTTPMethod = 'GET';
  2787. _Path = 'accounts/{accountId}/alerts';
  2788. _Methodid = 'adsense.accounts.alerts.list';
  2789. Var
  2790. _P : String;
  2791. begin
  2792. _P:=SubstitutePath(_Path,['accountId',accountId]);
  2793. Result:=ServiceCall(_HTTPMethod,_P,AQuery,Nil,TAlerts) as TAlerts;
  2794. end;
  2795. Function TAccountsAlertsResource.List(accountId: string; AQuery : TAccountsAlertslistOptions) : TAlerts;
  2796. Var
  2797. _Q : String;
  2798. begin
  2799. _Q:='';
  2800. AddToQuery(_Q,'locale',AQuery.locale);
  2801. Result:=List(accountId,_Q);
  2802. end;
  2803. { --------------------------------------------------------------------
  2804. TAccountsCustomchannelsAdunitsResource
  2805. --------------------------------------------------------------------}
  2806. Class Function TAccountsCustomchannelsAdunitsResource.ResourceName : String;
  2807. begin
  2808. Result:='adunits';
  2809. end;
  2810. Class Function TAccountsCustomchannelsAdunitsResource.DefaultAPI : TGoogleAPIClass;
  2811. begin
  2812. Result:=TadsenseAPI;
  2813. end;
  2814. Function TAccountsCustomchannelsAdunitsResource.List(accountId: string; adClientId: string; customChannelId: string; AQuery : string = '') : TAdUnits;
  2815. Const
  2816. _HTTPMethod = 'GET';
  2817. _Path = 'accounts/{accountId}/adclients/{adClientId}/customchannels/{customChannelId}/adunits';
  2818. _Methodid = 'adsense.accounts.customchannels.adunits.list';
  2819. Var
  2820. _P : String;
  2821. begin
  2822. _P:=SubstitutePath(_Path,['accountId',accountId,'adClientId',adClientId,'customChannelId',customChannelId]);
  2823. Result:=ServiceCall(_HTTPMethod,_P,AQuery,Nil,TAdUnits) as TAdUnits;
  2824. end;
  2825. Function TAccountsCustomchannelsAdunitsResource.List(accountId: string; adClientId: string; customChannelId: string; AQuery : TAccountsCustomchannelsAdunitslistOptions) : TAdUnits;
  2826. Var
  2827. _Q : String;
  2828. begin
  2829. _Q:='';
  2830. AddToQuery(_Q,'includeInactive',AQuery.includeInactive);
  2831. AddToQuery(_Q,'maxResults',AQuery.maxResults);
  2832. AddToQuery(_Q,'pageToken',AQuery.pageToken);
  2833. Result:=List(accountId,adClientId,customChannelId,_Q);
  2834. end;
  2835. { --------------------------------------------------------------------
  2836. TAccountsCustomchannelsResource
  2837. --------------------------------------------------------------------}
  2838. Class Function TAccountsCustomchannelsResource.ResourceName : String;
  2839. begin
  2840. Result:='customchannels';
  2841. end;
  2842. Class Function TAccountsCustomchannelsResource.DefaultAPI : TGoogleAPIClass;
  2843. begin
  2844. Result:=TadsenseAPI;
  2845. end;
  2846. Function TAccountsCustomchannelsResource.Get(accountId: string; adClientId: string; customChannelId: string) : TCustomChannel;
  2847. Const
  2848. _HTTPMethod = 'GET';
  2849. _Path = 'accounts/{accountId}/adclients/{adClientId}/customchannels/{customChannelId}';
  2850. _Methodid = 'adsense.accounts.customchannels.get';
  2851. Var
  2852. _P : String;
  2853. begin
  2854. _P:=SubstitutePath(_Path,['accountId',accountId,'adClientId',adClientId,'customChannelId',customChannelId]);
  2855. Result:=ServiceCall(_HTTPMethod,_P,'',Nil,TCustomChannel) as TCustomChannel;
  2856. end;
  2857. Function TAccountsCustomchannelsResource.List(accountId: string; adClientId: string; AQuery : string = '') : TCustomChannels;
  2858. Const
  2859. _HTTPMethod = 'GET';
  2860. _Path = 'accounts/{accountId}/adclients/{adClientId}/customchannels';
  2861. _Methodid = 'adsense.accounts.customchannels.list';
  2862. Var
  2863. _P : String;
  2864. begin
  2865. _P:=SubstitutePath(_Path,['accountId',accountId,'adClientId',adClientId]);
  2866. Result:=ServiceCall(_HTTPMethod,_P,AQuery,Nil,TCustomChannels) as TCustomChannels;
  2867. end;
  2868. Function TAccountsCustomchannelsResource.List(accountId: string; adClientId: string; AQuery : TAccountsCustomchannelslistOptions) : TCustomChannels;
  2869. Var
  2870. _Q : String;
  2871. begin
  2872. _Q:='';
  2873. AddToQuery(_Q,'maxResults',AQuery.maxResults);
  2874. AddToQuery(_Q,'pageToken',AQuery.pageToken);
  2875. Result:=List(accountId,adClientId,_Q);
  2876. end;
  2877. Function TAccountsCustomchannelsResource.GetAdunitsInstance : TAccountsCustomchannelsAdunitsResource;
  2878. begin
  2879. if (FAdunitsInstance=Nil) then
  2880. FAdunitsInstance:=CreateAdunitsResource;
  2881. Result:=FAdunitsInstance;
  2882. end;
  2883. Function TAccountsCustomchannelsResource.CreateAdunitsResource : TAccountsCustomchannelsAdunitsResource;
  2884. begin
  2885. Result:=CreateAdunitsResource(Self);
  2886. end;
  2887. Function TAccountsCustomchannelsResource.CreateAdunitsResource(AOwner : TComponent) : TAccountsCustomchannelsAdunitsResource;
  2888. begin
  2889. Result:=TAccountsCustomchannelsAdunitsResource.Create(AOwner);
  2890. Result.API:=Self.API;
  2891. end;
  2892. { --------------------------------------------------------------------
  2893. TAccountsPaymentsResource
  2894. --------------------------------------------------------------------}
  2895. Class Function TAccountsPaymentsResource.ResourceName : String;
  2896. begin
  2897. Result:='payments';
  2898. end;
  2899. Class Function TAccountsPaymentsResource.DefaultAPI : TGoogleAPIClass;
  2900. begin
  2901. Result:=TadsenseAPI;
  2902. end;
  2903. Function TAccountsPaymentsResource.List(accountId: string) : TPayments;
  2904. Const
  2905. _HTTPMethod = 'GET';
  2906. _Path = 'accounts/{accountId}/payments';
  2907. _Methodid = 'adsense.accounts.payments.list';
  2908. Var
  2909. _P : String;
  2910. begin
  2911. _P:=SubstitutePath(_Path,['accountId',accountId]);
  2912. Result:=ServiceCall(_HTTPMethod,_P,'',Nil,TPayments) as TPayments;
  2913. end;
  2914. { --------------------------------------------------------------------
  2915. TAccountsReportsSavedResource
  2916. --------------------------------------------------------------------}
  2917. Class Function TAccountsReportsSavedResource.ResourceName : String;
  2918. begin
  2919. Result:='saved';
  2920. end;
  2921. Class Function TAccountsReportsSavedResource.DefaultAPI : TGoogleAPIClass;
  2922. begin
  2923. Result:=TadsenseAPI;
  2924. end;
  2925. Function TAccountsReportsSavedResource.Generate(accountId: string; savedReportId: string; AQuery : string = '') : TAdsenseReportsGenerateResponse;
  2926. Const
  2927. _HTTPMethod = 'GET';
  2928. _Path = 'accounts/{accountId}/reports/{savedReportId}';
  2929. _Methodid = 'adsense.accounts.reports.saved.generate';
  2930. Var
  2931. _P : String;
  2932. begin
  2933. _P:=SubstitutePath(_Path,['accountId',accountId,'savedReportId',savedReportId]);
  2934. Result:=ServiceCall(_HTTPMethod,_P,AQuery,Nil,TAdsenseReportsGenerateResponse) as TAdsenseReportsGenerateResponse;
  2935. end;
  2936. Function TAccountsReportsSavedResource.Generate(accountId: string; savedReportId: string; AQuery : TAccountsReportsSavedgenerateOptions) : TAdsenseReportsGenerateResponse;
  2937. Var
  2938. _Q : String;
  2939. begin
  2940. _Q:='';
  2941. AddToQuery(_Q,'locale',AQuery.locale);
  2942. AddToQuery(_Q,'maxResults',AQuery.maxResults);
  2943. AddToQuery(_Q,'startIndex',AQuery.startIndex);
  2944. Result:=Generate(accountId,savedReportId,_Q);
  2945. end;
  2946. Function TAccountsReportsSavedResource.List(accountId: string; AQuery : string = '') : TSavedReports;
  2947. Const
  2948. _HTTPMethod = 'GET';
  2949. _Path = 'accounts/{accountId}/reports/saved';
  2950. _Methodid = 'adsense.accounts.reports.saved.list';
  2951. Var
  2952. _P : String;
  2953. begin
  2954. _P:=SubstitutePath(_Path,['accountId',accountId]);
  2955. Result:=ServiceCall(_HTTPMethod,_P,AQuery,Nil,TSavedReports) as TSavedReports;
  2956. end;
  2957. Function TAccountsReportsSavedResource.List(accountId: string; AQuery : TAccountsReportsSavedlistOptions) : TSavedReports;
  2958. Var
  2959. _Q : String;
  2960. begin
  2961. _Q:='';
  2962. AddToQuery(_Q,'maxResults',AQuery.maxResults);
  2963. AddToQuery(_Q,'pageToken',AQuery.pageToken);
  2964. Result:=List(accountId,_Q);
  2965. end;
  2966. { --------------------------------------------------------------------
  2967. TAccountsReportsResource
  2968. --------------------------------------------------------------------}
  2969. Class Function TAccountsReportsResource.ResourceName : String;
  2970. begin
  2971. Result:='reports';
  2972. end;
  2973. Class Function TAccountsReportsResource.DefaultAPI : TGoogleAPIClass;
  2974. begin
  2975. Result:=TadsenseAPI;
  2976. end;
  2977. Function TAccountsReportsResource.Generate(accountId: string; AQuery : string = '') : TAdsenseReportsGenerateResponse;
  2978. Const
  2979. _HTTPMethod = 'GET';
  2980. _Path = 'accounts/{accountId}/reports';
  2981. _Methodid = 'adsense.accounts.reports.generate';
  2982. Var
  2983. _P : String;
  2984. begin
  2985. _P:=SubstitutePath(_Path,['accountId',accountId]);
  2986. Result:=ServiceCall(_HTTPMethod,_P,AQuery,Nil,TAdsenseReportsGenerateResponse) as TAdsenseReportsGenerateResponse;
  2987. end;
  2988. Function TAccountsReportsResource.Generate(accountId: string; AQuery : TAccountsReportsgenerateOptions) : TAdsenseReportsGenerateResponse;
  2989. Var
  2990. _Q : String;
  2991. begin
  2992. _Q:='';
  2993. AddToQuery(_Q,'currency',AQuery.currency);
  2994. AddToQuery(_Q,'dimension',AQuery.dimension);
  2995. AddToQuery(_Q,'endDate',AQuery.endDate);
  2996. AddToQuery(_Q,'filter',AQuery.filter);
  2997. AddToQuery(_Q,'locale',AQuery.locale);
  2998. AddToQuery(_Q,'maxResults',AQuery.maxResults);
  2999. AddToQuery(_Q,'metric',AQuery.metric);
  3000. AddToQuery(_Q,'sort',AQuery.sort);
  3001. AddToQuery(_Q,'startDate',AQuery.startDate);
  3002. AddToQuery(_Q,'startIndex',AQuery.startIndex);
  3003. AddToQuery(_Q,'useTimezoneReporting',AQuery.useTimezoneReporting);
  3004. Result:=Generate(accountId,_Q);
  3005. end;
  3006. Function TAccountsReportsResource.GetSavedInstance : TAccountsReportsSavedResource;
  3007. begin
  3008. if (FSavedInstance=Nil) then
  3009. FSavedInstance:=CreateSavedResource;
  3010. Result:=FSavedInstance;
  3011. end;
  3012. Function TAccountsReportsResource.CreateSavedResource : TAccountsReportsSavedResource;
  3013. begin
  3014. Result:=CreateSavedResource(Self);
  3015. end;
  3016. Function TAccountsReportsResource.CreateSavedResource(AOwner : TComponent) : TAccountsReportsSavedResource;
  3017. begin
  3018. Result:=TAccountsReportsSavedResource.Create(AOwner);
  3019. Result.API:=Self.API;
  3020. end;
  3021. { --------------------------------------------------------------------
  3022. TAccountsSavedadstylesResource
  3023. --------------------------------------------------------------------}
  3024. Class Function TAccountsSavedadstylesResource.ResourceName : String;
  3025. begin
  3026. Result:='savedadstyles';
  3027. end;
  3028. Class Function TAccountsSavedadstylesResource.DefaultAPI : TGoogleAPIClass;
  3029. begin
  3030. Result:=TadsenseAPI;
  3031. end;
  3032. Function TAccountsSavedadstylesResource.Get(accountId: string; savedAdStyleId: string) : TSavedAdStyle;
  3033. Const
  3034. _HTTPMethod = 'GET';
  3035. _Path = 'accounts/{accountId}/savedadstyles/{savedAdStyleId}';
  3036. _Methodid = 'adsense.accounts.savedadstyles.get';
  3037. Var
  3038. _P : String;
  3039. begin
  3040. _P:=SubstitutePath(_Path,['accountId',accountId,'savedAdStyleId',savedAdStyleId]);
  3041. Result:=ServiceCall(_HTTPMethod,_P,'',Nil,TSavedAdStyle) as TSavedAdStyle;
  3042. end;
  3043. Function TAccountsSavedadstylesResource.List(accountId: string; AQuery : string = '') : TSavedAdStyles;
  3044. Const
  3045. _HTTPMethod = 'GET';
  3046. _Path = 'accounts/{accountId}/savedadstyles';
  3047. _Methodid = 'adsense.accounts.savedadstyles.list';
  3048. Var
  3049. _P : String;
  3050. begin
  3051. _P:=SubstitutePath(_Path,['accountId',accountId]);
  3052. Result:=ServiceCall(_HTTPMethod,_P,AQuery,Nil,TSavedAdStyles) as TSavedAdStyles;
  3053. end;
  3054. Function TAccountsSavedadstylesResource.List(accountId: string; AQuery : TAccountsSavedadstyleslistOptions) : TSavedAdStyles;
  3055. Var
  3056. _Q : String;
  3057. begin
  3058. _Q:='';
  3059. AddToQuery(_Q,'maxResults',AQuery.maxResults);
  3060. AddToQuery(_Q,'pageToken',AQuery.pageToken);
  3061. Result:=List(accountId,_Q);
  3062. end;
  3063. { --------------------------------------------------------------------
  3064. TAccountsUrlchannelsResource
  3065. --------------------------------------------------------------------}
  3066. Class Function TAccountsUrlchannelsResource.ResourceName : String;
  3067. begin
  3068. Result:='urlchannels';
  3069. end;
  3070. Class Function TAccountsUrlchannelsResource.DefaultAPI : TGoogleAPIClass;
  3071. begin
  3072. Result:=TadsenseAPI;
  3073. end;
  3074. Function TAccountsUrlchannelsResource.List(accountId: string; adClientId: string; AQuery : string = '') : TUrlChannels;
  3075. Const
  3076. _HTTPMethod = 'GET';
  3077. _Path = 'accounts/{accountId}/adclients/{adClientId}/urlchannels';
  3078. _Methodid = 'adsense.accounts.urlchannels.list';
  3079. Var
  3080. _P : String;
  3081. begin
  3082. _P:=SubstitutePath(_Path,['accountId',accountId,'adClientId',adClientId]);
  3083. Result:=ServiceCall(_HTTPMethod,_P,AQuery,Nil,TUrlChannels) as TUrlChannels;
  3084. end;
  3085. Function TAccountsUrlchannelsResource.List(accountId: string; adClientId: string; AQuery : TAccountsUrlchannelslistOptions) : TUrlChannels;
  3086. Var
  3087. _Q : String;
  3088. begin
  3089. _Q:='';
  3090. AddToQuery(_Q,'maxResults',AQuery.maxResults);
  3091. AddToQuery(_Q,'pageToken',AQuery.pageToken);
  3092. Result:=List(accountId,adClientId,_Q);
  3093. end;
  3094. { --------------------------------------------------------------------
  3095. TAccountsResource
  3096. --------------------------------------------------------------------}
  3097. Class Function TAccountsResource.ResourceName : String;
  3098. begin
  3099. Result:='accounts';
  3100. end;
  3101. Class Function TAccountsResource.DefaultAPI : TGoogleAPIClass;
  3102. begin
  3103. Result:=TadsenseAPI;
  3104. end;
  3105. Function TAccountsResource.Get(accountId: string; AQuery : string = '') : TAccount;
  3106. Const
  3107. _HTTPMethod = 'GET';
  3108. _Path = 'accounts/{accountId}';
  3109. _Methodid = 'adsense.accounts.get';
  3110. Var
  3111. _P : String;
  3112. begin
  3113. _P:=SubstitutePath(_Path,['accountId',accountId]);
  3114. Result:=ServiceCall(_HTTPMethod,_P,AQuery,Nil,TAccount) as TAccount;
  3115. end;
  3116. Function TAccountsResource.Get(accountId: string; AQuery : TAccountsgetOptions) : TAccount;
  3117. Var
  3118. _Q : String;
  3119. begin
  3120. _Q:='';
  3121. AddToQuery(_Q,'tree',AQuery.tree);
  3122. Result:=Get(accountId,_Q);
  3123. end;
  3124. Function TAccountsResource.List(AQuery : string = '') : TAccounts;
  3125. Const
  3126. _HTTPMethod = 'GET';
  3127. _Path = 'accounts';
  3128. _Methodid = 'adsense.accounts.list';
  3129. begin
  3130. Result:=ServiceCall(_HTTPMethod,_Path,AQuery,Nil,TAccounts) as TAccounts;
  3131. end;
  3132. Function TAccountsResource.List(AQuery : TAccountslistOptions) : TAccounts;
  3133. Var
  3134. _Q : String;
  3135. begin
  3136. _Q:='';
  3137. AddToQuery(_Q,'maxResults',AQuery.maxResults);
  3138. AddToQuery(_Q,'pageToken',AQuery.pageToken);
  3139. Result:=List(_Q);
  3140. end;
  3141. Function TAccountsResource.GetAdclientsInstance : TAccountsAdclientsResource;
  3142. begin
  3143. if (FAdclientsInstance=Nil) then
  3144. FAdclientsInstance:=CreateAdclientsResource;
  3145. Result:=FAdclientsInstance;
  3146. end;
  3147. Function TAccountsResource.CreateAdclientsResource : TAccountsAdclientsResource;
  3148. begin
  3149. Result:=CreateAdclientsResource(Self);
  3150. end;
  3151. Function TAccountsResource.CreateAdclientsResource(AOwner : TComponent) : TAccountsAdclientsResource;
  3152. begin
  3153. Result:=TAccountsAdclientsResource.Create(AOwner);
  3154. Result.API:=Self.API;
  3155. end;
  3156. Function TAccountsResource.GetAdunitsCustomchannelsInstance : TAccountsAdunitsCustomchannelsResource;
  3157. begin
  3158. if (FAdunitsCustomchannelsInstance=Nil) then
  3159. FAdunitsCustomchannelsInstance:=CreateAdunitsCustomchannelsResource;
  3160. Result:=FAdunitsCustomchannelsInstance;
  3161. end;
  3162. Function TAccountsResource.CreateAdunitsCustomchannelsResource : TAccountsAdunitsCustomchannelsResource;
  3163. begin
  3164. Result:=CreateAdunitsCustomchannelsResource(Self);
  3165. end;
  3166. Function TAccountsResource.CreateAdunitsCustomchannelsResource(AOwner : TComponent) : TAccountsAdunitsCustomchannelsResource;
  3167. begin
  3168. Result:=TAccountsAdunitsCustomchannelsResource.Create(AOwner);
  3169. Result.API:=Self.API;
  3170. end;
  3171. Function TAccountsResource.GetAdunitsInstance : TAccountsAdunitsResource;
  3172. begin
  3173. if (FAdunitsInstance=Nil) then
  3174. FAdunitsInstance:=CreateAdunitsResource;
  3175. Result:=FAdunitsInstance;
  3176. end;
  3177. Function TAccountsResource.CreateAdunitsResource : TAccountsAdunitsResource;
  3178. begin
  3179. Result:=CreateAdunitsResource(Self);
  3180. end;
  3181. Function TAccountsResource.CreateAdunitsResource(AOwner : TComponent) : TAccountsAdunitsResource;
  3182. begin
  3183. Result:=TAccountsAdunitsResource.Create(AOwner);
  3184. Result.API:=Self.API;
  3185. end;
  3186. Function TAccountsResource.GetAlertsInstance : TAccountsAlertsResource;
  3187. begin
  3188. if (FAlertsInstance=Nil) then
  3189. FAlertsInstance:=CreateAlertsResource;
  3190. Result:=FAlertsInstance;
  3191. end;
  3192. Function TAccountsResource.CreateAlertsResource : TAccountsAlertsResource;
  3193. begin
  3194. Result:=CreateAlertsResource(Self);
  3195. end;
  3196. Function TAccountsResource.CreateAlertsResource(AOwner : TComponent) : TAccountsAlertsResource;
  3197. begin
  3198. Result:=TAccountsAlertsResource.Create(AOwner);
  3199. Result.API:=Self.API;
  3200. end;
  3201. Function TAccountsResource.GetCustomchannelsAdunitsInstance : TAccountsCustomchannelsAdunitsResource;
  3202. begin
  3203. if (FCustomchannelsAdunitsInstance=Nil) then
  3204. FCustomchannelsAdunitsInstance:=CreateCustomchannelsAdunitsResource;
  3205. Result:=FCustomchannelsAdunitsInstance;
  3206. end;
  3207. Function TAccountsResource.CreateCustomchannelsAdunitsResource : TAccountsCustomchannelsAdunitsResource;
  3208. begin
  3209. Result:=CreateCustomchannelsAdunitsResource(Self);
  3210. end;
  3211. Function TAccountsResource.CreateCustomchannelsAdunitsResource(AOwner : TComponent) : TAccountsCustomchannelsAdunitsResource;
  3212. begin
  3213. Result:=TAccountsCustomchannelsAdunitsResource.Create(AOwner);
  3214. Result.API:=Self.API;
  3215. end;
  3216. Function TAccountsResource.GetCustomchannelsInstance : TAccountsCustomchannelsResource;
  3217. begin
  3218. if (FCustomchannelsInstance=Nil) then
  3219. FCustomchannelsInstance:=CreateCustomchannelsResource;
  3220. Result:=FCustomchannelsInstance;
  3221. end;
  3222. Function TAccountsResource.CreateCustomchannelsResource : TAccountsCustomchannelsResource;
  3223. begin
  3224. Result:=CreateCustomchannelsResource(Self);
  3225. end;
  3226. Function TAccountsResource.CreateCustomchannelsResource(AOwner : TComponent) : TAccountsCustomchannelsResource;
  3227. begin
  3228. Result:=TAccountsCustomchannelsResource.Create(AOwner);
  3229. Result.API:=Self.API;
  3230. end;
  3231. Function TAccountsResource.GetPaymentsInstance : TAccountsPaymentsResource;
  3232. begin
  3233. if (FPaymentsInstance=Nil) then
  3234. FPaymentsInstance:=CreatePaymentsResource;
  3235. Result:=FPaymentsInstance;
  3236. end;
  3237. Function TAccountsResource.CreatePaymentsResource : TAccountsPaymentsResource;
  3238. begin
  3239. Result:=CreatePaymentsResource(Self);
  3240. end;
  3241. Function TAccountsResource.CreatePaymentsResource(AOwner : TComponent) : TAccountsPaymentsResource;
  3242. begin
  3243. Result:=TAccountsPaymentsResource.Create(AOwner);
  3244. Result.API:=Self.API;
  3245. end;
  3246. Function TAccountsResource.GetReportsSavedInstance : TAccountsReportsSavedResource;
  3247. begin
  3248. if (FReportsSavedInstance=Nil) then
  3249. FReportsSavedInstance:=CreateReportsSavedResource;
  3250. Result:=FReportsSavedInstance;
  3251. end;
  3252. Function TAccountsResource.CreateReportsSavedResource : TAccountsReportsSavedResource;
  3253. begin
  3254. Result:=CreateReportsSavedResource(Self);
  3255. end;
  3256. Function TAccountsResource.CreateReportsSavedResource(AOwner : TComponent) : TAccountsReportsSavedResource;
  3257. begin
  3258. Result:=TAccountsReportsSavedResource.Create(AOwner);
  3259. Result.API:=Self.API;
  3260. end;
  3261. Function TAccountsResource.GetReportsInstance : TAccountsReportsResource;
  3262. begin
  3263. if (FReportsInstance=Nil) then
  3264. FReportsInstance:=CreateReportsResource;
  3265. Result:=FReportsInstance;
  3266. end;
  3267. Function TAccountsResource.CreateReportsResource : TAccountsReportsResource;
  3268. begin
  3269. Result:=CreateReportsResource(Self);
  3270. end;
  3271. Function TAccountsResource.CreateReportsResource(AOwner : TComponent) : TAccountsReportsResource;
  3272. begin
  3273. Result:=TAccountsReportsResource.Create(AOwner);
  3274. Result.API:=Self.API;
  3275. end;
  3276. Function TAccountsResource.GetSavedadstylesInstance : TAccountsSavedadstylesResource;
  3277. begin
  3278. if (FSavedadstylesInstance=Nil) then
  3279. FSavedadstylesInstance:=CreateSavedadstylesResource;
  3280. Result:=FSavedadstylesInstance;
  3281. end;
  3282. Function TAccountsResource.CreateSavedadstylesResource : TAccountsSavedadstylesResource;
  3283. begin
  3284. Result:=CreateSavedadstylesResource(Self);
  3285. end;
  3286. Function TAccountsResource.CreateSavedadstylesResource(AOwner : TComponent) : TAccountsSavedadstylesResource;
  3287. begin
  3288. Result:=TAccountsSavedadstylesResource.Create(AOwner);
  3289. Result.API:=Self.API;
  3290. end;
  3291. Function TAccountsResource.GetUrlchannelsInstance : TAccountsUrlchannelsResource;
  3292. begin
  3293. if (FUrlchannelsInstance=Nil) then
  3294. FUrlchannelsInstance:=CreateUrlchannelsResource;
  3295. Result:=FUrlchannelsInstance;
  3296. end;
  3297. Function TAccountsResource.CreateUrlchannelsResource : TAccountsUrlchannelsResource;
  3298. begin
  3299. Result:=CreateUrlchannelsResource(Self);
  3300. end;
  3301. Function TAccountsResource.CreateUrlchannelsResource(AOwner : TComponent) : TAccountsUrlchannelsResource;
  3302. begin
  3303. Result:=TAccountsUrlchannelsResource.Create(AOwner);
  3304. Result.API:=Self.API;
  3305. end;
  3306. { --------------------------------------------------------------------
  3307. TAdclientsResource
  3308. --------------------------------------------------------------------}
  3309. Class Function TAdclientsResource.ResourceName : String;
  3310. begin
  3311. Result:='adclients';
  3312. end;
  3313. Class Function TAdclientsResource.DefaultAPI : TGoogleAPIClass;
  3314. begin
  3315. Result:=TadsenseAPI;
  3316. end;
  3317. Function TAdclientsResource.List(AQuery : string = '') : TAdClients;
  3318. Const
  3319. _HTTPMethod = 'GET';
  3320. _Path = 'adclients';
  3321. _Methodid = 'adsense.adclients.list';
  3322. begin
  3323. Result:=ServiceCall(_HTTPMethod,_Path,AQuery,Nil,TAdClients) as TAdClients;
  3324. end;
  3325. Function TAdclientsResource.List(AQuery : TAdclientslistOptions) : TAdClients;
  3326. Var
  3327. _Q : String;
  3328. begin
  3329. _Q:='';
  3330. AddToQuery(_Q,'maxResults',AQuery.maxResults);
  3331. AddToQuery(_Q,'pageToken',AQuery.pageToken);
  3332. Result:=List(_Q);
  3333. end;
  3334. { --------------------------------------------------------------------
  3335. TAdunitsCustomchannelsResource
  3336. --------------------------------------------------------------------}
  3337. Class Function TAdunitsCustomchannelsResource.ResourceName : String;
  3338. begin
  3339. Result:='customchannels';
  3340. end;
  3341. Class Function TAdunitsCustomchannelsResource.DefaultAPI : TGoogleAPIClass;
  3342. begin
  3343. Result:=TadsenseAPI;
  3344. end;
  3345. Function TAdunitsCustomchannelsResource.List(adClientId: string; adUnitId: string; AQuery : string = '') : TCustomChannels;
  3346. Const
  3347. _HTTPMethod = 'GET';
  3348. _Path = 'adclients/{adClientId}/adunits/{adUnitId}/customchannels';
  3349. _Methodid = 'adsense.adunits.customchannels.list';
  3350. Var
  3351. _P : String;
  3352. begin
  3353. _P:=SubstitutePath(_Path,['adClientId',adClientId,'adUnitId',adUnitId]);
  3354. Result:=ServiceCall(_HTTPMethod,_P,AQuery,Nil,TCustomChannels) as TCustomChannels;
  3355. end;
  3356. Function TAdunitsCustomchannelsResource.List(adClientId: string; adUnitId: string; AQuery : TAdunitsCustomchannelslistOptions) : TCustomChannels;
  3357. Var
  3358. _Q : String;
  3359. begin
  3360. _Q:='';
  3361. AddToQuery(_Q,'maxResults',AQuery.maxResults);
  3362. AddToQuery(_Q,'pageToken',AQuery.pageToken);
  3363. Result:=List(adClientId,adUnitId,_Q);
  3364. end;
  3365. { --------------------------------------------------------------------
  3366. TAdunitsResource
  3367. --------------------------------------------------------------------}
  3368. Class Function TAdunitsResource.ResourceName : String;
  3369. begin
  3370. Result:='adunits';
  3371. end;
  3372. Class Function TAdunitsResource.DefaultAPI : TGoogleAPIClass;
  3373. begin
  3374. Result:=TadsenseAPI;
  3375. end;
  3376. Function TAdunitsResource.Get(adClientId: string; adUnitId: string) : TAdUnit;
  3377. Const
  3378. _HTTPMethod = 'GET';
  3379. _Path = 'adclients/{adClientId}/adunits/{adUnitId}';
  3380. _Methodid = 'adsense.adunits.get';
  3381. Var
  3382. _P : String;
  3383. begin
  3384. _P:=SubstitutePath(_Path,['adClientId',adClientId,'adUnitId',adUnitId]);
  3385. Result:=ServiceCall(_HTTPMethod,_P,'',Nil,TAdUnit) as TAdUnit;
  3386. end;
  3387. Function TAdunitsResource.GetAdCode(adClientId: string; adUnitId: string) : TAdCode;
  3388. Const
  3389. _HTTPMethod = 'GET';
  3390. _Path = 'adclients/{adClientId}/adunits/{adUnitId}/adcode';
  3391. _Methodid = 'adsense.adunits.getAdCode';
  3392. Var
  3393. _P : String;
  3394. begin
  3395. _P:=SubstitutePath(_Path,['adClientId',adClientId,'adUnitId',adUnitId]);
  3396. Result:=ServiceCall(_HTTPMethod,_P,'',Nil,TAdCode) as TAdCode;
  3397. end;
  3398. Function TAdunitsResource.List(adClientId: string; AQuery : string = '') : TAdUnits;
  3399. Const
  3400. _HTTPMethod = 'GET';
  3401. _Path = 'adclients/{adClientId}/adunits';
  3402. _Methodid = 'adsense.adunits.list';
  3403. Var
  3404. _P : String;
  3405. begin
  3406. _P:=SubstitutePath(_Path,['adClientId',adClientId]);
  3407. Result:=ServiceCall(_HTTPMethod,_P,AQuery,Nil,TAdUnits) as TAdUnits;
  3408. end;
  3409. Function TAdunitsResource.List(adClientId: string; AQuery : TAdunitslistOptions) : TAdUnits;
  3410. Var
  3411. _Q : String;
  3412. begin
  3413. _Q:='';
  3414. AddToQuery(_Q,'includeInactive',AQuery.includeInactive);
  3415. AddToQuery(_Q,'maxResults',AQuery.maxResults);
  3416. AddToQuery(_Q,'pageToken',AQuery.pageToken);
  3417. Result:=List(adClientId,_Q);
  3418. end;
  3419. Function TAdunitsResource.GetCustomchannelsInstance : TAdunitsCustomchannelsResource;
  3420. begin
  3421. if (FCustomchannelsInstance=Nil) then
  3422. FCustomchannelsInstance:=CreateCustomchannelsResource;
  3423. Result:=FCustomchannelsInstance;
  3424. end;
  3425. Function TAdunitsResource.CreateCustomchannelsResource : TAdunitsCustomchannelsResource;
  3426. begin
  3427. Result:=CreateCustomchannelsResource(Self);
  3428. end;
  3429. Function TAdunitsResource.CreateCustomchannelsResource(AOwner : TComponent) : TAdunitsCustomchannelsResource;
  3430. begin
  3431. Result:=TAdunitsCustomchannelsResource.Create(AOwner);
  3432. Result.API:=Self.API;
  3433. end;
  3434. { --------------------------------------------------------------------
  3435. TAlertsResource
  3436. --------------------------------------------------------------------}
  3437. Class Function TAlertsResource.ResourceName : String;
  3438. begin
  3439. Result:='alerts';
  3440. end;
  3441. Class Function TAlertsResource.DefaultAPI : TGoogleAPIClass;
  3442. begin
  3443. Result:=TadsenseAPI;
  3444. end;
  3445. Procedure TAlertsResource.Delete(alertId: string);
  3446. Const
  3447. _HTTPMethod = 'DELETE';
  3448. _Path = 'alerts/{alertId}';
  3449. _Methodid = 'adsense.alerts.delete';
  3450. Var
  3451. _P : String;
  3452. begin
  3453. _P:=SubstitutePath(_Path,['alertId',alertId]);
  3454. ServiceCall(_HTTPMethod,_P,'',Nil,Nil);
  3455. end;
  3456. Function TAlertsResource.List(AQuery : string = '') : TAlerts;
  3457. Const
  3458. _HTTPMethod = 'GET';
  3459. _Path = 'alerts';
  3460. _Methodid = 'adsense.alerts.list';
  3461. begin
  3462. Result:=ServiceCall(_HTTPMethod,_Path,AQuery,Nil,TAlerts) as TAlerts;
  3463. end;
  3464. Function TAlertsResource.List(AQuery : TAlertslistOptions) : TAlerts;
  3465. Var
  3466. _Q : String;
  3467. begin
  3468. _Q:='';
  3469. AddToQuery(_Q,'locale',AQuery.locale);
  3470. Result:=List(_Q);
  3471. end;
  3472. { --------------------------------------------------------------------
  3473. TCustomchannelsAdunitsResource
  3474. --------------------------------------------------------------------}
  3475. Class Function TCustomchannelsAdunitsResource.ResourceName : String;
  3476. begin
  3477. Result:='adunits';
  3478. end;
  3479. Class Function TCustomchannelsAdunitsResource.DefaultAPI : TGoogleAPIClass;
  3480. begin
  3481. Result:=TadsenseAPI;
  3482. end;
  3483. Function TCustomchannelsAdunitsResource.List(adClientId: string; customChannelId: string; AQuery : string = '') : TAdUnits;
  3484. Const
  3485. _HTTPMethod = 'GET';
  3486. _Path = 'adclients/{adClientId}/customchannels/{customChannelId}/adunits';
  3487. _Methodid = 'adsense.customchannels.adunits.list';
  3488. Var
  3489. _P : String;
  3490. begin
  3491. _P:=SubstitutePath(_Path,['adClientId',adClientId,'customChannelId',customChannelId]);
  3492. Result:=ServiceCall(_HTTPMethod,_P,AQuery,Nil,TAdUnits) as TAdUnits;
  3493. end;
  3494. Function TCustomchannelsAdunitsResource.List(adClientId: string; customChannelId: string; AQuery : TCustomchannelsAdunitslistOptions) : TAdUnits;
  3495. Var
  3496. _Q : String;
  3497. begin
  3498. _Q:='';
  3499. AddToQuery(_Q,'includeInactive',AQuery.includeInactive);
  3500. AddToQuery(_Q,'maxResults',AQuery.maxResults);
  3501. AddToQuery(_Q,'pageToken',AQuery.pageToken);
  3502. Result:=List(adClientId,customChannelId,_Q);
  3503. end;
  3504. { --------------------------------------------------------------------
  3505. TCustomchannelsResource
  3506. --------------------------------------------------------------------}
  3507. Class Function TCustomchannelsResource.ResourceName : String;
  3508. begin
  3509. Result:='customchannels';
  3510. end;
  3511. Class Function TCustomchannelsResource.DefaultAPI : TGoogleAPIClass;
  3512. begin
  3513. Result:=TadsenseAPI;
  3514. end;
  3515. Function TCustomchannelsResource.Get(adClientId: string; customChannelId: string) : TCustomChannel;
  3516. Const
  3517. _HTTPMethod = 'GET';
  3518. _Path = 'adclients/{adClientId}/customchannels/{customChannelId}';
  3519. _Methodid = 'adsense.customchannels.get';
  3520. Var
  3521. _P : String;
  3522. begin
  3523. _P:=SubstitutePath(_Path,['adClientId',adClientId,'customChannelId',customChannelId]);
  3524. Result:=ServiceCall(_HTTPMethod,_P,'',Nil,TCustomChannel) as TCustomChannel;
  3525. end;
  3526. Function TCustomchannelsResource.List(adClientId: string; AQuery : string = '') : TCustomChannels;
  3527. Const
  3528. _HTTPMethod = 'GET';
  3529. _Path = 'adclients/{adClientId}/customchannels';
  3530. _Methodid = 'adsense.customchannels.list';
  3531. Var
  3532. _P : String;
  3533. begin
  3534. _P:=SubstitutePath(_Path,['adClientId',adClientId]);
  3535. Result:=ServiceCall(_HTTPMethod,_P,AQuery,Nil,TCustomChannels) as TCustomChannels;
  3536. end;
  3537. Function TCustomchannelsResource.List(adClientId: string; AQuery : TCustomchannelslistOptions) : TCustomChannels;
  3538. Var
  3539. _Q : String;
  3540. begin
  3541. _Q:='';
  3542. AddToQuery(_Q,'maxResults',AQuery.maxResults);
  3543. AddToQuery(_Q,'pageToken',AQuery.pageToken);
  3544. Result:=List(adClientId,_Q);
  3545. end;
  3546. Function TCustomchannelsResource.GetAdunitsInstance : TCustomchannelsAdunitsResource;
  3547. begin
  3548. if (FAdunitsInstance=Nil) then
  3549. FAdunitsInstance:=CreateAdunitsResource;
  3550. Result:=FAdunitsInstance;
  3551. end;
  3552. Function TCustomchannelsResource.CreateAdunitsResource : TCustomchannelsAdunitsResource;
  3553. begin
  3554. Result:=CreateAdunitsResource(Self);
  3555. end;
  3556. Function TCustomchannelsResource.CreateAdunitsResource(AOwner : TComponent) : TCustomchannelsAdunitsResource;
  3557. begin
  3558. Result:=TCustomchannelsAdunitsResource.Create(AOwner);
  3559. Result.API:=Self.API;
  3560. end;
  3561. { --------------------------------------------------------------------
  3562. TMetadataDimensionsResource
  3563. --------------------------------------------------------------------}
  3564. Class Function TMetadataDimensionsResource.ResourceName : String;
  3565. begin
  3566. Result:='dimensions';
  3567. end;
  3568. Class Function TMetadataDimensionsResource.DefaultAPI : TGoogleAPIClass;
  3569. begin
  3570. Result:=TadsenseAPI;
  3571. end;
  3572. Function TMetadataDimensionsResource.List : TMetadata;
  3573. Const
  3574. _HTTPMethod = 'GET';
  3575. _Path = 'metadata/dimensions';
  3576. _Methodid = 'adsense.metadata.dimensions.list';
  3577. begin
  3578. Result:=ServiceCall(_HTTPMethod,_Path,'',Nil,TMetadata) as TMetadata;
  3579. end;
  3580. { --------------------------------------------------------------------
  3581. TMetadataMetricsResource
  3582. --------------------------------------------------------------------}
  3583. Class Function TMetadataMetricsResource.ResourceName : String;
  3584. begin
  3585. Result:='metrics';
  3586. end;
  3587. Class Function TMetadataMetricsResource.DefaultAPI : TGoogleAPIClass;
  3588. begin
  3589. Result:=TadsenseAPI;
  3590. end;
  3591. Function TMetadataMetricsResource.List : TMetadata;
  3592. Const
  3593. _HTTPMethod = 'GET';
  3594. _Path = 'metadata/metrics';
  3595. _Methodid = 'adsense.metadata.metrics.list';
  3596. begin
  3597. Result:=ServiceCall(_HTTPMethod,_Path,'',Nil,TMetadata) as TMetadata;
  3598. end;
  3599. { --------------------------------------------------------------------
  3600. TMetadataResource
  3601. --------------------------------------------------------------------}
  3602. Class Function TMetadataResource.ResourceName : String;
  3603. begin
  3604. Result:='metadata';
  3605. end;
  3606. Class Function TMetadataResource.DefaultAPI : TGoogleAPIClass;
  3607. begin
  3608. Result:=TadsenseAPI;
  3609. end;
  3610. Function TMetadataResource.GetDimensionsInstance : TMetadataDimensionsResource;
  3611. begin
  3612. if (FDimensionsInstance=Nil) then
  3613. FDimensionsInstance:=CreateDimensionsResource;
  3614. Result:=FDimensionsInstance;
  3615. end;
  3616. Function TMetadataResource.CreateDimensionsResource : TMetadataDimensionsResource;
  3617. begin
  3618. Result:=CreateDimensionsResource(Self);
  3619. end;
  3620. Function TMetadataResource.CreateDimensionsResource(AOwner : TComponent) : TMetadataDimensionsResource;
  3621. begin
  3622. Result:=TMetadataDimensionsResource.Create(AOwner);
  3623. Result.API:=Self.API;
  3624. end;
  3625. Function TMetadataResource.GetMetricsInstance : TMetadataMetricsResource;
  3626. begin
  3627. if (FMetricsInstance=Nil) then
  3628. FMetricsInstance:=CreateMetricsResource;
  3629. Result:=FMetricsInstance;
  3630. end;
  3631. Function TMetadataResource.CreateMetricsResource : TMetadataMetricsResource;
  3632. begin
  3633. Result:=CreateMetricsResource(Self);
  3634. end;
  3635. Function TMetadataResource.CreateMetricsResource(AOwner : TComponent) : TMetadataMetricsResource;
  3636. begin
  3637. Result:=TMetadataMetricsResource.Create(AOwner);
  3638. Result.API:=Self.API;
  3639. end;
  3640. { --------------------------------------------------------------------
  3641. TPaymentsResource
  3642. --------------------------------------------------------------------}
  3643. Class Function TPaymentsResource.ResourceName : String;
  3644. begin
  3645. Result:='payments';
  3646. end;
  3647. Class Function TPaymentsResource.DefaultAPI : TGoogleAPIClass;
  3648. begin
  3649. Result:=TadsenseAPI;
  3650. end;
  3651. Function TPaymentsResource.List : TPayments;
  3652. Const
  3653. _HTTPMethod = 'GET';
  3654. _Path = 'payments';
  3655. _Methodid = 'adsense.payments.list';
  3656. begin
  3657. Result:=ServiceCall(_HTTPMethod,_Path,'',Nil,TPayments) as TPayments;
  3658. end;
  3659. { --------------------------------------------------------------------
  3660. TReportsSavedResource
  3661. --------------------------------------------------------------------}
  3662. Class Function TReportsSavedResource.ResourceName : String;
  3663. begin
  3664. Result:='saved';
  3665. end;
  3666. Class Function TReportsSavedResource.DefaultAPI : TGoogleAPIClass;
  3667. begin
  3668. Result:=TadsenseAPI;
  3669. end;
  3670. Function TReportsSavedResource.Generate(savedReportId: string; AQuery : string = '') : TAdsenseReportsGenerateResponse;
  3671. Const
  3672. _HTTPMethod = 'GET';
  3673. _Path = 'reports/{savedReportId}';
  3674. _Methodid = 'adsense.reports.saved.generate';
  3675. Var
  3676. _P : String;
  3677. begin
  3678. _P:=SubstitutePath(_Path,['savedReportId',savedReportId]);
  3679. Result:=ServiceCall(_HTTPMethod,_P,AQuery,Nil,TAdsenseReportsGenerateResponse) as TAdsenseReportsGenerateResponse;
  3680. end;
  3681. Function TReportsSavedResource.Generate(savedReportId: string; AQuery : TReportsSavedgenerateOptions) : TAdsenseReportsGenerateResponse;
  3682. Var
  3683. _Q : String;
  3684. begin
  3685. _Q:='';
  3686. AddToQuery(_Q,'locale',AQuery.locale);
  3687. AddToQuery(_Q,'maxResults',AQuery.maxResults);
  3688. AddToQuery(_Q,'startIndex',AQuery.startIndex);
  3689. Result:=Generate(savedReportId,_Q);
  3690. end;
  3691. Function TReportsSavedResource.List(AQuery : string = '') : TSavedReports;
  3692. Const
  3693. _HTTPMethod = 'GET';
  3694. _Path = 'reports/saved';
  3695. _Methodid = 'adsense.reports.saved.list';
  3696. begin
  3697. Result:=ServiceCall(_HTTPMethod,_Path,AQuery,Nil,TSavedReports) as TSavedReports;
  3698. end;
  3699. Function TReportsSavedResource.List(AQuery : TReportsSavedlistOptions) : TSavedReports;
  3700. Var
  3701. _Q : String;
  3702. begin
  3703. _Q:='';
  3704. AddToQuery(_Q,'maxResults',AQuery.maxResults);
  3705. AddToQuery(_Q,'pageToken',AQuery.pageToken);
  3706. Result:=List(_Q);
  3707. end;
  3708. { --------------------------------------------------------------------
  3709. TReportsResource
  3710. --------------------------------------------------------------------}
  3711. Class Function TReportsResource.ResourceName : String;
  3712. begin
  3713. Result:='reports';
  3714. end;
  3715. Class Function TReportsResource.DefaultAPI : TGoogleAPIClass;
  3716. begin
  3717. Result:=TadsenseAPI;
  3718. end;
  3719. Function TReportsResource.Generate(AQuery : string = '') : TAdsenseReportsGenerateResponse;
  3720. Const
  3721. _HTTPMethod = 'GET';
  3722. _Path = 'reports';
  3723. _Methodid = 'adsense.reports.generate';
  3724. begin
  3725. Result:=ServiceCall(_HTTPMethod,_Path,AQuery,Nil,TAdsenseReportsGenerateResponse) as TAdsenseReportsGenerateResponse;
  3726. end;
  3727. Function TReportsResource.Generate(AQuery : TReportsgenerateOptions) : TAdsenseReportsGenerateResponse;
  3728. Var
  3729. _Q : String;
  3730. begin
  3731. _Q:='';
  3732. AddToQuery(_Q,'accountId',AQuery.accountId);
  3733. AddToQuery(_Q,'currency',AQuery.currency);
  3734. AddToQuery(_Q,'dimension',AQuery.dimension);
  3735. AddToQuery(_Q,'endDate',AQuery.endDate);
  3736. AddToQuery(_Q,'filter',AQuery.filter);
  3737. AddToQuery(_Q,'locale',AQuery.locale);
  3738. AddToQuery(_Q,'maxResults',AQuery.maxResults);
  3739. AddToQuery(_Q,'metric',AQuery.metric);
  3740. AddToQuery(_Q,'sort',AQuery.sort);
  3741. AddToQuery(_Q,'startDate',AQuery.startDate);
  3742. AddToQuery(_Q,'startIndex',AQuery.startIndex);
  3743. AddToQuery(_Q,'useTimezoneReporting',AQuery.useTimezoneReporting);
  3744. Result:=Generate(_Q);
  3745. end;
  3746. Function TReportsResource.GetSavedInstance : TReportsSavedResource;
  3747. begin
  3748. if (FSavedInstance=Nil) then
  3749. FSavedInstance:=CreateSavedResource;
  3750. Result:=FSavedInstance;
  3751. end;
  3752. Function TReportsResource.CreateSavedResource : TReportsSavedResource;
  3753. begin
  3754. Result:=CreateSavedResource(Self);
  3755. end;
  3756. Function TReportsResource.CreateSavedResource(AOwner : TComponent) : TReportsSavedResource;
  3757. begin
  3758. Result:=TReportsSavedResource.Create(AOwner);
  3759. Result.API:=Self.API;
  3760. end;
  3761. { --------------------------------------------------------------------
  3762. TSavedadstylesResource
  3763. --------------------------------------------------------------------}
  3764. Class Function TSavedadstylesResource.ResourceName : String;
  3765. begin
  3766. Result:='savedadstyles';
  3767. end;
  3768. Class Function TSavedadstylesResource.DefaultAPI : TGoogleAPIClass;
  3769. begin
  3770. Result:=TadsenseAPI;
  3771. end;
  3772. Function TSavedadstylesResource.Get(savedAdStyleId: string) : TSavedAdStyle;
  3773. Const
  3774. _HTTPMethod = 'GET';
  3775. _Path = 'savedadstyles/{savedAdStyleId}';
  3776. _Methodid = 'adsense.savedadstyles.get';
  3777. Var
  3778. _P : String;
  3779. begin
  3780. _P:=SubstitutePath(_Path,['savedAdStyleId',savedAdStyleId]);
  3781. Result:=ServiceCall(_HTTPMethod,_P,'',Nil,TSavedAdStyle) as TSavedAdStyle;
  3782. end;
  3783. Function TSavedadstylesResource.List(AQuery : string = '') : TSavedAdStyles;
  3784. Const
  3785. _HTTPMethod = 'GET';
  3786. _Path = 'savedadstyles';
  3787. _Methodid = 'adsense.savedadstyles.list';
  3788. begin
  3789. Result:=ServiceCall(_HTTPMethod,_Path,AQuery,Nil,TSavedAdStyles) as TSavedAdStyles;
  3790. end;
  3791. Function TSavedadstylesResource.List(AQuery : TSavedadstyleslistOptions) : TSavedAdStyles;
  3792. Var
  3793. _Q : String;
  3794. begin
  3795. _Q:='';
  3796. AddToQuery(_Q,'maxResults',AQuery.maxResults);
  3797. AddToQuery(_Q,'pageToken',AQuery.pageToken);
  3798. Result:=List(_Q);
  3799. end;
  3800. { --------------------------------------------------------------------
  3801. TUrlchannelsResource
  3802. --------------------------------------------------------------------}
  3803. Class Function TUrlchannelsResource.ResourceName : String;
  3804. begin
  3805. Result:='urlchannels';
  3806. end;
  3807. Class Function TUrlchannelsResource.DefaultAPI : TGoogleAPIClass;
  3808. begin
  3809. Result:=TadsenseAPI;
  3810. end;
  3811. Function TUrlchannelsResource.List(adClientId: string; AQuery : string = '') : TUrlChannels;
  3812. Const
  3813. _HTTPMethod = 'GET';
  3814. _Path = 'adclients/{adClientId}/urlchannels';
  3815. _Methodid = 'adsense.urlchannels.list';
  3816. Var
  3817. _P : String;
  3818. begin
  3819. _P:=SubstitutePath(_Path,['adClientId',adClientId]);
  3820. Result:=ServiceCall(_HTTPMethod,_P,AQuery,Nil,TUrlChannels) as TUrlChannels;
  3821. end;
  3822. Function TUrlchannelsResource.List(adClientId: string; AQuery : TUrlchannelslistOptions) : TUrlChannels;
  3823. Var
  3824. _Q : String;
  3825. begin
  3826. _Q:='';
  3827. AddToQuery(_Q,'maxResults',AQuery.maxResults);
  3828. AddToQuery(_Q,'pageToken',AQuery.pageToken);
  3829. Result:=List(adClientId,_Q);
  3830. end;
  3831. { --------------------------------------------------------------------
  3832. TAdsenseAPI
  3833. --------------------------------------------------------------------}
  3834. Class Function TAdsenseAPI.APIName : String;
  3835. begin
  3836. Result:='adsense';
  3837. end;
  3838. Class Function TAdsenseAPI.APIVersion : String;
  3839. begin
  3840. Result:='v1.4';
  3841. end;
  3842. Class Function TAdsenseAPI.APIRevision : String;
  3843. begin
  3844. Result:='20160522';
  3845. end;
  3846. Class Function TAdsenseAPI.APIID : String;
  3847. begin
  3848. Result:='adsense:v1.4';
  3849. end;
  3850. Class Function TAdsenseAPI.APITitle : String;
  3851. begin
  3852. Result:='AdSense Management API';
  3853. end;
  3854. Class Function TAdsenseAPI.APIDescription : String;
  3855. begin
  3856. Result:='Accesses AdSense publishers'' inventory and generates performance reports.';
  3857. end;
  3858. Class Function TAdsenseAPI.APIOwnerDomain : String;
  3859. begin
  3860. Result:='google.com';
  3861. end;
  3862. Class Function TAdsenseAPI.APIOwnerName : String;
  3863. begin
  3864. Result:='Google';
  3865. end;
  3866. Class Function TAdsenseAPI.APIIcon16 : String;
  3867. begin
  3868. Result:='https://www.google.com/images/icons/product/adsense-16.png';
  3869. end;
  3870. Class Function TAdsenseAPI.APIIcon32 : String;
  3871. begin
  3872. Result:='https://www.google.com/images/icons/product/adsense-32.png';
  3873. end;
  3874. Class Function TAdsenseAPI.APIdocumentationLink : String;
  3875. begin
  3876. Result:='https://developers.google.com/adsense/management/';
  3877. end;
  3878. Class Function TAdsenseAPI.APIrootUrl : string;
  3879. begin
  3880. Result:='https://www.googleapis.com/';
  3881. end;
  3882. Class Function TAdsenseAPI.APIbasePath : string;
  3883. begin
  3884. Result:='/adsense/v1.4/';
  3885. end;
  3886. Class Function TAdsenseAPI.APIbaseURL : String;
  3887. begin
  3888. Result:='https://www.googleapis.com/adsense/v1.4/';
  3889. end;
  3890. Class Function TAdsenseAPI.APIProtocol : string;
  3891. begin
  3892. Result:='rest';
  3893. end;
  3894. Class Function TAdsenseAPI.APIservicePath : string;
  3895. begin
  3896. Result:='adsense/v1.4/';
  3897. end;
  3898. Class Function TAdsenseAPI.APIbatchPath : String;
  3899. begin
  3900. Result:='batch';
  3901. end;
  3902. Class Function TAdsenseAPI.APIAuthScopes : TScopeInfoArray;
  3903. begin
  3904. SetLength(Result,2);
  3905. Result[0].Name:='https://www.googleapis.com/auth/adsense';
  3906. Result[0].Description:='View and manage your AdSense data';
  3907. Result[1].Name:='https://www.googleapis.com/auth/adsense.readonly';
  3908. Result[1].Description:='View your AdSense data';
  3909. end;
  3910. Class Function TAdsenseAPI.APINeedsAuth : Boolean;
  3911. begin
  3912. Result:=True;
  3913. end;
  3914. Class Procedure TAdsenseAPI.RegisterAPIResources;
  3915. begin
  3916. TAccount.RegisterObject;
  3917. TAccounts.RegisterObject;
  3918. TAdClient.RegisterObject;
  3919. TAdClients.RegisterObject;
  3920. TAdCode.RegisterObject;
  3921. TAdStyleTypecolors.RegisterObject;
  3922. TAdStyleTypefont.RegisterObject;
  3923. TAdStyle.RegisterObject;
  3924. TAdUnitTypecontentAdsSettingsTypebackupOption.RegisterObject;
  3925. TAdUnitTypecontentAdsSettings.RegisterObject;
  3926. TAdUnitTypefeedAdsSettings.RegisterObject;
  3927. TAdUnitTypemobileContentAdsSettings.RegisterObject;
  3928. TAdUnit.RegisterObject;
  3929. TAdUnits.RegisterObject;
  3930. TAdsenseReportsGenerateResponseTypeheadersItem.RegisterObject;
  3931. TAdsenseReportsGenerateResponse.RegisterObject;
  3932. TAlert.RegisterObject;
  3933. TAlerts.RegisterObject;
  3934. TCustomChannelTypetargetingInfo.RegisterObject;
  3935. TCustomChannel.RegisterObject;
  3936. TCustomChannels.RegisterObject;
  3937. TMetadata.RegisterObject;
  3938. TPayment.RegisterObject;
  3939. TPayments.RegisterObject;
  3940. TReportingMetadataEntry.RegisterObject;
  3941. TSavedAdStyle.RegisterObject;
  3942. TSavedAdStyles.RegisterObject;
  3943. TSavedReport.RegisterObject;
  3944. TSavedReports.RegisterObject;
  3945. TUrlChannel.RegisterObject;
  3946. TUrlChannels.RegisterObject;
  3947. end;
  3948. Function TAdsenseAPI.GetAccountsAdclientsInstance : TAccountsAdclientsResource;
  3949. begin
  3950. if (FAccountsAdclientsInstance=Nil) then
  3951. FAccountsAdclientsInstance:=CreateAccountsAdclientsResource;
  3952. Result:=FAccountsAdclientsInstance;
  3953. end;
  3954. Function TAdsenseAPI.CreateAccountsAdclientsResource : TAccountsAdclientsResource;
  3955. begin
  3956. Result:=CreateAccountsAdclientsResource(Self);
  3957. end;
  3958. Function TAdsenseAPI.CreateAccountsAdclientsResource(AOwner : TComponent) : TAccountsAdclientsResource;
  3959. begin
  3960. Result:=TAccountsAdclientsResource.Create(AOwner);
  3961. Result.API:=Self.API;
  3962. end;
  3963. Function TAdsenseAPI.GetAccountsAdunitsCustomchannelsInstance : TAccountsAdunitsCustomchannelsResource;
  3964. begin
  3965. if (FAccountsAdunitsCustomchannelsInstance=Nil) then
  3966. FAccountsAdunitsCustomchannelsInstance:=CreateAccountsAdunitsCustomchannelsResource;
  3967. Result:=FAccountsAdunitsCustomchannelsInstance;
  3968. end;
  3969. Function TAdsenseAPI.CreateAccountsAdunitsCustomchannelsResource : TAccountsAdunitsCustomchannelsResource;
  3970. begin
  3971. Result:=CreateAccountsAdunitsCustomchannelsResource(Self);
  3972. end;
  3973. Function TAdsenseAPI.CreateAccountsAdunitsCustomchannelsResource(AOwner : TComponent) : TAccountsAdunitsCustomchannelsResource;
  3974. begin
  3975. Result:=TAccountsAdunitsCustomchannelsResource.Create(AOwner);
  3976. Result.API:=Self.API;
  3977. end;
  3978. Function TAdsenseAPI.GetAccountsAdunitsInstance : TAccountsAdunitsResource;
  3979. begin
  3980. if (FAccountsAdunitsInstance=Nil) then
  3981. FAccountsAdunitsInstance:=CreateAccountsAdunitsResource;
  3982. Result:=FAccountsAdunitsInstance;
  3983. end;
  3984. Function TAdsenseAPI.CreateAccountsAdunitsResource : TAccountsAdunitsResource;
  3985. begin
  3986. Result:=CreateAccountsAdunitsResource(Self);
  3987. end;
  3988. Function TAdsenseAPI.CreateAccountsAdunitsResource(AOwner : TComponent) : TAccountsAdunitsResource;
  3989. begin
  3990. Result:=TAccountsAdunitsResource.Create(AOwner);
  3991. Result.API:=Self.API;
  3992. end;
  3993. Function TAdsenseAPI.GetAccountsAlertsInstance : TAccountsAlertsResource;
  3994. begin
  3995. if (FAccountsAlertsInstance=Nil) then
  3996. FAccountsAlertsInstance:=CreateAccountsAlertsResource;
  3997. Result:=FAccountsAlertsInstance;
  3998. end;
  3999. Function TAdsenseAPI.CreateAccountsAlertsResource : TAccountsAlertsResource;
  4000. begin
  4001. Result:=CreateAccountsAlertsResource(Self);
  4002. end;
  4003. Function TAdsenseAPI.CreateAccountsAlertsResource(AOwner : TComponent) : TAccountsAlertsResource;
  4004. begin
  4005. Result:=TAccountsAlertsResource.Create(AOwner);
  4006. Result.API:=Self.API;
  4007. end;
  4008. Function TAdsenseAPI.GetAccountsCustomchannelsAdunitsInstance : TAccountsCustomchannelsAdunitsResource;
  4009. begin
  4010. if (FAccountsCustomchannelsAdunitsInstance=Nil) then
  4011. FAccountsCustomchannelsAdunitsInstance:=CreateAccountsCustomchannelsAdunitsResource;
  4012. Result:=FAccountsCustomchannelsAdunitsInstance;
  4013. end;
  4014. Function TAdsenseAPI.CreateAccountsCustomchannelsAdunitsResource : TAccountsCustomchannelsAdunitsResource;
  4015. begin
  4016. Result:=CreateAccountsCustomchannelsAdunitsResource(Self);
  4017. end;
  4018. Function TAdsenseAPI.CreateAccountsCustomchannelsAdunitsResource(AOwner : TComponent) : TAccountsCustomchannelsAdunitsResource;
  4019. begin
  4020. Result:=TAccountsCustomchannelsAdunitsResource.Create(AOwner);
  4021. Result.API:=Self.API;
  4022. end;
  4023. Function TAdsenseAPI.GetAccountsCustomchannelsInstance : TAccountsCustomchannelsResource;
  4024. begin
  4025. if (FAccountsCustomchannelsInstance=Nil) then
  4026. FAccountsCustomchannelsInstance:=CreateAccountsCustomchannelsResource;
  4027. Result:=FAccountsCustomchannelsInstance;
  4028. end;
  4029. Function TAdsenseAPI.CreateAccountsCustomchannelsResource : TAccountsCustomchannelsResource;
  4030. begin
  4031. Result:=CreateAccountsCustomchannelsResource(Self);
  4032. end;
  4033. Function TAdsenseAPI.CreateAccountsCustomchannelsResource(AOwner : TComponent) : TAccountsCustomchannelsResource;
  4034. begin
  4035. Result:=TAccountsCustomchannelsResource.Create(AOwner);
  4036. Result.API:=Self.API;
  4037. end;
  4038. Function TAdsenseAPI.GetAccountsPaymentsInstance : TAccountsPaymentsResource;
  4039. begin
  4040. if (FAccountsPaymentsInstance=Nil) then
  4041. FAccountsPaymentsInstance:=CreateAccountsPaymentsResource;
  4042. Result:=FAccountsPaymentsInstance;
  4043. end;
  4044. Function TAdsenseAPI.CreateAccountsPaymentsResource : TAccountsPaymentsResource;
  4045. begin
  4046. Result:=CreateAccountsPaymentsResource(Self);
  4047. end;
  4048. Function TAdsenseAPI.CreateAccountsPaymentsResource(AOwner : TComponent) : TAccountsPaymentsResource;
  4049. begin
  4050. Result:=TAccountsPaymentsResource.Create(AOwner);
  4051. Result.API:=Self.API;
  4052. end;
  4053. Function TAdsenseAPI.GetAccountsReportsSavedInstance : TAccountsReportsSavedResource;
  4054. begin
  4055. if (FAccountsReportsSavedInstance=Nil) then
  4056. FAccountsReportsSavedInstance:=CreateAccountsReportsSavedResource;
  4057. Result:=FAccountsReportsSavedInstance;
  4058. end;
  4059. Function TAdsenseAPI.CreateAccountsReportsSavedResource : TAccountsReportsSavedResource;
  4060. begin
  4061. Result:=CreateAccountsReportsSavedResource(Self);
  4062. end;
  4063. Function TAdsenseAPI.CreateAccountsReportsSavedResource(AOwner : TComponent) : TAccountsReportsSavedResource;
  4064. begin
  4065. Result:=TAccountsReportsSavedResource.Create(AOwner);
  4066. Result.API:=Self.API;
  4067. end;
  4068. Function TAdsenseAPI.GetAccountsReportsInstance : TAccountsReportsResource;
  4069. begin
  4070. if (FAccountsReportsInstance=Nil) then
  4071. FAccountsReportsInstance:=CreateAccountsReportsResource;
  4072. Result:=FAccountsReportsInstance;
  4073. end;
  4074. Function TAdsenseAPI.CreateAccountsReportsResource : TAccountsReportsResource;
  4075. begin
  4076. Result:=CreateAccountsReportsResource(Self);
  4077. end;
  4078. Function TAdsenseAPI.CreateAccountsReportsResource(AOwner : TComponent) : TAccountsReportsResource;
  4079. begin
  4080. Result:=TAccountsReportsResource.Create(AOwner);
  4081. Result.API:=Self.API;
  4082. end;
  4083. Function TAdsenseAPI.GetAccountsSavedadstylesInstance : TAccountsSavedadstylesResource;
  4084. begin
  4085. if (FAccountsSavedadstylesInstance=Nil) then
  4086. FAccountsSavedadstylesInstance:=CreateAccountsSavedadstylesResource;
  4087. Result:=FAccountsSavedadstylesInstance;
  4088. end;
  4089. Function TAdsenseAPI.CreateAccountsSavedadstylesResource : TAccountsSavedadstylesResource;
  4090. begin
  4091. Result:=CreateAccountsSavedadstylesResource(Self);
  4092. end;
  4093. Function TAdsenseAPI.CreateAccountsSavedadstylesResource(AOwner : TComponent) : TAccountsSavedadstylesResource;
  4094. begin
  4095. Result:=TAccountsSavedadstylesResource.Create(AOwner);
  4096. Result.API:=Self.API;
  4097. end;
  4098. Function TAdsenseAPI.GetAccountsUrlchannelsInstance : TAccountsUrlchannelsResource;
  4099. begin
  4100. if (FAccountsUrlchannelsInstance=Nil) then
  4101. FAccountsUrlchannelsInstance:=CreateAccountsUrlchannelsResource;
  4102. Result:=FAccountsUrlchannelsInstance;
  4103. end;
  4104. Function TAdsenseAPI.CreateAccountsUrlchannelsResource : TAccountsUrlchannelsResource;
  4105. begin
  4106. Result:=CreateAccountsUrlchannelsResource(Self);
  4107. end;
  4108. Function TAdsenseAPI.CreateAccountsUrlchannelsResource(AOwner : TComponent) : TAccountsUrlchannelsResource;
  4109. begin
  4110. Result:=TAccountsUrlchannelsResource.Create(AOwner);
  4111. Result.API:=Self.API;
  4112. end;
  4113. Function TAdsenseAPI.GetAccountsInstance : TAccountsResource;
  4114. begin
  4115. if (FAccountsInstance=Nil) then
  4116. FAccountsInstance:=CreateAccountsResource;
  4117. Result:=FAccountsInstance;
  4118. end;
  4119. Function TAdsenseAPI.CreateAccountsResource : TAccountsResource;
  4120. begin
  4121. Result:=CreateAccountsResource(Self);
  4122. end;
  4123. Function TAdsenseAPI.CreateAccountsResource(AOwner : TComponent) : TAccountsResource;
  4124. begin
  4125. Result:=TAccountsResource.Create(AOwner);
  4126. Result.API:=Self.API;
  4127. end;
  4128. Function TAdsenseAPI.GetAdclientsInstance : TAdclientsResource;
  4129. begin
  4130. if (FAdclientsInstance=Nil) then
  4131. FAdclientsInstance:=CreateAdclientsResource;
  4132. Result:=FAdclientsInstance;
  4133. end;
  4134. Function TAdsenseAPI.CreateAdclientsResource : TAdclientsResource;
  4135. begin
  4136. Result:=CreateAdclientsResource(Self);
  4137. end;
  4138. Function TAdsenseAPI.CreateAdclientsResource(AOwner : TComponent) : TAdclientsResource;
  4139. begin
  4140. Result:=TAdclientsResource.Create(AOwner);
  4141. Result.API:=Self.API;
  4142. end;
  4143. Function TAdsenseAPI.GetAdunitsCustomchannelsInstance : TAdunitsCustomchannelsResource;
  4144. begin
  4145. if (FAdunitsCustomchannelsInstance=Nil) then
  4146. FAdunitsCustomchannelsInstance:=CreateAdunitsCustomchannelsResource;
  4147. Result:=FAdunitsCustomchannelsInstance;
  4148. end;
  4149. Function TAdsenseAPI.CreateAdunitsCustomchannelsResource : TAdunitsCustomchannelsResource;
  4150. begin
  4151. Result:=CreateAdunitsCustomchannelsResource(Self);
  4152. end;
  4153. Function TAdsenseAPI.CreateAdunitsCustomchannelsResource(AOwner : TComponent) : TAdunitsCustomchannelsResource;
  4154. begin
  4155. Result:=TAdunitsCustomchannelsResource.Create(AOwner);
  4156. Result.API:=Self.API;
  4157. end;
  4158. Function TAdsenseAPI.GetAdunitsInstance : TAdunitsResource;
  4159. begin
  4160. if (FAdunitsInstance=Nil) then
  4161. FAdunitsInstance:=CreateAdunitsResource;
  4162. Result:=FAdunitsInstance;
  4163. end;
  4164. Function TAdsenseAPI.CreateAdunitsResource : TAdunitsResource;
  4165. begin
  4166. Result:=CreateAdunitsResource(Self);
  4167. end;
  4168. Function TAdsenseAPI.CreateAdunitsResource(AOwner : TComponent) : TAdunitsResource;
  4169. begin
  4170. Result:=TAdunitsResource.Create(AOwner);
  4171. Result.API:=Self.API;
  4172. end;
  4173. Function TAdsenseAPI.GetAlertsInstance : TAlertsResource;
  4174. begin
  4175. if (FAlertsInstance=Nil) then
  4176. FAlertsInstance:=CreateAlertsResource;
  4177. Result:=FAlertsInstance;
  4178. end;
  4179. Function TAdsenseAPI.CreateAlertsResource : TAlertsResource;
  4180. begin
  4181. Result:=CreateAlertsResource(Self);
  4182. end;
  4183. Function TAdsenseAPI.CreateAlertsResource(AOwner : TComponent) : TAlertsResource;
  4184. begin
  4185. Result:=TAlertsResource.Create(AOwner);
  4186. Result.API:=Self.API;
  4187. end;
  4188. Function TAdsenseAPI.GetCustomchannelsAdunitsInstance : TCustomchannelsAdunitsResource;
  4189. begin
  4190. if (FCustomchannelsAdunitsInstance=Nil) then
  4191. FCustomchannelsAdunitsInstance:=CreateCustomchannelsAdunitsResource;
  4192. Result:=FCustomchannelsAdunitsInstance;
  4193. end;
  4194. Function TAdsenseAPI.CreateCustomchannelsAdunitsResource : TCustomchannelsAdunitsResource;
  4195. begin
  4196. Result:=CreateCustomchannelsAdunitsResource(Self);
  4197. end;
  4198. Function TAdsenseAPI.CreateCustomchannelsAdunitsResource(AOwner : TComponent) : TCustomchannelsAdunitsResource;
  4199. begin
  4200. Result:=TCustomchannelsAdunitsResource.Create(AOwner);
  4201. Result.API:=Self.API;
  4202. end;
  4203. Function TAdsenseAPI.GetCustomchannelsInstance : TCustomchannelsResource;
  4204. begin
  4205. if (FCustomchannelsInstance=Nil) then
  4206. FCustomchannelsInstance:=CreateCustomchannelsResource;
  4207. Result:=FCustomchannelsInstance;
  4208. end;
  4209. Function TAdsenseAPI.CreateCustomchannelsResource : TCustomchannelsResource;
  4210. begin
  4211. Result:=CreateCustomchannelsResource(Self);
  4212. end;
  4213. Function TAdsenseAPI.CreateCustomchannelsResource(AOwner : TComponent) : TCustomchannelsResource;
  4214. begin
  4215. Result:=TCustomchannelsResource.Create(AOwner);
  4216. Result.API:=Self.API;
  4217. end;
  4218. Function TAdsenseAPI.GetMetadataDimensionsInstance : TMetadataDimensionsResource;
  4219. begin
  4220. if (FMetadataDimensionsInstance=Nil) then
  4221. FMetadataDimensionsInstance:=CreateMetadataDimensionsResource;
  4222. Result:=FMetadataDimensionsInstance;
  4223. end;
  4224. Function TAdsenseAPI.CreateMetadataDimensionsResource : TMetadataDimensionsResource;
  4225. begin
  4226. Result:=CreateMetadataDimensionsResource(Self);
  4227. end;
  4228. Function TAdsenseAPI.CreateMetadataDimensionsResource(AOwner : TComponent) : TMetadataDimensionsResource;
  4229. begin
  4230. Result:=TMetadataDimensionsResource.Create(AOwner);
  4231. Result.API:=Self.API;
  4232. end;
  4233. Function TAdsenseAPI.GetMetadataMetricsInstance : TMetadataMetricsResource;
  4234. begin
  4235. if (FMetadataMetricsInstance=Nil) then
  4236. FMetadataMetricsInstance:=CreateMetadataMetricsResource;
  4237. Result:=FMetadataMetricsInstance;
  4238. end;
  4239. Function TAdsenseAPI.CreateMetadataMetricsResource : TMetadataMetricsResource;
  4240. begin
  4241. Result:=CreateMetadataMetricsResource(Self);
  4242. end;
  4243. Function TAdsenseAPI.CreateMetadataMetricsResource(AOwner : TComponent) : TMetadataMetricsResource;
  4244. begin
  4245. Result:=TMetadataMetricsResource.Create(AOwner);
  4246. Result.API:=Self.API;
  4247. end;
  4248. Function TAdsenseAPI.GetMetadataInstance : TMetadataResource;
  4249. begin
  4250. if (FMetadataInstance=Nil) then
  4251. FMetadataInstance:=CreateMetadataResource;
  4252. Result:=FMetadataInstance;
  4253. end;
  4254. Function TAdsenseAPI.CreateMetadataResource : TMetadataResource;
  4255. begin
  4256. Result:=CreateMetadataResource(Self);
  4257. end;
  4258. Function TAdsenseAPI.CreateMetadataResource(AOwner : TComponent) : TMetadataResource;
  4259. begin
  4260. Result:=TMetadataResource.Create(AOwner);
  4261. Result.API:=Self.API;
  4262. end;
  4263. Function TAdsenseAPI.GetPaymentsInstance : TPaymentsResource;
  4264. begin
  4265. if (FPaymentsInstance=Nil) then
  4266. FPaymentsInstance:=CreatePaymentsResource;
  4267. Result:=FPaymentsInstance;
  4268. end;
  4269. Function TAdsenseAPI.CreatePaymentsResource : TPaymentsResource;
  4270. begin
  4271. Result:=CreatePaymentsResource(Self);
  4272. end;
  4273. Function TAdsenseAPI.CreatePaymentsResource(AOwner : TComponent) : TPaymentsResource;
  4274. begin
  4275. Result:=TPaymentsResource.Create(AOwner);
  4276. Result.API:=Self.API;
  4277. end;
  4278. Function TAdsenseAPI.GetReportsSavedInstance : TReportsSavedResource;
  4279. begin
  4280. if (FReportsSavedInstance=Nil) then
  4281. FReportsSavedInstance:=CreateReportsSavedResource;
  4282. Result:=FReportsSavedInstance;
  4283. end;
  4284. Function TAdsenseAPI.CreateReportsSavedResource : TReportsSavedResource;
  4285. begin
  4286. Result:=CreateReportsSavedResource(Self);
  4287. end;
  4288. Function TAdsenseAPI.CreateReportsSavedResource(AOwner : TComponent) : TReportsSavedResource;
  4289. begin
  4290. Result:=TReportsSavedResource.Create(AOwner);
  4291. Result.API:=Self.API;
  4292. end;
  4293. Function TAdsenseAPI.GetReportsInstance : TReportsResource;
  4294. begin
  4295. if (FReportsInstance=Nil) then
  4296. FReportsInstance:=CreateReportsResource;
  4297. Result:=FReportsInstance;
  4298. end;
  4299. Function TAdsenseAPI.CreateReportsResource : TReportsResource;
  4300. begin
  4301. Result:=CreateReportsResource(Self);
  4302. end;
  4303. Function TAdsenseAPI.CreateReportsResource(AOwner : TComponent) : TReportsResource;
  4304. begin
  4305. Result:=TReportsResource.Create(AOwner);
  4306. Result.API:=Self.API;
  4307. end;
  4308. Function TAdsenseAPI.GetSavedadstylesInstance : TSavedadstylesResource;
  4309. begin
  4310. if (FSavedadstylesInstance=Nil) then
  4311. FSavedadstylesInstance:=CreateSavedadstylesResource;
  4312. Result:=FSavedadstylesInstance;
  4313. end;
  4314. Function TAdsenseAPI.CreateSavedadstylesResource : TSavedadstylesResource;
  4315. begin
  4316. Result:=CreateSavedadstylesResource(Self);
  4317. end;
  4318. Function TAdsenseAPI.CreateSavedadstylesResource(AOwner : TComponent) : TSavedadstylesResource;
  4319. begin
  4320. Result:=TSavedadstylesResource.Create(AOwner);
  4321. Result.API:=Self.API;
  4322. end;
  4323. Function TAdsenseAPI.GetUrlchannelsInstance : TUrlchannelsResource;
  4324. begin
  4325. if (FUrlchannelsInstance=Nil) then
  4326. FUrlchannelsInstance:=CreateUrlchannelsResource;
  4327. Result:=FUrlchannelsInstance;
  4328. end;
  4329. Function TAdsenseAPI.CreateUrlchannelsResource : TUrlchannelsResource;
  4330. begin
  4331. Result:=CreateUrlchannelsResource(Self);
  4332. end;
  4333. Function TAdsenseAPI.CreateUrlchannelsResource(AOwner : TComponent) : TUrlchannelsResource;
  4334. begin
  4335. Result:=TUrlchannelsResource.Create(AOwner);
  4336. Result.API:=Self.API;
  4337. end;
  4338. initialization
  4339. TAdsenseAPI.RegisterAPI;
  4340. end.