blob_id
stringlengths
40
40
directory_id
stringlengths
40
40
path
stringlengths
4
410
content_id
stringlengths
40
40
detected_licenses
listlengths
0
51
license_type
stringclasses
2 values
repo_name
stringlengths
5
132
snapshot_id
stringlengths
40
40
revision_id
stringlengths
40
40
branch_name
stringlengths
4
80
visit_date
timestamp[us]
revision_date
timestamp[us]
committer_date
timestamp[us]
github_id
int64
5.85k
689M
star_events_count
int64
0
209k
fork_events_count
int64
0
110k
gha_license_id
stringclasses
22 values
gha_event_created_at
timestamp[us]
gha_created_at
timestamp[us]
gha_language
stringclasses
131 values
src_encoding
stringclasses
34 values
language
stringclasses
1 value
is_vendor
bool
1 class
is_generated
bool
2 classes
length_bytes
int64
3
9.45M
extension
stringclasses
32 values
content
stringlengths
3
9.45M
authors
listlengths
1
1
author_id
stringlengths
0
313
5bb86e6d3420ca564ae67187fe47deedfa4da717
ef2c7d2e0355a25eb2b76e509ce32cce713f1d45
/src/main/java/com/digital_innovationone/heroesapi/repository/HeroesRepository.java
2eb239d0bc1b20d3f0e35fe70891a98b33f72bd3
[]
no_license
Jorgeasf13/gerenciador_herois
9d0a31ac76da9ac2b7b324e9ed78107fef108519
0148cc35050a23d69fa783639f8234f3d3320105
refs/heads/master
2023-04-04T02:21:30.223482
2021-04-15T23:52:15
2021-04-15T23:52:15
358,418,696
0
0
null
null
null
null
UTF-8
Java
false
false
394
java
package com.digital_innovationone.heroesapi.repository; import com.amazonaws.services.dynamodbv2.xspec.S; import com.digital_innovationone.heroesapi.document.Heroes; import org.socialsignin.spring.data.dynamodb.repository.EnableScan; import org.springframework.data.repository.CrudRepository; @EnableScan public interface HeroesRepository extends CrudRepository<Heroes, String> { }
[ "noreply@github.com" ]
Jorgeasf13.noreply@github.com
67323a5f0602f33e5354c2f5d0fc540f47568dea
2869fc39e2e63d994d5dd8876476e473cb8d3986
/Super_order/src/java/com/lvmama/group/dao/GroupDreamDAO.java
aa3b36d2894e62bd398597c0425c4e6337bc75b7
[]
no_license
kavt/feiniu_pet
bec739de7c4e2ee896de50962dbd5fb6f1e28fe9
82963e2e87611442d9b338d96e0343f67262f437
refs/heads/master
2020-12-25T17:45:16.166052
2016-06-13T10:02:42
2016-06-13T10:02:42
61,026,061
0
0
null
2016-06-13T10:02:01
2016-06-13T10:02:01
null
UTF-8
Java
false
false
1,813
java
package com.lvmama.group.dao; import java.util.List; import java.util.Map; import com.lvmama.comm.BaseIbatisDAO; import com.lvmama.comm.bee.po.group.GroupDream; public class GroupDreamDAO extends BaseIbatisDAO { public GroupDream selectByPrimaryKey(Long dreamId) { GroupDream groupDream = (GroupDream) super.queryForObject("GROUP_DREAM.selectByPrimaryKey", dreamId); return groupDream; } public Integer selectRowCount(Map searchConds){ Integer count = 0; count = (Integer) super.queryForObject("GROUP_DREAM.selectRowCount",searchConds); return count; } public List<GroupDream> getSupGroupDreams(Map param) { if (param.get("_startRow")==null) { param.put("_startRow", 0); } if (param.get("_endRow")==null) { param.put("_endRow", 20); } return super.queryForList("GROUP_DREAM.selectGroupDream", param); } public Long insert(GroupDream groupDream) { Long key = (Long) super.insert("GROUP_DREAM.insert", groupDream); return key; } public int updateByPrimaryKey(GroupDream groupDream) { int rows = super.update("GROUP_DREAM.updateByPrimaryKey", groupDream); return rows; } public int updateValidByPrimaryKey(GroupDream groupDream) { int rows = super.update("GROUP_DREAM.updateValidByPrimaryKey", groupDream); return rows; } public void deleteByPrimaryKey(Map params){ super.delete("GROUP_DREAM.deleteByPrimaryKey",params); } // public Integer countByProductId(Long productId) { // GroupDream groupDream = new GroupDream(); // groupDream.setProductId(productId); // return (Integer) super.queryForObject("GROUP_DREAM.countByProductId", groupDream); // } public List<GroupDream> queryDreamProducts(Map paramMap){ return super.queryForList("GROUP_DREAM.queryDreamProducts",paramMap); } }
[ "feiniu7903@163.com" ]
feiniu7903@163.com
7049c7378981c89be917d91ce5ef6e4f52089215
865d78e2bbf72225d96d3b79410b9fea1da0ea5c
/lab2/65436/minwdScrapper/src/main/java/pl/krzywyyy/Advertisement.java
7b4c845186de329a94f390a87f702032c31a8e0f
[]
no_license
Piotr1902/wat-minwd-i6b1s1
e1a9407cdbc8e2f3cb1f9d6ff4d6f8d874dcd3e5
5216b1677b74d11541503a0147c0b42bc4568c2b
refs/heads/master
2020-12-19T12:45:12.197167
2020-01-22T19:30:39
2020-01-22T19:30:39
null
0
0
null
null
null
null
UTF-8
Java
false
false
1,114
java
package pl.krzywyyy; import lombok.Builder; import lombok.Data; @Data @Builder class Advertisement { private String title; private String year; private String mileage; private String engineCapacity; private String fuelType; private String price; private String location; private String url; private String image; @Override public String toString() { return "\t{\n" + "\t\t\"Advertisement\": {\n" + "\t\t\t\"title\":\"" + title + "\",\n" + "\t\t\t\"year=\":" + year + ",\n" + "\t\t\t\"mileage\":\"" + mileage + "\",\n" + "\t\t\t\"engineCapacity\":" + (engineCapacity != null ? "\"" + engineCapacity + "\"" : "null") + ",\n" + "\t\t\t\"fuelType\":\"" + fuelType + "\",\n" + "\t\t\t\"price\":\"" + price + "\",\n" + "\t\t\t\"location\":\"" + location + "\",\n" + "\t\t\t\"url\":\"" + url + "\",\n" + "\t\t\t\"image\":\"" + image + "\"\n" + "\t\t}\n" + "\t},\n"; } }
[ "noreply@github.com" ]
Piotr1902.noreply@github.com
36aa3e8cf1493664f9d941f2722d4feef7b91931
3e4e13e87f3e004857cd14e1ba1350e81d036737
/Lab2/kprabhakLab2/part2/MR/src/main/java/Extractor/URLExtractor.java
7284daa56792f1a51e8edef4dad216d992098ff8
[]
no_license
KiranPrabhakar135/data-intensive-computing
aa933287aab8593dd5e62242a39e971e560da402
c5db4903a9933b49b77326cd78e49392d1525d0f
refs/heads/master
2022-09-20T13:40:02.244478
2020-08-02T23:04:12
2020-08-02T23:04:12
191,499,196
0
0
null
2022-09-01T23:08:28
2019-06-12T04:45:23
Python
UTF-8
Java
false
false
978
java
package Extractor; import NYTimes.Contract; import NYTimes.Docs; import NYTimes.JsonOperations; import NYTimes.Response; import java.util.ArrayList; import java.util.List; public class URLExtractor { public List<String> getUrls(String jsonFilePath){ List<String> urls = new ArrayList<String>(); JsonOperations jsonOperations = new JsonOperations(); List<Contract> data = jsonOperations.readFromFile(jsonFilePath); if(data != null && data.size() > 0){ for (Contract item : data) { Response response = item.getResponse(); if(response != null && response.docs != null && response.docs.size() > 0){ for (Docs doc :response.docs ) { if(doc.getWeb_url().contains("2019")){ urls.add(doc.getWeb_url() + "\n"); } } } } } return urls; } }
[ "kiranprabhakar135@gmail.com" ]
kiranprabhakar135@gmail.com
96a08ddddc39db254d9a3ce6a441d79244b80b8f
7a122905246c0738d8952c36a7a144c4e0cdc95d
/xml/ch-multi/simple-parent/simple-weather/src/main/java/org/sonatype/mavenbook/weather/YahooParser.java
bf4f4340d9e042015e4eee36d6202c4c99891761
[]
no_license
amritakoley/Projects
b2125825bfafcc6ea6719549635a051076772ccc
f93393b50fe1e055726182c37808e8d017734a4b
refs/heads/master
2021-01-22T18:10:43.687706
2014-04-20T04:21:27
2014-04-20T04:21:27
null
0
0
null
null
null
null
UTF-8
Java
false
false
1,601
java
package org.sonatype.mavenbook.weather; import java.io.InputStream; import java.util.HashMap; import java.util.Map; import org.apache.log4j.Logger; import org.dom4j.Document; import org.dom4j.DocumentFactory; import org.dom4j.io.SAXReader; public class YahooParser { private static Logger log = Logger.getLogger(YahooParser.class); public Weather parse(InputStream inputStream) throws Exception { Weather weather = new Weather(); log.info( "Creating XML Reader" ); SAXReader xmlReader = createXmlReader(); Document doc = xmlReader.read( inputStream ); log.info( "Parsing XML Response" ); weather.setCity( doc.valueOf("/rss/channel/y:location/@city") ); weather.setRegion( doc.valueOf("/rss/channel/y:location/@region") ); weather.setCountry( doc.valueOf("/rss/channel/y:location/@country") ); weather.setCondition( doc.valueOf("/rss/channel/item/y:condition/@text") ); weather.setTemp( doc.valueOf("/rss/channel/item/y:condition/@temp") ); weather.setChill( doc.valueOf("/rss/channel/y:wind/@chill") ); weather.setHumidity( doc.valueOf("/rss/channel/y:atmosphere/@humidity") ); if(weather.getCity() == "") { return null; } else{ return weather; } } private SAXReader createXmlReader() { Map<String,String> uris = new HashMap<String,String>(); uris.put( "y", "http://xml.weather.yahoo.com/ns/rss/1.0" ); DocumentFactory factory = new DocumentFactory(); factory.setXPathNamespaceURIs( uris ); SAXReader xmlReader = new SAXReader(); xmlReader.setDocumentFactory( factory ); return xmlReader; } }
[ "amrita.koley91@gmail.com" ]
amrita.koley91@gmail.com
293f2c0dd8dd7f0cc15b71a57935d686a1a4b127
d22166ae9c0353df9732d92c9f65e5f3c49f3a64
/MultiThreadTutorial/src/main/java/com/gpcoder/cyclicbarrier/ServiceThree.java
9c6e73cfabdd442242555f0b5677c3492bff0bed
[]
no_license
gpcodervn/Java-Tutorial
5d33749a5e5dde9ff6779d44dd858741c447217f
be1fb613930e2164d6f2f43ac3a411aee8cb19c9
refs/heads/master
2022-11-23T23:06:36.554383
2019-09-21T16:30:56
2019-09-21T16:30:56
116,023,494
22
17
null
2022-11-16T09:38:22
2018-01-02T14:26:32
Java
UTF-8
Java
false
false
785
java
package com.gpcoder.cyclicbarrier; import java.util.concurrent.CyclicBarrier; public class ServiceThree implements Runnable { private final CyclicBarrier cyclicBarrier; public ServiceThree(CyclicBarrier cyclicBarrier) { this.cyclicBarrier = cyclicBarrier; } @Override public void run() { System.out.println("Starting service Three...."); try { Thread.sleep(1000); } catch (InterruptedException e1) { e1.printStackTrace(); } System.out.println("Service Three has finished its work.. waiting for others..."); try { cyclicBarrier.await(); } catch (Exception e) { System.out.println("Service Three interrupted!"); e.printStackTrace(); } System.out.println("The wait is over, lets complete Service Three!"); } }
[ "ptgiang56@gmail.com" ]
ptgiang56@gmail.com
c753d38a6c0805505571da663fe16bf7e206e572
6be39fc2c882d0b9269f1530e0650fd3717df493
/weixin反编译/sources/com/tencent/mm/protocal/c/zg.java
16b1a23170be25b772c17431905fb0195cd4673c
[]
no_license
sir-deng/res
f1819af90b366e8326bf23d1b2f1074dfe33848f
3cf9b044e1f4744350e5e89648d27247c9dc9877
refs/heads/master
2022-06-11T21:54:36.725180
2020-05-07T06:03:23
2020-05-07T06:03:23
155,177,067
5
0
null
null
null
null
UTF-8
Java
false
false
3,125
java
package com.tencent.mm.protocal.c; import e.a.a.c.a; import java.util.LinkedList; public final class zg extends bea { public String fGh; public LinkedList<alg> wpV = new LinkedList(); protected final int a(int i, Object... objArr) { int fW; byte[] bArr; if (i == 0) { a aVar = (a) objArr[0]; if (this.wQE != null) { aVar.fZ(1, this.wQE.bkL()); this.wQE.a(aVar); } aVar.d(2, 8, this.wpV); if (this.fGh == null) { return 0; } aVar.g(3, this.fGh); return 0; } else if (i == 1) { if (this.wQE != null) { fW = e.a.a.a.fW(1, this.wQE.bkL()) + 0; } else { fW = 0; } fW += e.a.a.a.c(2, 8, this.wpV); if (this.fGh != null) { fW += e.a.a.b.b.a.h(3, this.fGh); } return fW; } else if (i == 2) { bArr = (byte[]) objArr[0]; this.wpV.clear(); e.a.a.a.a aVar2 = new e.a.a.a.a(bArr, unknownTagHandler); for (fW = com.tencent.mm.bp.a.a(aVar2); fW > 0; fW = com.tencent.mm.bp.a.a(aVar2)) { if (!super.a(aVar2, this, fW)) { aVar2.cKx(); } } return 0; } else if (i != 3) { return -1; } else { e.a.a.a.a aVar3 = (e.a.a.a.a) objArr[0]; zg zgVar = (zg) objArr[1]; int intValue = ((Integer) objArr[2]).intValue(); LinkedList JD; int size; com.tencent.mm.bp.a fhVar; e.a.a.a.a aVar4; boolean z; switch (intValue) { case 1: JD = aVar3.JD(intValue); size = JD.size(); for (intValue = 0; intValue < size; intValue++) { bArr = (byte[]) JD.get(intValue); fhVar = new fh(); aVar4 = new e.a.a.a.a(bArr, unknownTagHandler); for (z = true; z; z = fhVar.a(aVar4, fhVar, com.tencent.mm.bp.a.a(aVar4))) { } zgVar.wQE = fhVar; } return 0; case 2: JD = aVar3.JD(intValue); size = JD.size(); for (intValue = 0; intValue < size; intValue++) { bArr = (byte[]) JD.get(intValue); fhVar = new alg(); aVar4 = new e.a.a.a.a(bArr, unknownTagHandler); for (z = true; z; z = fhVar.a(aVar4, fhVar, com.tencent.mm.bp.a.a(aVar4))) { } zgVar.wpV.add(fhVar); } return 0; case 3: zgVar.fGh = aVar3.AEQ.readString(); return 0; default: return -1; } } } }
[ "denghailong@vargo.com.cn" ]
denghailong@vargo.com.cn
e995e44e0013c7e234b5d0ec425300192c71f056
09da1324657b81904eec52e9c7b8cae331495b95
/commons-officetools/src/main/java/de/egladil/web/commons_officetools/openoffice/ods/ODSContentReader.java
61659902a151d03803b8ef981d004ded4a54fb8f
[]
no_license
heike2718/hewi-java-commons
b5c5a95c8c4b80102f4e942c0ec9fed983f9eb8b
ac0fdeca901c7ba69eb65f1a38cd34b36c748b36
refs/heads/develop
2023-08-29T11:45:40.348462
2023-08-06T15:52:15
2023-08-06T15:52:15
219,120,562
0
0
null
2023-09-14T19:48:00
2019-11-02T07:38:42
Java
UTF-8
Java
false
false
1,304
java
// ===================================================== // Project: commons-officetools // (c) Heike Winkelvoß // ===================================================== package de.egladil.web.commons_officetools.openoffice.ods; import java.io.IOException; import java.io.InputStream; import java.util.List; import javax.xml.parsers.ParserConfigurationException; import javax.xml.stream.XMLStreamException; import org.xml.sax.SAXException; import de.egladil.web.commons_officetools.exceptions.OfficeToolsRuntimeException; import de.egladil.web.commons_officetools.impl.AbstractTableDocumentContentReader; /** * ODSContentReader */ public class ODSContentReader extends AbstractTableDocumentContentReader { @Override public List<String> readContentAsLines(final InputStream in) { try { ODSParser odsParser = new ODSParser(); final String xml = odsParser.getContentSafe(in, 6000000); final List<OpenOfficeTableElement> extrahierteElemente = odsParser.parseContent(xml); // Act List<String> zeilen = new OORows2LinesMapper().apply(extrahierteElemente); return zeilen; } catch (IOException | XMLStreamException | ParserConfigurationException | SAXException e) { throw new OfficeToolsRuntimeException("Fehler beim Lesen der ODF-Datei: " + e.getMessage(), e); } } }
[ "public@egladil.de" ]
public@egladil.de
8fb2acebcf4e9c56024c034283459111ec7bca6b
0d616c734ae4d8a6d5f04a28d3845e7ce4281143
/uebung5/FeldManipulation.java
ed38e718103cb3782c22395879e46fa2daba79e0
[ "MIT" ]
permissive
stanchevv/Java-FDIBA
3bc54bd3d52c4311858d07d91b554128f700dc75
1746cae0ff3cab7a2be4a2544e8702863496dcae
refs/heads/master
2020-05-19T23:56:16.551257
2019-05-06T22:03:06
2019-05-06T22:03:06
185,277,915
0
0
null
null
null
null
UTF-8
Java
false
false
2,447
java
package uebung5; import java.util.HashSet; import java.util.Scanner; public class FeldManipulation { public static void main(String[] args) { Scanner scanner = new Scanner(System.in); int[] array = new int[5]; eingabe(array); ausgabe(array); System.out.println("maximum number = "+max(array)); System.out.println("index of min number = "+indexOfMin(array)); array = reverse(array); ausgabe(array); linearSearch(array,2); linearSearch(array,6); array = removeDuplicates(array); ausgabe(array); } public static void eingabe(int[] array) { Scanner scanner = new Scanner(System.in); for (int i = 0; i < array.length; i++) { System.out.println("Enter a number:"); array[i]=scanner.nextInt(); } } public static void ausgabe(int[] array) { for (int i = 0; i < array.length; i++) { System.out.println(i+" "+array[i]); } } public static int max(int[] array){ int max = array[0]; for (int i = 1; i < array.length; i++) { if (array[i]>max){ max=array[i]; } } return max; } public static int indexOfMin(int[] array){ int min = array[0]; int index = 0; for (int i = 1; i < array.length; i++) { if (array[i]<min){ min=array[i]; index = i; } } return index; } public static int[] reverse(int[] array){ int[] reversedArray = new int[array.length]; for (int i = 0; i < array.length; i++) { reversedArray[i]=array[array.length-1-i]; } return reversedArray; } public static int linearSearch(int[] array, int element){ int index = -1; for (int i = 0; i < array.length; i++) { if (array[i]==element){ index=i; } } return index; } public static int[] removeDuplicates(int[] array){ HashSet<Integer> uniqueValues = new HashSet<Integer>(); for (int i = 0; i < array.length; i++) { uniqueValues.add(array[i]); } int[] result = new int[uniqueValues.size()]; int counter = 0; for (int u:uniqueValues ) { result[counter]=u; } return result; } }
[ "stanvchev@gmail.com" ]
stanvchev@gmail.com
d6a483b237e1fda70c1067f282576e774f14e302
713607c56fff31b58bcc408e2b19dc4de7aebf67
/PCS_Project/src/org/kale/pcs/pages/Create_EDO_ImportPage_SL_Login.java
1aedf8a3c48b76695c759297935950de8cbe1769
[]
no_license
vivekanandkoli/PCS_Repo
63a1fcca2221b6f887f9df2800195e76d84fe805
20c44a7d2b2cf7a192824cf41ecc2ab604eca914
refs/heads/master
2020-05-29T15:06:26.177645
2019-06-11T05:56:32
2019-06-11T05:56:32
189,211,701
0
0
null
null
null
null
UTF-8
Java
false
false
2,454
java
package org.kale.pcs.pages; import org.kale.pcs.sdk.Variables_Declaration; import org.kale.pcs.utils.General_Methods; import org.kale.pcs.utils.Validate_Elements; import org.openqa.selenium.By; import org.openqa.selenium.WebDriver; import org.openqa.selenium.WebElement; import org.openqa.selenium.interactions.Actions; public class Create_EDO_ImportPage_SL_Login { WebDriver driver; Variables_Declaration vd=new Variables_Declaration(); General_Methods gm=new General_Methods(); Validate_Elements ve=new Validate_Elements(); public Create_EDO_ImportPage_SL_Login(WebDriver dr) { driver=dr; } public void Create_EDO(String SC_ID,String Description,String ExcelSavePath,String Invoice_No, String Invoice_Date,String Charge_Head,String Exchange_Currency_Amt,String Currency, String Exchange_Rate) throws Exception { driver.findElement(By.id("ctl00_lblMode")).click(); Actions action = new Actions(driver); WebElement element = driver.findElement(By.id("ctl00_lnkForwarding")); action.moveToElement(element).build().perform(); driver.findElement(By.id("ctl00_liFFImport")).click(); driver.findElement(By.xpath("//a[contains(.,'DO DashBoard')]")).click(); driver.findElement(By.id("ctl00_hldPage_grdDORequest_ctl02_lnkDoRequestNo")).click(); driver.findElement(By.id("ctl00_hldPage_btnDOFee")).click(); driver.findElement(By.id("ctl00_hldPage_grdInvocieDetails_ctl02_txtInvoiceNo")).sendKeys(Invoice_No); driver.findElement(By.id("ctl00_hldPage_grdInvocieDetails_ctl02_txtInvoiceDate")).sendKeys(Invoice_Date); driver.findElement(By.id("ctl00_hldPage_grdInvocieDetails_ctl02_ImgAddCharge")).click(); org.openqa.selenium.support.ui.Select Cbo_Charge_Head=new org.openqa.selenium.support.ui.Select(driver.findElement(By.id("ctl00_hldPage_rptInvDetails_ctl01_drpChargeHead"))); Cbo_Charge_Head.selectByVisibleText(Charge_Head); driver.findElement(By.id("ctl00_hldPage_rptInvDetails_ctl01_txtAmtUSD")).sendKeys(Exchange_Currency_Amt); org.openqa.selenium.support.ui.Select Cbo_Currency=new org.openqa.selenium.support.ui.Select(driver.findElement(By.id("ctl00_hldPage_rptInvDetails_ctl01_drpCurrency"))); Cbo_Currency.selectByVisibleText(Currency); driver.findElement(By.id("ctl00_hldPage_rptInvDetails_ctl01_txtExchangeRate")).sendKeys(Exchange_Rate); driver.findElement(By.id("ctl00_hldPage_btnPopupChrgSaveClose")).click(); } }
[ "vivekananand.koli.central@gmail.com" ]
vivekananand.koli.central@gmail.com
23f586d2b03b11251c8322970aa53a9a271c5d00
ff4c533bb90b81cd4da61ae0046a325a20a3a901
/RecursionProblems/src/com/example/rec/factorial/Count7.java
b54c7db153624299f88224086ab5fb609df91fce
[]
no_license
KAditi/Data-Structure-Algorithm-Java-Prog
1f8d30f8b75e4d23fadd6f69b7f1c3e50992c3a3
eb2f9f9585fa29851cf3b1b8ec60de5ce6d2a09c
refs/heads/master
2021-01-20T19:56:52.564748
2016-07-12T06:22:51
2016-07-12T06:22:51
60,556,433
2
0
null
null
null
null
UTF-8
Java
false
false
369
java
package com.example.rec.factorial; public class Count7 { public int count7(int n) { if(n==7) return 1; if(n == 0) return 0; if(n%10 == 7) return 1+count7(n/10); else return count7(n/10); } public static void main(String[] args) { Count7 count = new Count7(); System.out.println("Count:\t"+count.count7(7246)); } }
[ "kartiki.aditi@gmail.com" ]
kartiki.aditi@gmail.com
9fbecb673b105c8573a3e9b2db6e7891371d88a2
cb9992fd8a8005056a67c783aa46086c8e55290f
/hudi-common/src/main/java/org/apache/hudi/common/config/EnumDescription.java
2cba8987b762c95e581de078185ff061c282a1b1
[ "CC0-1.0", "MIT", "JSON", "Apache-2.0", "LicenseRef-scancode-warranty-disclaimer" ]
permissive
apache/hudi
cb3f365f40570357777e9d6e83b93c554f50e707
0e50d7586a7719eab870c8d83e3566bb549d64b6
refs/heads/master
2023-09-02T14:55:11.040855
2023-09-02T11:06:37
2023-09-02T11:06:37
76,474,200
3,615
1,833
Apache-2.0
2023-09-14T19:03:11
2016-12-14T15:53:41
Java
UTF-8
Java
false
false
1,474
java
/* * Licensed to the Apache Software Foundation (ASF) under one * or more contributor license agreements. See the NOTICE file * distributed with this work for additional information * regarding copyright ownership. The ASF licenses this file * to you under the Apache License, Version 2.0 (the * "License"); you may not use this file except in compliance * with the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ package org.apache.hudi.common.config; import java.lang.annotation.Documented; import java.lang.annotation.ElementType; import java.lang.annotation.Retention; import java.lang.annotation.RetentionPolicy; import java.lang.annotation.Target; /** * For any enum that is going to be used as a config value, * add this annotation by adding @EnumDescription("Your description here.") * directly above the enum class declaration. * Then in your config property add .withDocumentation(YourEnum.class) * see EnumFieldDescription.java */ @Documented @Retention(RetentionPolicy.RUNTIME) @Target(ElementType.TYPE) public @interface EnumDescription { String value(); }
[ "noreply@github.com" ]
apache.noreply@github.com
1c859034a41d9ffe131631a2ccc1707ff3e3ddc8
5406859a5e848429a13f3e14e8fcbcc23a5355a0
/src/utility/MissJava.java
111924ca251088abeb5531e4c979454af6d0a5ce
[]
no_license
johnny376/Summer2020_B20_git
fa2698e6b62bc03b6de31c46b2e4170eea3ce278
9632a8f8e2e3a7a76430c508f0732290bfbf712c
refs/heads/master
2022-11-25T07:38:27.732413
2020-08-06T01:47:49
2020-08-06T01:47:49
285,436,107
0
0
null
null
null
null
UTF-8
Java
false
false
142
java
package utility; public class MissJava { public static void main(String[] args) { System.out.println("I miss Java"); } }
[ "shawkat101@hotmail.com" ]
shawkat101@hotmail.com
cb7b7ad067dcd9fc542b85ad671b216a1af37098
c7e000e5c6549e095a8ffd032d33e0ca449c7ffd
/bin/platform/bootstrap/gensrc/de/hybris/platform/commercefacades/order/data/OrderHistoriesData.java
a172a53b3386eb64d416b2aa64115c7fd8e1761c
[]
no_license
J3ys/million
e80ff953e228e4bc43a1108a1c117ddf11cc4644
a97974b68b4adaf820f9024aa5181de635c60b4f
refs/heads/master
2021-03-09T22:59:35.115273
2015-05-19T02:47:29
2015-05-19T02:47:29
null
0
0
null
null
null
null
UTF-8
Java
false
false
2,062
java
/* * ---------------------------------------------------------------- * --- WARNING: THIS FILE IS GENERATED AND WILL BE OVERWRITTEN! * --- Generated at 2015/05/18 13:25:59 * ---------------------------------------------------------------- * * [y] hybris Platform * * Copyright (c) 2000-2013 hybris AG * All rights reserved. * * This software is the confidential and proprietary information of hybris * ("Confidential Information"). You shall not disclose such Confidential * Information and shall use it only in accordance with the terms of the * license agreement you entered into with hybris. * * */ package de.hybris.platform.commercefacades.order.data; import de.hybris.platform.commercefacades.order.data.OrderHistoryData; import de.hybris.platform.commerceservices.search.pagedata.PaginationData; import de.hybris.platform.commerceservices.search.pagedata.SortData; import java.util.List; public class OrderHistoriesData implements java.io.Serializable { /** <i>Generated property</i> for <code>OrderHistoriesData.orders</code> property defined at extension <code>commercefacades</code>. */ private List<OrderHistoryData> orders; /** <i>Generated property</i> for <code>OrderHistoriesData.pagination</code> property defined at extension <code>commercefacades</code>. */ private PaginationData pagination; /** <i>Generated property</i> for <code>OrderHistoriesData.sorts</code> property defined at extension <code>commercefacades</code>. */ private List<SortData> sorts; public OrderHistoriesData() { // default constructor } public void setOrders(final List<OrderHistoryData> orders) { this.orders = orders; } public List<OrderHistoryData> getOrders() { return orders; } public void setPagination(final PaginationData pagination) { this.pagination = pagination; } public PaginationData getPagination() { return pagination; } public void setSorts(final List<SortData> sorts) { this.sorts = sorts; } public List<SortData> getSorts() { return sorts; } }
[ "yanagisawa@gotandadenshi.jp" ]
yanagisawa@gotandadenshi.jp
a9941e67ad9755f58ec21b27439253f2beb6a2e1
6f734c0e3a964e7dc81a48e187e19a612516f1d0
/app/build/generated/not_namespaced_r_class_sources/debug/processDebugResources/r/androidx/drawerlayout/R.java
49e11863a2c727302641ce5dc6ac11ef84208944
[]
no_license
marsanchezs/ScanAPP
95985f42e0a91138e4509ce7e3c55a33e704e700
3088fbaa6d444ca3575c6cdb6bdf320ca822d0ac
refs/heads/master
2023-06-03T17:47:26.228286
2021-06-23T15:53:53
2021-06-23T15:53:53
375,847,219
0
0
null
null
null
null
UTF-8
Java
false
false
10,541
java
/* AUTO-GENERATED FILE. DO NOT MODIFY. * * This class was automatically generated by the * gradle plugin from the resource data it found. It * should not be modified by hand. */ package androidx.drawerlayout; public final class R { private R() {} public static final class attr { private attr() {} public static final int alpha = 0x7f030028; public static final int font = 0x7f030165; public static final int fontProviderAuthority = 0x7f030167; public static final int fontProviderCerts = 0x7f030168; public static final int fontProviderFetchStrategy = 0x7f030169; public static final int fontProviderFetchTimeout = 0x7f03016a; public static final int fontProviderPackage = 0x7f03016b; public static final int fontProviderQuery = 0x7f03016c; public static final int fontStyle = 0x7f03016e; public static final int fontVariationSettings = 0x7f03016f; public static final int fontWeight = 0x7f030170; public static final int ttcIndex = 0x7f03036e; } public static final class color { private color() {} public static final int notification_action_color_filter = 0x7f0500c1; public static final int notification_icon_bg_color = 0x7f0500c2; public static final int ripple_material_light = 0x7f0500ce; public static final int secondary_text_default_material_light = 0x7f0500d0; } public static final class dimen { private dimen() {} public static final int compat_button_inset_horizontal_material = 0x7f060054; public static final int compat_button_inset_vertical_material = 0x7f060055; public static final int compat_button_padding_horizontal_material = 0x7f060056; public static final int compat_button_padding_vertical_material = 0x7f060057; public static final int compat_control_corner_material = 0x7f060058; public static final int compat_notification_large_icon_max_height = 0x7f060059; public static final int compat_notification_large_icon_max_width = 0x7f06005a; public static final int notification_action_icon_size = 0x7f060181; public static final int notification_action_text_size = 0x7f060182; public static final int notification_big_circle_margin = 0x7f060183; public static final int notification_content_margin_start = 0x7f060184; public static final int notification_large_icon_height = 0x7f060185; public static final int notification_large_icon_width = 0x7f060186; public static final int notification_main_column_padding_top = 0x7f060187; public static final int notification_media_narrow_margin = 0x7f060188; public static final int notification_right_icon_size = 0x7f060189; public static final int notification_right_side_padding_top = 0x7f06018a; public static final int notification_small_icon_background_padding = 0x7f06018b; public static final int notification_small_icon_size_as_large = 0x7f06018c; public static final int notification_subtext_size = 0x7f06018d; public static final int notification_top_pad = 0x7f06018e; public static final int notification_top_pad_large_text = 0x7f06018f; } public static final class drawable { private drawable() {} public static final int notification_action_background = 0x7f0700a0; public static final int notification_bg = 0x7f0700a1; public static final int notification_bg_low = 0x7f0700a2; public static final int notification_bg_low_normal = 0x7f0700a3; public static final int notification_bg_low_pressed = 0x7f0700a4; public static final int notification_bg_normal = 0x7f0700a5; public static final int notification_bg_normal_pressed = 0x7f0700a6; public static final int notification_icon_background = 0x7f0700a7; public static final int notification_template_icon_bg = 0x7f0700a8; public static final int notification_template_icon_low_bg = 0x7f0700a9; public static final int notification_tile_bg = 0x7f0700aa; public static final int notify_panel_notification_icon_bg = 0x7f0700ab; } public static final class id { private id() {} public static final int action_container = 0x7f090038; public static final int action_divider = 0x7f09003a; public static final int action_image = 0x7f09003b; public static final int action_text = 0x7f090041; public static final int actions = 0x7f090042; public static final int async = 0x7f09004d; public static final int blocking = 0x7f09005f; public static final int chronometer = 0x7f0900a1; public static final int forever = 0x7f0900f4; public static final int icon = 0x7f090103; public static final int icon_group = 0x7f090104; public static final int info = 0x7f09010f; public static final int italic = 0x7f090112; public static final int line1 = 0x7f090124; public static final int line3 = 0x7f090125; public static final int normal = 0x7f09017a; public static final int notification_background = 0x7f09017b; public static final int notification_main_column = 0x7f09017c; public static final int notification_main_column_container = 0x7f09017d; public static final int right_icon = 0x7f09019d; public static final int right_side = 0x7f09019e; public static final int tag_transition_group = 0x7f0901e8; public static final int tag_unhandled_key_event_manager = 0x7f0901e9; public static final int tag_unhandled_key_listeners = 0x7f0901ea; public static final int text = 0x7f0901f0; public static final int text2 = 0x7f0901f1; public static final int time = 0x7f090206; public static final int title = 0x7f090207; } public static final class integer { private integer() {} public static final int status_bar_notification_info_maxnum = 0x7f0a001b; } public static final class layout { private layout() {} public static final int notification_action = 0x7f0c006e; public static final int notification_action_tombstone = 0x7f0c006f; public static final int notification_template_custom_big = 0x7f0c0076; public static final int notification_template_icon_group = 0x7f0c0077; public static final int notification_template_part_chronometer = 0x7f0c007b; public static final int notification_template_part_time = 0x7f0c007c; } public static final class string { private string() {} public static final int status_bar_notification_info_overflow = 0x7f1000a8; } public static final class style { private style() {} public static final int TextAppearance_Compat_Notification = 0x7f110162; public static final int TextAppearance_Compat_Notification_Info = 0x7f110163; public static final int TextAppearance_Compat_Notification_Line2 = 0x7f110165; public static final int TextAppearance_Compat_Notification_Time = 0x7f110168; public static final int TextAppearance_Compat_Notification_Title = 0x7f11016a; public static final int Widget_Compat_NotificationActionContainer = 0x7f110252; public static final int Widget_Compat_NotificationActionText = 0x7f110253; } public static final class styleable { private styleable() {} public static final int[] ColorStateListItem = { 0x10101a5, 0x101031f, 0x7f030028 }; public static final int ColorStateListItem_android_color = 0; public static final int ColorStateListItem_android_alpha = 1; public static final int ColorStateListItem_alpha = 2; public static final int[] FontFamily = { 0x7f030167, 0x7f030168, 0x7f030169, 0x7f03016a, 0x7f03016b, 0x7f03016c, 0x7f03016d }; public static final int FontFamily_fontProviderAuthority = 0; public static final int FontFamily_fontProviderCerts = 1; public static final int FontFamily_fontProviderFetchStrategy = 2; public static final int FontFamily_fontProviderFetchTimeout = 3; public static final int FontFamily_fontProviderPackage = 4; public static final int FontFamily_fontProviderQuery = 5; public static final int FontFamily_fontProviderSystemFontFamily = 6; public static final int[] FontFamilyFont = { 0x1010532, 0x1010533, 0x101053f, 0x101056f, 0x1010570, 0x7f030165, 0x7f03016e, 0x7f03016f, 0x7f030170, 0x7f03036e }; public static final int FontFamilyFont_android_font = 0; public static final int FontFamilyFont_android_fontWeight = 1; public static final int FontFamilyFont_android_fontStyle = 2; public static final int FontFamilyFont_android_ttcIndex = 3; public static final int FontFamilyFont_android_fontVariationSettings = 4; public static final int FontFamilyFont_font = 5; public static final int FontFamilyFont_fontStyle = 6; public static final int FontFamilyFont_fontVariationSettings = 7; public static final int FontFamilyFont_fontWeight = 8; public static final int FontFamilyFont_ttcIndex = 9; public static final int[] GradientColor = { 0x101019d, 0x101019e, 0x10101a1, 0x10101a2, 0x10101a3, 0x10101a4, 0x1010201, 0x101020b, 0x1010510, 0x1010511, 0x1010512, 0x1010513 }; public static final int GradientColor_android_startColor = 0; public static final int GradientColor_android_endColor = 1; public static final int GradientColor_android_type = 2; public static final int GradientColor_android_centerX = 3; public static final int GradientColor_android_centerY = 4; public static final int GradientColor_android_gradientRadius = 5; public static final int GradientColor_android_tileMode = 6; public static final int GradientColor_android_centerColor = 7; public static final int GradientColor_android_startX = 8; public static final int GradientColor_android_startY = 9; public static final int GradientColor_android_endX = 10; public static final int GradientColor_android_endY = 11; public static final int[] GradientColorItem = { 0x10101a5, 0x1010514 }; public static final int GradientColorItem_android_color = 0; public static final int GradientColorItem_android_offset = 1; } }
[ "marsanchezs@gmail.com" ]
marsanchezs@gmail.com
4e80a0df387a2d5ce6f7c24b978975e0d41374ea
1343608fb0baac9ad816d9d3a30417072e1cc048
/src/org/arc/dao/impl/TokenDaoImpl.java
7ce5ec3642df247d2a248219fb8a0627e90f4fe8
[ "Apache-2.0" ]
permissive
qkmc-rk/pandafertService
20b7b83050675fb5945c5d5f9d9bfc6a8e1d2560
4d1ea088c7c58d7a60ff0ed1ef4478380d4bcbb9
refs/heads/master
2021-07-23T03:52:30.834021
2017-11-04T10:10:40
2017-11-04T10:10:40
109,481,008
0
0
null
null
null
null
GB18030
Java
false
false
2,484
java
package org.arc.dao.impl; import java.sql.SQLException; import java.util.List; import org.apache.commons.dbutils.QueryRunner; import org.arc.dao.TokenDao; import org.arc.entity.Token; import org.arc.util.JdbcUtilC3p0; /** * @author Mrruan E-mail:qkmc@outlook.com * @version 创建时间:2017年10月29日 下午12:38:04 */ public class TokenDaoImpl implements TokenDao { @Override public int addOneToken(Token token) { //创建qr对象 QueryRunner qr = new QueryRunner(JdbcUtilC3p0.getDataSource()); //准备sql String sql = "insert into t_token(token,user_id)values(?,?)"; try { int update = qr.update(sql, token.getToken(),token.getUserId()); return update; } catch (SQLException e) { e.printStackTrace(); } return 0; } @Override public int deleteOneTokenByUserId(int userId) { QueryRunner qr = new QueryRunner(JdbcUtilC3p0.getDataSource()); String sql = "delete from t_token where user_id = ?"; try { int update = qr.update(sql, userId); return update; } catch (SQLException e) { e.printStackTrace(); } return 0; } @Override public int updateOneToken(Token token) { QueryRunner qr = new QueryRunner(JdbcUtilC3p0.getDataSource()); String sql = "update t_token set token = ?,user_id = ? where token_id=?"; try { int update = qr.update(sql, token.getToken(),token.getUserId(),token.getTokenId()); return update; } catch (SQLException e) { e.printStackTrace(); } return 0; } @Override public Token queryOneTokenByUserId(int uId) { QueryRunner qr = new QueryRunner(JdbcUtilC3p0.getDataSource()); String sql = "select * from t_token where user_id = ?"; try { List<Token> tokenlist = qr.query(sql, new TokenHandler(),uId); Token token = tokenlist.get(0); return token; } catch (SQLException e) { e.printStackTrace(); } return null; } @Override public List<Token> queryAll() { QueryRunner qr = new QueryRunner(JdbcUtilC3p0.getDataSource()); String sql = "select * from t_token"; try { List<Token> tokenlist = qr.query(sql, new TokenHandler()); return tokenlist; } catch (SQLException e) { e.printStackTrace(); } return null; } @Override public boolean deleteOneTokenByTokenId(int tokenId) { QueryRunner qr = new QueryRunner(JdbcUtilC3p0.getDataSource()); String sql = "delete from t_token where token_id = ?"; try { qr.update(sql, tokenId); return true; } catch (SQLException e) { e.printStackTrace(); } return false; } }
[ "qkmc@outlook.com" ]
qkmc@outlook.com
86af5f26813656c904833b57e42e80b0201fad0a
6baa09045c69b0231c35c22b06cdf69a8ce227d6
/modules/dfp_appengine/src/main/java/com/google/api/ads/dfp/jaxws/v201602/ProposalLink.java
47c798bee0236878ee628a7cee29dfa5216d96a3
[ "Apache-2.0" ]
permissive
remotejob/googleads-java-lib
f603b47117522104f7df2a72d2c96ae8c1ea011d
a330df0799de8d8de0dcdddf4c317d6b0cd2fe10
refs/heads/master
2020-12-11T01:36:29.506854
2016-07-28T22:13:24
2016-07-28T22:13:24
null
0
0
null
null
null
null
UTF-8
Java
false
false
4,513
java
package com.google.api.ads.dfp.jaxws.v201602; import javax.xml.bind.annotation.XmlAccessType; import javax.xml.bind.annotation.XmlAccessorType; import javax.xml.bind.annotation.XmlType; /** * * A link that can be added as a resource to a {@link Proposal}. * * * <p>Java class for ProposalLink complex type. * * <p>The following schema fragment specifies the expected content contained within this class. * * <pre> * &lt;complexType name="ProposalLink"> * &lt;complexContent> * &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"> * &lt;sequence> * &lt;element name="id" type="{http://www.w3.org/2001/XMLSchema}long" minOccurs="0"/> * &lt;element name="name" type="{http://www.w3.org/2001/XMLSchema}string" minOccurs="0"/> * &lt;element name="creatorId" type="{http://www.w3.org/2001/XMLSchema}long" minOccurs="0"/> * &lt;element name="url" type="{http://www.w3.org/2001/XMLSchema}string" minOccurs="0"/> * &lt;element name="description" type="{http://www.w3.org/2001/XMLSchema}string" minOccurs="0"/> * &lt;element name="creationDateTime" type="{https://www.google.com/apis/ads/publisher/v201602}DateTime" minOccurs="0"/> * &lt;/sequence> * &lt;/restriction> * &lt;/complexContent> * &lt;/complexType> * </pre> * * */ @XmlAccessorType(XmlAccessType.FIELD) @XmlType(name = "ProposalLink", propOrder = { "id", "name", "creatorId", "url", "description", "creationDateTime" }) public class ProposalLink { protected Long id; protected String name; protected Long creatorId; protected String url; protected String description; protected DateTime creationDateTime; /** * Gets the value of the id property. * * @return * possible object is * {@link Long } * */ public Long getId() { return id; } /** * Sets the value of the id property. * * @param value * allowed object is * {@link Long } * */ public void setId(Long value) { this.id = value; } /** * Gets the value of the name property. * * @return * possible object is * {@link String } * */ public String getName() { return name; } /** * Sets the value of the name property. * * @param value * allowed object is * {@link String } * */ public void setName(String value) { this.name = value; } /** * Gets the value of the creatorId property. * * @return * possible object is * {@link Long } * */ public Long getCreatorId() { return creatorId; } /** * Sets the value of the creatorId property. * * @param value * allowed object is * {@link Long } * */ public void setCreatorId(Long value) { this.creatorId = value; } /** * Gets the value of the url property. * * @return * possible object is * {@link String } * */ public String getUrl() { return url; } /** * Sets the value of the url property. * * @param value * allowed object is * {@link String } * */ public void setUrl(String value) { this.url = value; } /** * Gets the value of the description property. * * @return * possible object is * {@link String } * */ public String getDescription() { return description; } /** * Sets the value of the description property. * * @param value * allowed object is * {@link String } * */ public void setDescription(String value) { this.description = value; } /** * Gets the value of the creationDateTime property. * * @return * possible object is * {@link DateTime } * */ public DateTime getCreationDateTime() { return creationDateTime; } /** * Sets the value of the creationDateTime property. * * @param value * allowed object is * {@link DateTime } * */ public void setCreationDateTime(DateTime value) { this.creationDateTime = value; } }
[ "api.cseeley@gmail.com" ]
api.cseeley@gmail.com
2ec8133ca908e996f7513023e6636f3950dc0e01
f55c7b6e9b0b7904b26bb6dedbfca066e4b69ec9
/modules/adwords_appengine/src/main/java/com/google/api/ads/adwords/jaxws/v201502/cm/LabelError.java
db9f75e6281183eaaefeda53fbbc5b8353b74e3a
[ "Apache-2.0" ]
permissive
startuprockstar/googleads-java-lib
774f1672542be3589b4baaba5fc52f266200b36d
0c7253507172b7d83fe5ede4ac7ee8183214a3a0
refs/heads/master
2021-01-21T03:29:23.323814
2015-10-28T18:14:08
2015-10-28T18:14:08
null
0
0
null
null
null
null
UTF-8
Java
false
false
1,616
java
package com.google.api.ads.adwords.jaxws.v201502.cm; import javax.xml.bind.annotation.XmlAccessType; import javax.xml.bind.annotation.XmlAccessorType; import javax.xml.bind.annotation.XmlSchemaType; import javax.xml.bind.annotation.XmlType; /** * * Base error class for LabelService. * * * <p>Java class for LabelError complex type. * * <p>The following schema fragment specifies the expected content contained within this class. * * <pre> * &lt;complexType name="LabelError"> * &lt;complexContent> * &lt;extension base="{https://adwords.google.com/api/adwords/cm/v201502}ApiError"> * &lt;sequence> * &lt;element name="reason" type="{https://adwords.google.com/api/adwords/cm/v201502}LabelError.Reason" minOccurs="0"/> * &lt;/sequence> * &lt;/extension> * &lt;/complexContent> * &lt;/complexType> * </pre> * * */ @XmlAccessorType(XmlAccessType.FIELD) @XmlType(name = "LabelError", propOrder = { "reason" }) public class LabelError extends ApiError { @XmlSchemaType(name = "string") protected LabelErrorReason reason; /** * Gets the value of the reason property. * * @return * possible object is * {@link LabelErrorReason } * */ public LabelErrorReason getReason() { return reason; } /** * Sets the value of the reason property. * * @param value * allowed object is * {@link LabelErrorReason } * */ public void setReason(LabelErrorReason value) { this.reason = value; } }
[ "jradcliff@google.com" ]
jradcliff@google.com
404306677f88b50a9c07bd3e2211faac94196a09
e9affefd4e89b3c7e2064fee8833d7838c0e0abc
/aws-java-sdk-glue/src/main/java/com/amazonaws/services/glue/model/transform/AmazonRedshiftSourceMarshaller.java
b395f69cf71e82acdffc07e6e408007b924a332d
[ "Apache-2.0" ]
permissive
aws/aws-sdk-java
2c6199b12b47345b5d3c50e425dabba56e279190
bab987ab604575f41a76864f755f49386e3264b4
refs/heads/master
2023-08-29T10:49:07.379135
2023-08-28T21:05:55
2023-08-28T21:05:55
574,877
3,695
3,092
Apache-2.0
2023-09-13T23:35:28
2010-03-22T23:34:58
null
UTF-8
Java
false
false
2,280
java
/* * Copyright 2018-2023 Amazon.com, Inc. or its affiliates. All Rights Reserved. * * Licensed under the Apache License, Version 2.0 (the "License"). You may not use this file except in compliance with * the License. A copy of the License is located at * * http://aws.amazon.com/apache2.0 * * or in the "license" file accompanying this file. This file is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR * CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions * and limitations under the License. */ package com.amazonaws.services.glue.model.transform; import javax.annotation.Generated; import com.amazonaws.SdkClientException; import com.amazonaws.services.glue.model.*; import com.amazonaws.protocol.*; import com.amazonaws.annotation.SdkInternalApi; /** * AmazonRedshiftSourceMarshaller */ @Generated("com.amazonaws:aws-java-sdk-code-generator") @SdkInternalApi public class AmazonRedshiftSourceMarshaller { private static final MarshallingInfo<String> NAME_BINDING = MarshallingInfo.builder(MarshallingType.STRING).marshallLocation(MarshallLocation.PAYLOAD) .marshallLocationName("Name").build(); private static final MarshallingInfo<StructuredPojo> DATA_BINDING = MarshallingInfo.builder(MarshallingType.STRUCTURED) .marshallLocation(MarshallLocation.PAYLOAD).marshallLocationName("Data").build(); private static final AmazonRedshiftSourceMarshaller instance = new AmazonRedshiftSourceMarshaller(); public static AmazonRedshiftSourceMarshaller getInstance() { return instance; } /** * Marshall the given parameter object. */ public void marshall(AmazonRedshiftSource amazonRedshiftSource, ProtocolMarshaller protocolMarshaller) { if (amazonRedshiftSource == null) { throw new SdkClientException("Invalid argument passed to marshall(...)"); } try { protocolMarshaller.marshall(amazonRedshiftSource.getName(), NAME_BINDING); protocolMarshaller.marshall(amazonRedshiftSource.getData(), DATA_BINDING); } catch (Exception e) { throw new SdkClientException("Unable to marshall request to JSON: " + e.getMessage(), e); } } }
[ "" ]
c6870da35278f32118c1f356fd6e27f7f4bd9e89
1d18cd83831cea24c8ea48dce96f13c2ca3504c9
/src/com/eynak/footballquize/MainActivity.java
9a974b0710ecf7a98a9211a51d51d1e88dea927e
[]
no_license
kAvEh--/gameshit
fbf5f41d222088dc4979b86182514d9e0fed9a98
7a25b5d8e04c6b140f613e1d0e7cd5d02de1866c
refs/heads/master
2021-01-23T13:52:40.479003
2015-03-08T07:42:00
2015-03-08T07:42:00
28,241,886
0
0
null
null
null
null
UTF-8
Java
false
false
14,900
java
package com.eynak.footballquize; import java.util.HashMap; import android.annotation.SuppressLint; import android.content.Context; import android.content.Intent; import android.content.res.Resources; import android.graphics.Typeface; import android.os.AsyncTask; import android.os.Bundle; import android.support.v4.app.DialogFragment; import android.support.v4.app.FragmentActivity; import android.support.v4.view.PagerAdapter; import android.support.v4.view.ViewPager; import android.util.DisplayMetrics; import android.util.TypedValue; import android.view.Gravity; import android.view.LayoutInflater; import android.view.Menu; import android.view.View; import android.view.View.OnClickListener; import android.view.ViewGroup; import android.widget.FrameLayout; import android.widget.ImageButton; import android.widget.ImageView; import android.widget.RelativeLayout; import android.widget.RelativeLayout.LayoutParams; import android.widget.TextView; import com.eynak.utils.DatabasHandler; import com.eynak.utils.SendDatatoServer; import com.eynak.utils.ServerUtilities; import com.google.android.gcm.GCMRegistrar; public class MainActivity extends FragmentActivity { /** * The number of pages (wizard steps) to show in this demo. */ private static final int NUM_LEVELS = 31; /** * The pager widget, which handles animation and allows swiping horizontally * to access previous and next wizard steps. */ private ViewPager mPager; /** * The pager adapter, which provides the pages to the view pager widget. */ PagerAdapter adapter; PagerContainer mContainer; TextView _points_view; TextView _coins_view; TextView _main_to_finale; TextView _main_to_finale_2; private int _points; private int _coins; private int _last_level; DisplayMetrics metrics; float image_margin_px; int _help_count; Typeface face; // Google project id static final String SENDER_ID = "367325912027"; // Asyntask AsyncTask<Void, Void, Void> mRegisterTask; @SuppressLint("NewApi") @Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.activity_main); face = Typeface.createFromAsset(getAssets(), "font/" + getResources().getString(R.string.font) + ""); _points_view = (TextView) findViewById(R.id.question_header_points); _points_view.setTypeface(face); _coins_view = (TextView) findViewById(R.id.question_header_coins); _coins_view.setTypeface(face); _main_to_finale = (TextView) findViewById(R.id.main_finale_text); _main_to_finale.setTypeface(face); _main_to_finale_2 = (TextView) findViewById(R.id.main_finale_text_2); _main_to_finale_2.setTypeface(face); ViewPager myVP = (ViewPager) findViewById(R.id.mainViewPager); metrics = new DisplayMetrics(); getWindowManager().getDefaultDisplay().getMetrics(metrics); int width = metrics.widthPixels * 70 / 100; int height = metrics.heightPixels * 30 / 100; FrameLayout.LayoutParams tmpParams = new FrameLayout.LayoutParams( width, height); tmpParams.gravity = Gravity.CENTER; myVP.setLayoutParams(tmpParams); initialize(); if (_help_count < 2) { HelpDialog fr = new HelpDialog(); fr.setStyle(DialogFragment.STYLE_NO_TITLE, R.style.MyDialog); fr.setType(1); fr.show(getSupportFragmentManager(), "Hello"); DatabasHandler db = new DatabasHandler(getApplicationContext()); db = new DatabasHandler(getApplicationContext()); db.addShownCount(); db.close(); } mContainer = (PagerContainer) findViewById(R.id.pager_container); mPager = mContainer.getViewPager(); adapter = new MyPagerAdapter(); mPager.setAdapter(adapter); mPager.setPageTransformer(true, new ZoomOutPageTransformer()); // pager.setCurrentItem(2); // Necessary or the pager will only have one extra page to show // make this at least however many pages you can see mPager.setOffscreenPageLimit(2); // A little space between pages mPager.setPageMargin(15); // If hardware acceleration is enabled, you should also remove // clipping on the pager for its children. mPager.setClipChildren(false); // set page to last page unlocked mPager.setCurrentItem(_last_level - 1); SendDatatoServer tmp = new SendDatatoServer(this); tmp.checkUser(); // Make sure the device has the proper dependencies. GCMRegistrar.checkDevice(this); // Make sure the manifest was properly set - comment out this line // while developing the app, then uncomment it when it's ready. GCMRegistrar.checkManifest(this); // registerReceiver(mHandleMessageReceiver, new IntentFilter( // DISPLAY_MESSAGE_ACTION)); // Get GCM registration id final String regId = GCMRegistrar.getRegistrationId(this); // Check if regid already presents if (regId.equals("")) { // Registration is not present, register now with GCM GCMRegistrar.register(this, SENDER_ID); } else { // Device is already registered on GCM if (GCMRegistrar.isRegisteredOnServer(this)) { // Skips registration. } else { // Try to register again, but not in the UI thread. // It's also necessary to cancel the thread onDestroy(), // hence the use of AsyncTask instead of a raw thread. final Context context = this; mRegisterTask = new AsyncTask<Void, Void, Void>() { @Override protected Void doInBackground(Void... params) { // Register on our server // On server creates a new user ServerUtilities.register(context, regId); return null; } @Override protected void onPostExecute(Void result) { mRegisterTask = null; } }; mRegisterTask.execute(null, null, null); } } } private void initialize() { HashMap<String, Integer> gameData; DatabasHandler db = new DatabasHandler(getApplicationContext()); gameData = db.getGameData(); db.close(); _help_count = gameData.get("helpShownCount"); _points = gameData.get(getResources().getString(R.string.KEY_POINT)); _coins = gameData.get(getResources().getString(R.string.KEY_COINS)); _last_level = gameData.get(getResources().getString( R.string.KEY_LAST_P_UNLOCK)); if (_points >= getResources().getInteger(R.integer.FINALE_SCORE)) { _main_to_finale.setVisibility(View.INVISIBLE); _main_to_finale_2.setVisibility(View.INVISIBLE); } else { _main_to_finale.setText((getResources().getInteger( R.integer.FINALE_SCORE) - _points) + " " + getResources().getString(R.string.stat_score)); } _points_view.setText(String.valueOf(_points)); _coins_view.setText(String.valueOf(_coins)); } @Override public boolean onCreateOptionsMenu(Menu menu) { // Inflate the menu; this adds items to the action bar if it is present. getMenuInflater().inflate(R.menu.main, menu); return true; } @Override public void onBackPressed() { super.onBackPressed(); } public class ZoomOutPageTransformer implements ViewPager.PageTransformer { private static final float MIN_SCALE = 0.8f; private static final float MIN_ALPHA = 0.5f; Resources r = getResources(); float dp_10_px = TypedValue.applyDimension(TypedValue.COMPLEX_UNIT_DIP, 10, r.getDisplayMetrics()); float dp_15_px = TypedValue.applyDimension(TypedValue.COMPLEX_UNIT_DIP, 15, r.getDisplayMetrics()); float dp_20_px = TypedValue.applyDimension(TypedValue.COMPLEX_UNIT_DIP, 20, r.getDisplayMetrics()); LayoutParams params = new LayoutParams((int) dp_20_px, (int) dp_20_px); @SuppressLint("NewApi") public void transformPage(View view, float position) { if (position < -1) { // [-Infinity,-1) // This page is way off-screen to the left. view.setAlpha(MIN_ALPHA); view.setScaleY(MIN_SCALE); params.setMargins((int) (metrics.widthPixels / 30 * mPager .getCurrentItem()), (int) dp_10_px, 0, (int) dp_15_px); params.addRule(RelativeLayout.BELOW, R.id.pager_container); } else if (position <= 1) { // [-1,1] // Modify the default slide transition to shrink the page as // well float scaleFactor = Math.max(MIN_SCALE, 1 - Math.abs(position)); view.setScaleY(scaleFactor); // Fade the page relative to its size. view.setAlpha(MIN_ALPHA + (scaleFactor - MIN_SCALE) / (1 - MIN_SCALE) * (1 - MIN_ALPHA)); params.setMargins( (int) (metrics.widthPixels / 30 * mPager.getCurrentItem() + ((1 - Math.abs(position)) * metrics.widthPixels / 60) + dp_15_px), (int) dp_10_px, 0, (int) dp_15_px); params.addRule(RelativeLayout.BELOW, R.id.pager_container); } else { view.setAlpha(MIN_ALPHA); view.setScaleY(MIN_SCALE); } } } private class MyPagerAdapter extends PagerAdapter { @SuppressLint({ "NewApi", "InflateParams" }) @Override public Object instantiateItem(View pager, int position) { View view; LayoutInflater inflater = (LayoutInflater) getApplicationContext() .getSystemService(Context.LAYOUT_INFLATER_SERVICE); view = inflater.inflate(R.layout.level_layout, null); ImageView bg = (ImageView) view.findViewById(R.id.package_bg); ImageView lockIcon = (ImageView) view .findViewById(R.id.level_main_lock); TextView tv = (TextView) view.findViewById(R.id.package_title); tv.setTypeface(face); TextView score_tv = (TextView) view .findViewById(R.id.package_score); score_tv.setTypeface(face); ImageView gameIcon = (ImageView) view .findViewById(R.id.package_ic); DatabasHandler db = new DatabasHandler(getApplicationContext()); HashMap<String, String> data = db.getPackageInfo(position + 1); db.close(); if (position <= 30) if (position < _last_level) score_tv.setText(data.get("Point") + " امتیاز"); if (position == 30) { tv.setVisibility(View.INVISIBLE); gameIcon.setVisibility(View.INVISIBLE); } else tv.setText("مرحله " + (position + 1)); ImageButton stat = (ImageButton) view .findViewById(R.id.package_stat); stat.setTag(position + 1); stat.setOnClickListener(new OnClickListener() { @Override public void onClick(View v) { onStatClick(v); } }); ImageView _8x = (ImageView) view.findViewById(R.id.package_8x); view.setTag(position); view.setOnClickListener(new OnClickListener() { @Override public void onClick(View v) { int stage = (Integer) v.getTag(); if (stage == 30) { if (_points >= getResources().getInteger( R.integer.FINALE_SCORE)) { DatabasHandler db = new DatabasHandler( getApplicationContext()); HashMap<String, String> userData = db.getUser(); db.close(); if (userData.get(getResources().getString( R.string.KEY_NAME)) != null) { Intent intent = new Intent(MainActivity.this, FinaleLevelActivity.class); startActivity(intent); } else { onUserClick(null); } } else { // TODO } } else if (stage < _last_level) { Intent i = new Intent(MainActivity.this, LevelActivity.class); i.putExtra("level", (stage + 1)); startActivity(i); } else if (stage == _last_level) { UnlockDialog fr = new UnlockDialog(); fr.setStyle(DialogFragment.STYLE_NO_TITLE, R.style.MyDialog); fr.setLevel(stage + 1); fr.setCoins(_coins); fr.show(getSupportFragmentManager(), "Hello"); } else { // Toast.makeText(getApplicationContext(), // "You don`t have access to this level.", // Toast.LENGTH_LONG).show(); } } }); if (position == 30) { if (_points < getResources().getInteger(R.integer.FINALE_SCORE)) { bg.setImageResource(R.drawable.finale_lock_bg); tv.setTextColor(getResources().getColor(R.color.black)); } else { bg.setImageResource(R.drawable.finale_unlock_bg); tv.setTextColor(getResources().getColor(R.color.ajori)); } stat.setVisibility(View.INVISIBLE); lockIcon.setVisibility(View.INVISIBLE); } else if (position < _last_level) { bg.setImageResource(R.drawable.package_unlock_bg); tv.setTextColor(getResources().getColor(R.color.ajori)); lockIcon.setVisibility(View.INVISIBLE); stat.setImageResource(R.drawable.ic_stat_on); } else { bg.setImageResource(R.drawable.package_lock_bg); tv.setTextColor(getResources().getColor(R.color.black)); lockIcon.setVisibility(View.VISIBLE); stat.setImageResource(R.drawable.ic_stat_off); } if (position == 29) { _8x.setVisibility(View.VISIBLE); } ((ViewPager) pager).addView(view); return view; } @Override public void destroyItem(ViewGroup container, int position, Object object) { container.removeView((View) object); } @Override public int getCount() { return NUM_LEVELS; } @Override public boolean isViewFromObject(View view, Object object) { return (view == object); } } public void onStatClick(View v) { int level = (Integer) v.getTag(); if (level <= _last_level) { StatDialog fr = new StatDialog(); fr.setStyle(DialogFragment.STYLE_NO_TITLE, R.style.MyDialog2); fr.setLevel(level); fr.show(getSupportFragmentManager(), "Hello"); } } public void onShopClick(View v) { Intent intent = new Intent(MainActivity.this, ShopActivity.class); startActivity(intent); } public void onUserClick(View v) { UserDialog fr = new UserDialog(); fr.setStyle(DialogFragment.STYLE_NO_TITLE, R.style.MyDialog); fr.show(getSupportFragmentManager(), "Hello"); } public void onAchievementClick(View v) { Intent intent = new Intent(MainActivity.this, AchievementActivity.class); startActivity(intent); } public void onLeaderClick(View v) { Intent intent = new Intent(MainActivity.this, LeaderBoardActivity.class); startActivity(intent); } @Override protected void onResume() { super.onResume(); mPager.setAdapter(adapter); mPager.setCurrentItem(_last_level - 1); initialize(); } public void updateunlock() { initialize(); Intent i = new Intent(MainActivity.this, LevelActivity.class); i.putExtra("level", _last_level); startActivity(i); } public void gotoFinal(View v) { // Intent intent = new Intent(MainActivity.this, FinaleLevelActivity.class); // startActivity(intent); } public void onGiftClick(View v) { HelpDialog fr = new HelpDialog(); fr.setStyle(DialogFragment.STYLE_NO_TITLE, R.style.MyDialog); fr.setType(5); fr.show(getSupportFragmentManager(), "Hello"); } }
[ "kaveh.fazaeli@gmail.com" ]
kaveh.fazaeli@gmail.com
3732777d356de6528c4750eebc8639c89727e884
a7a9ad8b39e4c8324c68bd8ed365a71694a0f0ab
/applications/orders/src/test/java/com/microservices/orders/OrdersApplicationTests.java
23a39e4af73e2bff6747078474a3fe6ffdd3bc3e
[]
no_license
jyarbro88/amazon-microservices
58d5340409075f25cb0380b75dfbf0f39f9223f7
da743d27779ee12da2ed90f5e1afebaab1efc794
refs/heads/master
2020-03-24T08:27:38.679504
2018-08-16T15:00:34
2018-08-16T15:00:34
142,596,479
0
0
null
null
null
null
UTF-8
Java
false
false
350
java
package com.microservices.orders; import org.junit.Test; import org.junit.runner.RunWith; import org.springframework.boot.test.context.SpringBootTest; import org.springframework.test.context.junit4.SpringRunner; @RunWith(SpringRunner.class) @SpringBootTest public class OrdersApplicationTests { @Test public void contextLoads() { } }
[ "jyarbrough@solstice.com" ]
jyarbrough@solstice.com
f1ff2d5ff7ee34ac325d118abd3218ebc630b92c
082e26b011e30dc62a62fae95f375e4f87d9e99c
/docs/weixin_7.0.4_source/反编译源码/未反混淆/src/main/java/com/tencent/mm/protocal/protobuf/bby.java
202299c431401432dc165cade11188ae8c91a801
[]
no_license
xsren/AndroidReverseNotes
9631a5aabc031006e795a112b7ac756a8edd4385
9202c276fe9f04a978e4e08b08e42645d97ca94b
refs/heads/master
2021-04-07T22:50:51.072197
2019-07-16T02:24:43
2019-07-16T02:24:43
null
0
0
null
null
null
null
UTF-8
Java
false
false
3,057
java
package com.tencent.mm.protocal.protobuf; import com.tencent.matrix.trace.core.AppMethodBeat; import e.a.a.c.a; import java.util.LinkedList; public final class bby extends bsr { public int OpCode; public String ProductID; public final int op(int i, Object... objArr) { AppMethodBeat.i(62575); int ix; if (i == 0) { a aVar = (a) objArr[0]; if (this.BaseRequest != null) { aVar.iy(1, this.BaseRequest.computeSize()); this.BaseRequest.writeFields(aVar); } if (this.ProductID != null) { aVar.e(2, this.ProductID); } aVar.iz(3, this.OpCode); AppMethodBeat.o(62575); return 0; } else if (i == 1) { if (this.BaseRequest != null) { ix = e.a.a.a.ix(1, this.BaseRequest.computeSize()) + 0; } else { ix = 0; } if (this.ProductID != null) { ix += e.a.a.b.b.a.f(2, this.ProductID); } int bs = ix + e.a.a.b.b.a.bs(3, this.OpCode); AppMethodBeat.o(62575); return bs; } else if (i == 2) { e.a.a.a.a aVar2 = new e.a.a.a.a((byte[]) objArr[0], unknownTagHandler); for (ix = com.tencent.mm.bt.a.getNextFieldNumber(aVar2); ix > 0; ix = com.tencent.mm.bt.a.getNextFieldNumber(aVar2)) { if (!super.populateBuilderWithField(aVar2, this, ix)) { aVar2.ems(); } } AppMethodBeat.o(62575); return 0; } else if (i == 3) { e.a.a.a.a aVar3 = (e.a.a.a.a) objArr[0]; bby bby = (bby) objArr[1]; int intValue = ((Integer) objArr[2]).intValue(); switch (intValue) { case 1: LinkedList Vh = aVar3.Vh(intValue); int size = Vh.size(); for (intValue = 0; intValue < size; intValue++) { byte[] bArr = (byte[]) Vh.get(intValue); hl hlVar = new hl(); e.a.a.a.a aVar4 = new e.a.a.a.a(bArr, unknownTagHandler); for (boolean z = true; z; z = hlVar.populateBuilderWithField(aVar4, hlVar, com.tencent.mm.bt.a.getNextFieldNumber(aVar4))) { } bby.BaseRequest = hlVar; } AppMethodBeat.o(62575); return 0; case 2: bby.ProductID = aVar3.BTU.readString(); AppMethodBeat.o(62575); return 0; case 3: bby.OpCode = aVar3.BTU.vd(); AppMethodBeat.o(62575); return 0; default: AppMethodBeat.o(62575); return -1; } } else { AppMethodBeat.o(62575); return -1; } } }
[ "alwangsisi@163.com" ]
alwangsisi@163.com
3fb9bd19d8c909f1974700246843c55eadd18988
79e17de56f6a23091cdbfe2818f1cb5f168e5d01
/src/de/jost_net/JVerein/gui/parts/BuchungListTablePart.java
f659024325db9632a4a62d69e07926a964bc330e
[]
no_license
klingerr/AdwJVerein
3f1c7125f68f6015ad440e01ae7caf925e4b8155
3f741b7389513ba0612775c2b46961483b75a215
refs/heads/master
2021-01-10T08:24:45.878510
2016-12-05T19:23:40
2016-12-05T19:23:40
51,390,074
0
0
null
null
null
null
UTF-8
Java
false
false
2,398
java
/********************************************************************** * Copyright (c) by Heiner Jostkleigrewe * This program is free software: you can redistribute it and/or modify it under the terms of the * GNU General Public License as published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. * * This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without * even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See * the GNU General Public License for more details. * * You should have received a copy of the GNU General Public License along with this program. If not, * see <http://www.gnu.org/licenses/>. * * heiner@jverein.de * www.jverein.de **********************************************************************/ package de.jost_net.JVerein.gui.parts; import java.rmi.RemoteException; import java.util.List; import de.jost_net.JVerein.Einstellungen; import de.jost_net.JVerein.rmi.Buchung; import de.willuhn.datasource.GenericIterator; import de.willuhn.jameica.gui.Action; import de.willuhn.jameica.gui.parts.TablePart; public class BuchungListTablePart extends TablePart { public BuchungListTablePart(Action action) { super(action); } public BuchungListTablePart(GenericIterator list, Action action) { super(list, action); } public BuchungListTablePart(List<Buchung> list, Action action) { super(list, action); } /** * Liefert den anzuzeigenden Summen-Text. Kann von abgeleiteten Klassen * ueberschrieben werde, um etwas anderes anzuzeigen. * * @return anzuzeigender Text oder null, wenn nichts angezeigt werden soll. */ @Override protected String getSummary() { String summary = super.getSummary(); double sumBetrag = 0.0; try { @SuppressWarnings("rawtypes") List l = this.getItems(); for (int i = 0; i < l.size(); i++) { Buchung b = (Buchung) l.get(i); sumBetrag += b.getBetrag(); } summary += " / " + "Gesamtbetrag:" + " " + Einstellungen.DECIMALFORMAT.format(sumBetrag) + " " + Einstellungen.CURRENCY; } catch (RemoteException re) { // nichts tun } return summary; } }
[ "ralf.klinger@gmx.de" ]
ralf.klinger@gmx.de
ab06520d568cfb10e65dae7a74a73551faff990e
abb9aa1911280b20a6d8f782befc96da80bfd19f
/SmartCart2/app/src/main/java/com/example/smartcart/record/ParsedNdefRecord.java
5c6eb725887d1c37e8551a9f33f33e3176b73e88
[]
no_license
usrivastav615/ankit
ddbb6fd77ccff8e35d22fc2b28d7d1bd3255f67f
2f16f7d760bad48a37778ce937bc9ff5fb1e902e
refs/heads/master
2021-01-10T02:04:36.052802
2015-12-07T17:30:25
2015-12-07T17:30:25
46,727,269
0
1
null
null
null
null
UTF-8
Java
false
false
1,009
java
/* * Copyright (C) 2010 The Android Open Source Project * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ package com.example.smartcart.record; import android.app.Activity; import android.view.LayoutInflater; import android.view.View; import android.view.ViewGroup; public interface ParsedNdefRecord { /** * Returns a view to display this record. */ public View getView(Activity activity, LayoutInflater inflater, ViewGroup parent, int offset); }
[ "usrivast@adobe.com" ]
usrivast@adobe.com
08fd65c8cef101d504683226540c8c4352de1cd2
1192e8228df65686770b4251a06b5fd4622955b9
/src/main/java/com/moodtoday/activity/MainActivity.java
0464b024521a713d92b8e4a4dfecfc3ba3c24ecf
[]
no_license
khk0851/mood
def93b7a2935404b071e5694474203b9f97166bf
fcbd77a671a1be27d413d37b3b29fdeef946f5ca
refs/heads/main
2022-12-19T00:02:50.584201
2020-10-08T08:39:53
2020-10-08T08:39:53
302,275,191
0
0
null
null
null
null
UTF-8
Java
false
false
2,894
java
package com.moodtoday.activity; import android.content.DialogInterface; import android.content.Intent; import android.os.Bundle; import android.view.View; import android.widget.Button; import androidx.appcompat.app.AlertDialog; import androidx.appcompat.app.AppCompatActivity; import com.moodtoday.R; import com.moodtoday.db.DBHelper; import com.moodtoday.dto.DiaryDTO; import java.text.SimpleDateFormat; import java.util.ArrayList; import java.util.Date; public class MainActivity extends AppCompatActivity { Button btnLast, btnToday; DBHelper dbHelper; ArrayList<DiaryDTO> diaryList= new ArrayList<>();; String email; @Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.activity_main); email = getIntent().getStringExtra("email"); dbHelper = new DBHelper(MainActivity.this); btnLast = findViewById(R.id.btn_last); btnLast.setOnClickListener(new View.OnClickListener() { @Override public void onClick(View v) { Intent intent = new Intent(MainActivity.this, LastActivity.class); intent.putExtra("email", email); startActivity(intent); } }); btnToday = findViewById(R.id.btn_today); btnToday.setOnClickListener(new View.OnClickListener() { @Override public void onClick(View v) { if(diaryList.size() > 0) { AlertDialog.Builder builder = new AlertDialog.Builder(MainActivity.this); builder.setMessage("오늘의 기록을 작성하셨습니다."); builder.setPositiveButton("확인", new DialogInterface.OnClickListener() { @Override public void onClick(DialogInterface dialog, int which) { dialog.dismiss(); } }); AlertDialog dialog = builder.create(); dialog.show(); } else { Intent intent = new Intent(MainActivity.this, TodayActivity.class); intent.putExtra("email", email); startActivity(intent); } } }); } String getTodayDate() { long now = System.currentTimeMillis(); Date date = new Date(now); SimpleDateFormat simpleDateFormat = new SimpleDateFormat("yyyy-M-d"); String strDate = simpleDateFormat.format(date); return strDate; } @Override protected void onResume() { super.onResume(); diaryList.clear(); diaryList = dbHelper.selectDiaryTable(getTodayDate(), email); } }
[ "noreply@github.com" ]
khk0851.noreply@github.com
b82d76096590530ec87b580a9a35956038229065
f126342af63541c6accddfe1dfd4358dcd0f32b9
/src/gui/MessageRecevable.java
8b916f377bb3cdbb17f4431309c0968bb1f026b4
[]
no_license
AnimateGO/honda
c757eea1e15506d090c31c2c3b5f98d97b1a80b4
0b54388530e6e7cb519e60cfde652e981629680d
refs/heads/master
2020-03-21T04:38:29.682253
2018-09-19T06:25:49
2018-09-19T06:25:49
138,119,787
0
0
null
2018-09-19T06:36:40
2018-06-21T04:37:43
Java
UTF-8
Java
false
false
385
java
/* * To change this template, choose Tools | Templates * and open the template in the editor. */ package gui; /** * GUI等に搭載するインタフェース ログの追加と受信したメッセージの追加メソッドを持つ * @author koji */ public interface MessageRecevable { public void reciveMessage(String text); public void addMessage(String text); }
[ "satoken0806@gmail.com" ]
satoken0806@gmail.com
acd8916abae82fb78f61b65e98440644b0698352
726bef06762e4e90f1c5c07f16802243a35b5e9f
/src/main/java/com/ideal/user/controller/UserController.java
da186b9f6d5eff8a7151f4a98e9ca97fff0c6f5e
[]
no_license
JJinbo/wechart
fb5e125eda1483a19f97d04e1800b89bea04a0ee
1142809939e65d4694702b05106b10c00966751f
refs/heads/master
2020-04-18T10:31:14.577027
2019-01-25T08:15:25
2019-01-25T08:15:25
167,469,690
0
1
null
null
null
null
UTF-8
Java
false
false
1,002
java
package com.ideal.user.controller; import java.util.List; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Controller; import org.springframework.web.bind.annotation.RequestMapping; import org.springframework.web.bind.annotation.ResponseBody; import com.ideal.entity.UserInfoEntity; import com.ideal.user.service.UserService; /** * @Auther: JJB * @Date: 2019年1月22日 * @Description: 用户列表 */ @Controller @RequestMapping("/user") public class UserController { @Autowired private UserService userServiceImpl; //获取所有的用户 @RequestMapping("/queryAllUser") @ResponseBody public List<UserInfoEntity> queryAllUser(){ return userServiceImpl.queryAllUser(); } //获取所有的用户 @RequestMapping("/queryUserBy") @ResponseBody public UserInfoEntity queryUserBy(UserInfoEntity user){ return userServiceImpl.queryUserBy(user); } }
[ "贾锦波@DESKTOP-88CJ41P" ]
贾锦波@DESKTOP-88CJ41P
e4b63ab4fe9fe7dbabb14c461c1fc9d5a2234abc
24b4c52769cc74a18061eb4483676fd9e50f580d
/src/剑指offer/lengthOfLongestSubstring.java
c09dbdbc8e3ce01547e617c7b4e3765e35ae0365
[]
no_license
1160300510/leetcode
95a7619f301ff711b7fdb715861c4d94e145c031
1b87444380838ac1373fdd60f03b0b283d411150
refs/heads/main
2023-06-21T12:26:24.501193
2021-07-31T12:22:13
2021-07-31T12:22:13
303,888,891
2
0
null
null
null
null
UTF-8
Java
false
false
935
java
package 剑指offer; import java.util.HashMap; import java.util.Map; public class lengthOfLongestSubstring { public int lengthOfLongestSubstring(String s) { if(s==null || s.length()==0){ return 0; } Map<Character, Integer> map = new HashMap<>(); int n = s.length(); int i=0, j=0; int ans = 1; while(j<n){ if(i == j){ map.clear(); map.put(s.charAt(j), j); j++; }else{ char c = s.charAt(j); if(!map.containsKey(c)){ map.put(c, j); j++; }else{ ans = Math.max(ans, j-i); i = Math.max(i, map.get(c)+1); map.put(c,j); j++; } } } ans = Math.max(ans, j-i); return ans; } }
[ "379744795@qq.com" ]
379744795@qq.com
a75572e2628c91e92e38d3f624edaa3f72882070
9cdffd38b37e7873de37e004bad75d64b4650e44
/sell/src/main/java/com/qcl/controller/BuyerOrderController.java
b295214fcd19b852b2c2f0c90eabfd223b48b301
[]
no_license
wangmengzhong/supacer
2556059e2b1b7bc2ad3a1d8b98495d6d89cf0cd6
547d41975eda31d3081e8342f79843594fad3bad
refs/heads/master
2023-01-23T10:50:53.656491
2019-11-28T07:57:09
2019-11-28T07:57:09
157,357,086
0
0
null
null
null
null
UTF-8
Java
false
false
3,506
java
package com.qcl.controller; import com.qcl.VO.ResultVO; import com.qcl.converter.OrderForm2OrderDTOConverter; import com.qcl.dto.OrderDTO; import com.qcl.enums.ResultEnum; import com.qcl.exception.SellException; import com.qcl.form.OrderForm; import com.qcl.service.BuyerService; import com.qcl.service.OrderService; import com.qcl.utils.ResultVOUtil; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.util.CollectionUtils; import org.springframework.util.StringUtils; import org.springframework.validation.BindingResult; import org.springframework.web.bind.annotation.GetMapping; import org.springframework.web.bind.annotation.PostMapping; import org.springframework.web.bind.annotation.RequestMapping; import org.springframework.web.bind.annotation.RequestParam; import org.springframework.web.bind.annotation.RestController; import java.util.HashMap; import java.util.List; import java.util.Map; import javax.validation.Valid; import lombok.extern.slf4j.Slf4j; /** * 编程小石头:2501902696(微信) */ @RestController @RequestMapping("/buyer/order") @Slf4j public class BuyerOrderController { @Autowired private OrderService orderService; @Autowired private BuyerService buyerService; //创建订单 @PostMapping("/create") public ResultVO<Map<String, String>> create(@Valid OrderForm orderForm, BindingResult bindingResult) { if (bindingResult.hasErrors()) { throw new SellException(ResultEnum.PARAM_ERROR.getCode(), bindingResult.getFieldError().getDefaultMessage()); } OrderDTO orderDTO = OrderForm2OrderDTOConverter.convert(orderForm); if (CollectionUtils.isEmpty(orderDTO.getOrderDetailList())) { throw new SellException(ResultEnum.CART_EMPTY); } OrderDTO createResult = orderService.create(orderDTO); Map<String, String> map = new HashMap<>(); map.put("orderId", createResult.getOrderId()); return ResultVOUtil.success(map); } //订单列表 @GetMapping("/listByStatus") public ResultVO<List<OrderDTO>> listByStatus(@RequestParam("openid") String openid, @RequestParam(value = "orderStatus", defaultValue = "0") Integer orderStatus) { if (StringUtils.isEmpty(openid)) { throw new SellException(ResultEnum.PARAM_ERROR); } List<OrderDTO> orderList = buyerService.findOrderList(openid, orderStatus); return ResultVOUtil.success(orderList); } //订单详情 @GetMapping("/detail") public ResultVO<OrderDTO> detail(@RequestParam("openid") String openid, @RequestParam("orderId") String orderId) { OrderDTO orderDTO = buyerService.findOrderOne(openid, orderId); return ResultVOUtil.success(orderDTO); } //确认收货 @PostMapping("/sure") public ResultVO sure(@RequestParam("openid") String openid, @RequestParam("orderId") String orderId) { buyerService.cancelOrder(openid, orderId); return ResultVOUtil.success(); } //取消订单 @PostMapping("/cancel") public ResultVO cancel(@RequestParam("openid") String openid, @RequestParam("orderId") String orderId) { buyerService.cancelOrder(openid, orderId); return ResultVOUtil.success(); } }
[ "2369915949@qq.com" ]
2369915949@qq.com
c8e7a9b04c82a3643838012cfeced1711981f44e
08116a6f033f38806131a2d8712c9363b44c95db
/backend/src/main/java/ba/unsa/etf/bp/udat/services/ImportTimeService.java
e75eb009aae65a9443e301a3c346b9f97b0557c1
[]
no_license
adkl/university-data-analysis-tool
1604a7ec434a14e347261e3073ee5335df16fe2f
643af082f54634f7168fd0fb0f07526c80f65d0a
refs/heads/master
2021-09-04T07:41:02.629845
2018-01-17T04:04:31
2018-01-17T04:04:31
null
0
0
null
null
null
null
UTF-8
Java
false
false
935
java
package ba.unsa.etf.bp.udat.services; import ba.unsa.etf.bp.udat.models.ImportTime; import ba.unsa.etf.bp.udat.models.SemesterDim; import ba.unsa.etf.bp.udat.repositories.ImportTimeRepository; import ba.unsa.etf.bp.udat.repositories.SemesterDimRepository; import org.hibernate.service.spi.ServiceException; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.data.jpa.repository.JpaContext; import org.springframework.stereotype.Service; import java.util.ArrayList; import java.util.Collection; import java.util.List; @Service public class ImportTimeService extends BaseService<ImportTime, ImportTimeRepository>{ public ImportTime findByTableName(String tableName) throws ServiceException { ImportTime it = repository.findByTableName(tableName); return it; } public List<Object[]> findTimeOfImport() { return repository.findTimeOfImport(); } }
[ "ebegic2@etf.unsa.ba" ]
ebegic2@etf.unsa.ba
7639274df96eeb0983d63c123db480a965fd9b42
7311890a9d708e75bf98d660436f615337b2702d
/src/com/hening/sale/corecode/login/action/LoginAction.java
233e7d4c16651f746ec161964f2963470eef6af4
[]
no_license
hening191/saleManagement
374eca82b05c9746c6d79114b5196d22a53ffd1d
da4a457fc92aa8e49f9e91266845b997d7483e7a
refs/heads/master
2021-09-09T12:14:40.540323
2018-03-16T01:28:46
2018-03-16T01:28:46
125,149,949
0
0
null
null
null
null
UTF-8
Java
false
false
2,092
java
package com.hening.sale.corecode.login.action; import java.util.HashMap; import java.util.Map; import org.springframework.beans.factory.annotation.Autowired; import com.hening.sale.utils.SessionUtil; import com.hening.sale.corecode.login.entity.User; import com.hening.sale.corecode.login.service.LoginService; import com.hening.sale.common.base.BaseAction; @SuppressWarnings("serial") public class LoginAction extends BaseAction { private String loginName; private String password; private Map<String,Object> resMap = new HashMap<String,Object>(); @Autowired private LoginService loginService; public String login() { SessionUtil.clearCurrentUser(request, response); return "fail"; } public String doLogin(){ if( loginName == null || "".equals( loginName ) ){ resMap.put("msg", "请输入用户名"); resMap.put("success", 0); resMap.put("msg_type", "0"); return "error"; } if( password == null || "".equals( password ) ){ resMap.put("msg", "请输入密码"); resMap.put("success", 0); resMap.put("msg_type", "1"); return "error"; } try { User user = loginService.findUserByLoginName(loginName); if(user != null){ if(password.equals(user.getPassword())){ SessionUtil.setCurrentUser( request, response, user ); resMap.put("success", 1); return "success"; }else{ resMap.put("msg", "密码错误"); resMap.put("success", 0); resMap.put("msg_type", "1"); return "error"; } }else{ resMap.put("msg", "帐号不存在"); resMap.put("success", 0); resMap.put("msg_type", "0"); return "error"; } } catch (Exception e) { return "fail"; } } public String getLoginName() { return loginName; } public void setLoginName(String loginName) { this.loginName = loginName; } public String getPassword() { return password; } public void setPassword(String password) { this.password = password; } public Map<String, Object> getResMap() { return resMap; } public void setResMap(Map<String, Object> resMap) { this.resMap = resMap; } }
[ "472462446@qq.com" ]
472462446@qq.com
4d5ce14f36fb35c70994fa3cc2870074987a20d2
83071feebd9509f77b0281a91623548e89572a79
/bcn/src/main/java/com/kodeinc/bcn/api/v1/roles/entities/RoleResponse.java
54fe3dc8aaaf189d096ca523a12915c5b80c9557
[]
no_license
Moverr/blockchainjava
4c77dd8b548298104b7f7fabbabb7da5c58d16b7
6630de66f7fa66b009454a846912c698f0802268
refs/heads/master
2021-07-02T09:55:39.641924
2018-10-18T04:05:43
2018-10-18T04:05:43
153,171,572
0
0
null
2020-09-08T22:48:16
2018-10-15T19:41:33
JavaScript
UTF-8
Java
false
false
3,691
java
/* * To change this license header, choose License Headers in Project Properties. * To change this template file, choose Tools | Templates * and open the template in the editor. */ package com.kodeinc.bcn.api.v1.roles.entities; import com.fasterxml.jackson.annotation.JsonIgnoreProperties; import com.fasterxml.jackson.annotation.JsonInclude; import com.kodeinc.bcn.api.v1.permissions.entities.PermissionsResponse; import java.util.Arrays; import java.util.Objects; /** * * @author Mover 11/22/2017 */ @JsonIgnoreProperties(ignoreUnknown = true) @JsonInclude(JsonInclude.Include.NON_NULL) public class RoleResponse { private Integer id; private String name; private String code; private String description; private boolean isSystem; private PermissionsResponse[] permissions; private Long dateCreated; private String author; public RoleResponse() { } public RoleResponse(Integer id) { this.id = id; } public Integer getId() { return id; } public void setId(Integer id) { this.id = id; } public String getName() { return name; } public void setName(String name) { this.name = name; } public String getDescription() { return description; } public void setDescription(String description) { this.description = description; } public boolean isIsSystem() { return isSystem; } public void setIsSystem(boolean isSystem) { this.isSystem = isSystem; } public PermissionsResponse[] getPermissions() { return permissions; } public void setPermissions(PermissionsResponse[] permissions) { this.permissions = permissions; } public Long getDateCreated() { return dateCreated; } public void setDateCreated(Long dateCreated) { this.dateCreated = dateCreated; } public String getAuthor() { return author; } public void setAuthor(String author) { this.author = author; } public String getCode() { return code; } public void setCode(String code) { this.code = code; } @Override public int hashCode() { int hash = 5; hash = 43 * hash + Objects.hashCode(this.id); hash = 43 * hash + Objects.hashCode(this.name); hash = 43 * hash + Objects.hashCode(this.description); hash = 43 * hash + (this.isSystem ? 1 : 0); hash = 43 * hash + Arrays.deepHashCode(this.permissions); return hash; } @Override public boolean equals(Object obj) { if (this == obj) { return true; } if (obj == null) { return false; } if (getClass() != obj.getClass()) { return false; } final RoleResponse other = (RoleResponse) obj; if (this.isSystem != other.isSystem) { return false; } if (!Objects.equals(this.name, other.name)) { return false; } if (!Objects.equals(this.description, other.description)) { return false; } if (!Objects.equals(this.id, other.id)) { return false; } return Arrays.deepEquals(this.permissions, other.permissions); } @Override public String toString() { return "RoleResponse{" + "id=" + id + ", name=" + name + ", code=" + code + ", description=" + description + ", isSystem=" + isSystem + ", permissions=" + Arrays.asList(permissions) + "}"; } }
[ "moverr@gmail.com" ]
moverr@gmail.com
69d7f0d5e86c6fe780a5fc8b2fc33c2b3c6d52c0
10575a7f7333793aae103f799696f30f1894abf5
/src/SourceCode/Day_13_Abstract_Classes.java
47046d0053c4aeabd482eb3c54ec31decc9b959b
[]
no_license
svrswetha/HackerRank
52cc289746a7dfa5c499876179197939bbd7dc8b
03dac98b8af8ba0e526712be3f52438ed1084496
refs/heads/master
2021-01-19T11:09:15.103425
2018-01-04T23:38:48
2018-01-04T23:38:48
87,932,050
0
0
null
2017-04-16T19:00:43
2017-04-11T12:35:32
Java
UTF-8
Java
false
false
987
java
import java.util.*; abstract class Book { String title; String author; Book(String title, String author) { this.title = title; this.author = author; } abstract void display(); } class MyBook extends Book { private static int price; MyBook(String title, String author, int price) { super(title,author); this.title = title; this.author = author; this.price =price; } void display() { System.out.println( "Title: " + title + "\nAuthor: " + author + "\nPrice: " + price); } } public class Day_13_Abstract_Classes { public static void main(String[] args) { Scanner scanner = new Scanner(System.in); String title = scanner.nextLine(); String author = scanner.nextLine(); int price = scanner.nextInt(); scanner.close(); Book book = new MyBook(title, author, price); book.display(); } }
[ "svrswetha@gmail.com" ]
svrswetha@gmail.com
399a6b3116213bb0f65597d006b6520756fbcf56
6be39fc2c882d0b9269f1530e0650fd3717df493
/weixin反编译/sources/com/tencent/mm/plugin/location_soso/SoSoProxyUI.java
2f69d3f8c8e3c369023bb940ce85a5d273991fb9
[]
no_license
sir-deng/res
f1819af90b366e8326bf23d1b2f1074dfe33848f
3cf9b044e1f4744350e5e89648d27247c9dc9877
refs/heads/master
2022-06-11T21:54:36.725180
2020-05-07T06:03:23
2020-05-07T06:03:23
155,177,067
5
0
null
null
null
null
UTF-8
Java
false
false
3,884
java
package com.tencent.mm.plugin.location_soso; import android.content.Intent; import android.content.res.Resources; import android.os.Build.VERSION; import android.os.Bundle; import android.view.KeyEvent; import android.view.LayoutInflater; import android.view.MotionEvent; import com.tencent.mm.R; import com.tencent.mm.plugin.p.c; import com.tencent.mm.plugin.report.service.g; import com.tencent.mm.sdk.a.b; import com.tencent.mm.sdk.platformtools.ad; import com.tencent.mm.sdk.platformtools.x; import com.tencent.mm.ui.base.a; import com.tencent.mm.ui.v; import com.tencent.tencentmap.mapsdk.map.MapActivity; @a(19) public class SoSoProxyUI extends MapActivity { protected static final String TAG = "MicroMsg.SoSoProxyUI"; private com.tencent.mm.plugin.p.a basemapUI; public void onCreate(Bundle bundle) { boolean z = true; x.i(TAG, "SoSoProxyUI onCreate"); super.onCreate(bundle); int intExtra = getIntent().getIntExtra("intent_map_key", -1); if (c.a.oem == null) { try { String str = TAG; String str2 = "summerasyncinit not init activity foreground[%b] savedInstanceState[%b], activity[%s, %d]"; Object[] objArr = new Object[4]; objArr[0] = Boolean.valueOf(b.foreground); if (bundle == null) { z = false; } objArr[1] = Boolean.valueOf(z); objArr[2] = getClass().getSimpleName(); objArr[3] = Integer.valueOf(hashCode()); x.e(str, str2, objArr); finish(); } catch (Throwable th) { x.printErrStackTrace(TAG, th, "summerasyncinit finish:", new Object[0]); } g.pWK.a(598, 20, 1, false); return; } this.basemapUI = c.a.oem.e(this, intExtra); if (this.basemapUI == null) { finish(); return; } this.basemapUI.onCreate(bundle); if (VERSION.SDK_INT >= 21) { getWindow().setStatusBarColor(getResources().getColor(R.e.btT)); } } public void onBackPressed() { this.basemapUI.onBackPressed(); } public boolean dispatchTouchEvent(MotionEvent motionEvent) { if (this.basemapUI.dispatchTouchEvent(motionEvent)) { return true; } return super.dispatchTouchEvent(motionEvent); } public boolean dispatchKeyEvent(KeyEvent keyEvent) { if (this.basemapUI.dispatchKeyEvent(keyEvent)) { return true; } return super.dispatchKeyEvent(keyEvent); } public boolean onKeyUp(int i, KeyEvent keyEvent) { if (i != 82 || keyEvent.getAction() != 1) { return super.onKeyUp(i, keyEvent); } this.basemapUI.aWZ(); return true; } public void onResume() { super.onResume(); this.basemapUI.onResume(); } public void onPause() { super.onPause(); this.basemapUI.onPause(); } public void onDestroy() { if (this.basemapUI != null) { this.basemapUI.onDestroy(); } super.onDestroy(); } protected void onActivityResult(int i, int i2, Intent intent) { this.basemapUI.onActivityResult(i, i2, intent); } public Object getSystemService(String str) { Object systemService = super.getSystemService(str); if (getAssets() == null || !"layout_inflater".equals(str)) { return systemService; } return v.b((LayoutInflater) systemService); } public Resources getResources() { if (getAssets() == null || ad.getResources() == null) { return super.getResources(); } return ad.getResources(); } public void finish() { super.finish(); } }
[ "denghailong@vargo.com.cn" ]
denghailong@vargo.com.cn
5b503c572f1ababe5dd424b1dfcb2c6163d13944
58081c23331ebc0240b3700670937052e4531ddf
/desktop/src/com/mygdx/game/desktop/LevelTester.java
c6ee2fff97ba0e1224be2bd21970e1bc9a58434c
[]
no_license
Lewis300/PelletGameGit
2688f39cd8a0fa693c33a815f6bab183c22a538f
a1e8d2b8b7a4bfdace560aa47b9c350d33617a1c
refs/heads/master
2021-09-19T21:26:58.185136
2018-08-01T00:06:42
2018-08-01T00:06:42
113,351,695
2
0
null
null
null
null
UTF-8
Java
false
false
1,353
java
package com.mygdx.game.desktop; import com.badlogic.gdx.Gdx; import com.badlogic.gdx.physics.box2d.EdgeShape; import com.mygdx.game.Levels.LevelManager; import com.mygdx.game.PelletGame; import javax.swing.JOptionPane; import com.badlogic.gdx.backends.lwjgl.LwjglApplication; import com.badlogic.gdx.backends.lwjgl.LwjglApplicationConfiguration; import com.mygdx.game.PelletGame; import java.util.ArrayList; import static com.mygdx.game.PelletGame.openAgain; /** * Created by Lewis on 11/30/2017. */ public class LevelTester { public static void main(String[] args) { ArrayList<Integer> nums = new ArrayList<Integer>(); //int num = Integer.parseInt(JOptionPane.showInputDialog("Enter level number")); while (true) { try{nums.add(Integer.parseInt(JOptionPane.showInputDialog("Enter level number")));} catch (Exception e) { break; } } LevelManager.isBeingUsedByLevelTester = true; LevelManager.lvlSequence = nums; LwjglApplication app; LwjglApplicationConfiguration config = new LwjglApplicationConfiguration(); app = new LwjglApplication(new PelletGame(), config); config.width = (int) (360 * 1.5); config.height = (int) (640 * 1.5); openAgain = false; } }
[ "34315738+Lewis300@users.noreply.github.com" ]
34315738+Lewis300@users.noreply.github.com
b613fafc55740119b8b130335235bbb770e6f135
ff57c6df2d055b28bf889f7eeb9ff3264ae87272
/src/br/unb/cic/lp/gol/EstadoPreVivoX.java
caa8370b580ac1d810b6564c5524c348d5b775a4
[]
no_license
caioycosta/gameOfLifeJ
ea2ea8f44cd1c85a470f9fccdeb4a60d2dc283e8
c912eb8d1d603c2f2e60c5e27d1337328b87bd57
refs/heads/master
2020-12-25T04:37:55.229085
2014-07-06T12:42:43
2014-07-06T12:42:43
null
0
0
null
null
null
null
UTF-8
Java
false
false
85
java
package br.unb.cic.lp.gol; public class EstadoPreVivoX extends EstadoVivo { }
[ "codemq.codeplex.com" ]
codemq.codeplex.com
5fcaf08bebc9cf913839af27ba073b9756da62d1
8fc3cf13d7cc0c6aa1f36dfa4b54c3e3e9d760d6
/src/src/data_entry/admin_page.java
870b47350ffd749e074e8dc520e1355a3595f5ef
[ "MIT" ]
permissive
yashica-patodia/SoftwareEngineeringProject
6baeafa19963da0a62ede6222a530dc4bec33717
4c74bcca005e086c01830e5d4f1108e3dc0c87d7
refs/heads/master
2021-10-26T11:43:21.197941
2019-04-12T10:38:18
2019-04-12T10:38:23
null
0
0
null
null
null
null
UTF-8
Java
false
false
23,817
java
/* * To change this license header, choose License Headers in Project Properties. * To change this template file, choose Tools | Templates * and open the template in the editor. */ package data_entry; import java.sql.*; import javax.swing.*; import java.awt.*; import java.lang.*; /** * * @author kanishk */ public class admin_page extends javax.swing.JFrame { /** * Creates new form admin_page */ private String username; private String password; private String usertype; private static final String rootUsername="root";//System.getenv("SE_SQL_USER"); private static final String rootPassword="iit2017";//System.getenv("SE_SQL_PASS"); private static final String conn_string= "jdbc:mysql://localhost:3306";//System.getenv("SE_SQL_CONN"); private Connection conn; private Admin admin=new Admin(); public admin_page() { System.out.println("We are here from admin_gui"); this.setVisible(true); initComponents(); } void list_reset() { int count=0; int i=0; String[] table_name=new String[10]; try{ conn=DriverManager.getConnection(conn_string,rootUsername,rootPassword); Statement st=(Statement)conn.createStatement(); String query="SELECT COUNT(*) FROM information_schema.tables WHERE table_schema = 'demodb'"; ResultSet rs=st.executeQuery(query); rs.next(); count=(rs.getInt(1)); query="SELECT table_name FROM information_schema.tables WHERE table_type = 'base table' AND table_schema='demodb';"; rs=st.executeQuery(query); while(rs.next()) { table_name[i]=rs.getString(1); //System.out.println(table_name[i]); ++i; } } catch(Exception e) { System.out.println(e); } final int Count=count; jList1.setModel(new javax.swing.AbstractListModel<String>() { public int getSize() { return Count; } public String getElementAt(int i) { return table_name[i]; } }); jScrollPane1.setViewportView(jList1); count=0;i=0; String[] pending=new String[10]; try{ conn=DriverManager.getConnection(conn_string+"/demodb",rootUsername,rootPassword); Statement st=(Statement)conn.createStatement(); String query="SELECT * FROM Pending_Requests"; ResultSet rs=st.executeQuery(query); while(rs.next()) { pending[i]=rs.getString(1); //System.out.println(table_name[i]); ++i; } count=i; } catch(Exception e) { System.out.println(e); } final int Count2=count; jList2.setModel(new javax.swing.AbstractListModel<String>() { public int getSize() { return Count2; } public String getElementAt(int i) { return pending[i]; } }); jScrollPane2.setViewportView(jList2); } /** * This method is called from within the constructor to initialize the form. * WARNING: Do NOT modify this code. The content of this method is always * regenerated by the Form Editor. */ @SuppressWarnings("unchecked") // <editor-fold defaultstate="collapsed" desc="Generated Code"> private void initComponents() { jPanel1 = new javax.swing.JPanel(); jLabel1 = new javax.swing.JLabel(); jScrollPane1 = new javax.swing.JScrollPane(); jList1 = new javax.swing.JList<>(); add_col = new javax.swing.JButton(); view_table = new javax.swing.JButton(); delete_table = new javax.swing.JButton(); jScrollPane2 = new javax.swing.JScrollPane(); jList2 = new javax.swing.JList<>(); jLabel2 = new javax.swing.JLabel(); approve = new javax.swing.JButton(); jLabel3 = new javax.swing.JLabel(); jTextField1 = new javax.swing.JTextField(); jLabel4 = new javax.swing.JLabel(); create_table = new javax.swing.JButton(); view_message = new javax.swing.JButton(); jPanel2 = new javax.swing.JPanel(); jLabel5 = new javax.swing.JLabel(); back_button = new javax.swing.JButton(); setDefaultCloseOperation(javax.swing.WindowConstants.EXIT_ON_CLOSE); setTitle("WELCOME MY ADMIN"); setAlwaysOnTop(true); setFont(new java.awt.Font("Liberation Sans", 1, 14)); // NOI18N jPanel1.setBackground(new java.awt.Color(41, 241, 195)); jLabel1.setFont(new java.awt.Font("Liberation Sans", 1, 14)); // NOI18N jLabel1.setForeground(java.awt.Color.black); jLabel1.setText("Current Datatables"); add_col.setFont(new java.awt.Font("Liberation Sans", 1, 12)); // NOI18N add_col.setForeground(java.awt.Color.black); add_col.setText("Add Column"); add_col.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent evt) { add_colActionPerformed(evt); } }); view_table.setFont(new java.awt.Font("Liberation Sans", 1, 12)); // NOI18N view_table.setForeground(java.awt.Color.black); view_table.setText("View Table"); view_table.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent evt) { view_tableActionPerformed(evt); } }); delete_table.setFont(new java.awt.Font("Liberation Sans", 1, 12)); // NOI18N delete_table.setForeground(java.awt.Color.black); delete_table.setText("Delete"); delete_table.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent evt) { delete_tableActionPerformed(evt); } }); this.list_reset(); jLabel2.setFont(new java.awt.Font("Liberation Sans", 1, 14)); // NOI18N jLabel2.setForeground(java.awt.Color.black); jLabel2.setText("Pending Requests"); approve.setFont(new java.awt.Font("Liberation Sans", 1, 12)); // NOI18N approve.setForeground(java.awt.Color.black); approve.setText("Approve "); approve.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent evt) { approveActionPerformed(evt); } }); jLabel3.setFont(new java.awt.Font("Liberation Sans", 1, 12)); // NOI18N jLabel3.setForeground(java.awt.Color.black); jLabel3.setText("New Table?"); jLabel4.setFont(new java.awt.Font("Liberation Sans", 1, 12)); // NOI18N jLabel4.setForeground(java.awt.Color.black); jLabel4.setText("Columns:"); create_table.setFont(new java.awt.Font("Liberation Sans", 1, 12)); // NOI18N create_table.setForeground(java.awt.Color.black); create_table.setText("Create Table"); create_table.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent evt) { create_tableActionPerformed(evt); } }); view_message.setFont(new java.awt.Font("Liberation Sans", 1, 12)); // NOI18N view_message.setForeground(java.awt.Color.black); view_message.setText("View Message"); view_message.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent evt) { view_messageActionPerformed(evt); } }); jPanel2.setBackground(new java.awt.Color(36, 37, 42)); jLabel5.setFont(new java.awt.Font("Liberation Sans", 1, 14)); // NOI18N jLabel5.setForeground(java.awt.Color.white); jLabel5.setText("WELCOME ADMIN "); javax.swing.GroupLayout jPanel2Layout = new javax.swing.GroupLayout(jPanel2); jPanel2.setLayout(jPanel2Layout); jPanel2Layout.setHorizontalGroup( jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, jPanel2Layout.createSequentialGroup() .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE) .addComponent(jLabel5, javax.swing.GroupLayout.PREFERRED_SIZE, 214, javax.swing.GroupLayout.PREFERRED_SIZE) .addGap(203, 203, 203)) ); jPanel2Layout.setVerticalGroup( jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGroup(jPanel2Layout.createSequentialGroup() .addContainerGap() .addComponent(jLabel5, javax.swing.GroupLayout.DEFAULT_SIZE, 33, Short.MAX_VALUE) .addContainerGap()) ); back_button.setFont(new java.awt.Font("Liberation Sans", 1, 12)); // NOI18N back_button.setForeground(java.awt.Color.black); back_button.setText("Back"); back_button.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent evt) { gobacktologin(evt); } }); javax.swing.GroupLayout jPanel1Layout = new javax.swing.GroupLayout(jPanel1); jPanel1.setLayout(jPanel1Layout); jPanel1Layout.setHorizontalGroup( jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGroup(jPanel1Layout.createSequentialGroup() .addContainerGap() .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGroup(jPanel1Layout.createSequentialGroup() .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addComponent(jLabel3, javax.swing.GroupLayout.PREFERRED_SIZE, 142, javax.swing.GroupLayout.PREFERRED_SIZE) .addComponent(jLabel4, javax.swing.GroupLayout.PREFERRED_SIZE, 64, javax.swing.GroupLayout.PREFERRED_SIZE)) .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)) .addGroup(jPanel1Layout.createSequentialGroup() .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false) .addGroup(jPanel1Layout.createSequentialGroup() .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING, false) .addGroup(jPanel1Layout.createSequentialGroup() .addGap(76, 76, 76) .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING) .addComponent(jTextField1, javax.swing.GroupLayout.PREFERRED_SIZE, 117, javax.swing.GroupLayout.PREFERRED_SIZE) .addComponent(create_table))) .addGroup(jPanel1Layout.createSequentialGroup() .addComponent(add_col, javax.swing.GroupLayout.PREFERRED_SIZE, 103, javax.swing.GroupLayout.PREFERRED_SIZE) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE) .addComponent(view_table, javax.swing.GroupLayout.PREFERRED_SIZE, 95, javax.swing.GroupLayout.PREFERRED_SIZE))) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED) .addComponent(delete_table, javax.swing.GroupLayout.PREFERRED_SIZE, 81, javax.swing.GroupLayout.PREFERRED_SIZE)) .addComponent(jLabel1, javax.swing.GroupLayout.PREFERRED_SIZE, 149, javax.swing.GroupLayout.PREFERRED_SIZE) .addComponent(jScrollPane1)) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, 55, Short.MAX_VALUE) .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addComponent(jLabel2, javax.swing.GroupLayout.PREFERRED_SIZE, 149, javax.swing.GroupLayout.PREFERRED_SIZE) .addComponent(jScrollPane2, javax.swing.GroupLayout.PREFERRED_SIZE, 237, javax.swing.GroupLayout.PREFERRED_SIZE) .addGroup(jPanel1Layout.createSequentialGroup() .addComponent(view_message, javax.swing.GroupLayout.PREFERRED_SIZE, 113, javax.swing.GroupLayout.PREFERRED_SIZE) .addGap(21, 21, 21) .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addComponent(back_button, javax.swing.GroupLayout.PREFERRED_SIZE, 103, javax.swing.GroupLayout.PREFERRED_SIZE) .addComponent(approve, javax.swing.GroupLayout.PREFERRED_SIZE, 103, javax.swing.GroupLayout.PREFERRED_SIZE)))) .addGap(42, 42, 42)))) .addComponent(jPanel2, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE) ); jPanel1Layout.setVerticalGroup( jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGroup(jPanel1Layout.createSequentialGroup() .addComponent(jPanel2, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE) .addGap(53, 53, 53) .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE) .addComponent(jLabel1, javax.swing.GroupLayout.PREFERRED_SIZE, 30, javax.swing.GroupLayout.PREFERRED_SIZE) .addComponent(jLabel2, javax.swing.GroupLayout.PREFERRED_SIZE, 30, javax.swing.GroupLayout.PREFERRED_SIZE)) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED) .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false) .addComponent(jScrollPane2, javax.swing.GroupLayout.DEFAULT_SIZE, 86, Short.MAX_VALUE) .addComponent(jScrollPane1, javax.swing.GroupLayout.PREFERRED_SIZE, 0, Short.MAX_VALUE)) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED) .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE) .addComponent(add_col) .addComponent(view_table) .addComponent(delete_table) .addComponent(approve) .addComponent(view_message)) .addGap(32, 32, 32) .addComponent(jLabel3, javax.swing.GroupLayout.PREFERRED_SIZE, 23, javax.swing.GroupLayout.PREFERRED_SIZE) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED) .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE) .addComponent(jLabel4) .addComponent(jTextField1, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED) .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addComponent(create_table) .addComponent(back_button)) .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)) ); javax.swing.GroupLayout layout = new javax.swing.GroupLayout(getContentPane()); getContentPane().setLayout(layout); layout.setHorizontalGroup( layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addComponent(jPanel1, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE) ); layout.setVerticalGroup( layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addComponent(jPanel1, javax.swing.GroupLayout.Alignment.TRAILING, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE) ); pack(); }// </editor-fold> private void approveActionPerformed(java.awt.event.ActionEvent evt) { // TODO add your handling code here: String a=jList2.getSelectedValue().toString(); String b=jList1.getSelectedValue().toString(); Table t1=new Table(b); String[] A=new String[t1.col]; for(int i=0;i<t1.col;++i) { A[i]=null; } admin.add_row_dynamically(b, A,t1.col); System.out.println(a); String[] data=new String[2]; int i=0; try{ conn= DriverManager.getConnection(conn_string+"/demodb", rootUsername, rootPassword); Statement st=(Statement)conn.createStatement(); String sql ="Select * from Pending_Requests where Name='"+a+"';"; ResultSet rs=st.executeQuery(sql); rs.next(); data[0]=rs.getString(2); data[1]=rs.getString(3); } catch(SQLException e) { System.out.println(e); } admin.add_row("USERS", data[0], data[1], "",""); admin.delete("Pending_Requests",a); this.list_reset(); } private void add_colActionPerformed(java.awt.event.ActionEvent evt) { // TODO add your handling code here: String a=jList1.getSelectedValue().toString(); add_column_revised add=new add_column_revised(a); this.setVisible(false); this.dispose(); } private void create_tableActionPerformed(java.awt.event.ActionEvent evt) { // TODO add your handling code here: int x=Integer.parseInt(jTextField1.getText()); this.setVisible(false); this.dispose(); new create_new_table(x); } private void view_messageActionPerformed(java.awt.event.ActionEvent evt) { // TODO add your handling code here: try{ conn= DriverManager.getConnection(conn_string+"/demodb", rootUsername, rootPassword); Statement st=(Statement)conn.createStatement(); String a=jList2.getSelectedValue().toString(); String sql ="Select * from Pending_Requests where Name='"+a+"';"; ResultSet rs=st.executeQuery(sql); rs.next(); String message=rs.getString(4); javax.swing.JOptionPane.showMessageDialog(getContentPane(),message); } catch(SQLException e) { System.out.println(e); } } private void gobacktologin(java.awt.event.ActionEvent evt) { // TODO add your handling code here: this.setVisible(false); this.dispose(); new login(); } private void view_tableActionPerformed(java.awt.event.ActionEvent evt) { // TODO add your handling code here: String a = jList1.getSelectedValue().toString(); admin.view_table(a); this.list_reset(); } private void delete_tableActionPerformed(java.awt.event.ActionEvent evt) { // TODO add your handling code here: String a = jList1.getSelectedValue().toString(); admin.drop_table(a); this.list_reset(); } /** * @param args the command line arguments */ public static void main(String args[]) { /* Set the Nimbus look and feel */ //<editor-fold defaultstate="collapsed" desc=" Look and feel setting code (optional) "> /* If Nimbus (introduced in Java SE 6) is not available, stay with the default look and feel. * For details see http://download.oracle.com/javase/tutorial/uiswing/lookandfeel/plaf.html */ try { for (javax.swing.UIManager.LookAndFeelInfo info : javax.swing.UIManager.getInstalledLookAndFeels()) { if ("Nimbus".equals(info.getName())) { javax.swing.UIManager.setLookAndFeel(info.getClassName()); break; } } } catch (ClassNotFoundException ex) { java.util.logging.Logger.getLogger(admin_page.class.getName()).log(java.util.logging.Level.SEVERE, null, ex); } catch (InstantiationException ex) { java.util.logging.Logger.getLogger(admin_page.class.getName()).log(java.util.logging.Level.SEVERE, null, ex); } catch (IllegalAccessException ex) { java.util.logging.Logger.getLogger(admin_page.class.getName()).log(java.util.logging.Level.SEVERE, null, ex); } catch (javax.swing.UnsupportedLookAndFeelException ex) { java.util.logging.Logger.getLogger(admin_page.class.getName()).log(java.util.logging.Level.SEVERE, null, ex); } //</editor-fold> /* Create and display the form */ java.awt.EventQueue.invokeLater(new Runnable() { public void run() { new admin_page().setVisible(true); } }); } // Variables declaration - do not modify private javax.swing.JButton add_col; private javax.swing.JButton approve; private javax.swing.JButton back_button; private javax.swing.JButton create_table; private javax.swing.JButton delete_table; private javax.swing.JLabel jLabel1; private javax.swing.JLabel jLabel2; private javax.swing.JLabel jLabel3; private javax.swing.JLabel jLabel4; private javax.swing.JLabel jLabel5; private javax.swing.JList<String> jList1; private javax.swing.JList<String> jList2; private javax.swing.JPanel jPanel1; private javax.swing.JPanel jPanel2; private javax.swing.JScrollPane jScrollPane1; private javax.swing.JScrollPane jScrollPane2; private javax.swing.JTextField jTextField1; private javax.swing.JButton view_message; private javax.swing.JButton view_table; // End of variables declaration }
[ "singhkanishk7777@gmail.com" ]
singhkanishk7777@gmail.com
f86a4f1477f016cb00f248ae6335d9080e0e5636
3b6caea5f5718c5acffd866aae98f22c78324f65
/app/src/main/java/com/example/user/ling/SpeechSearch.java
8ea50bbf066e97a70456c9ba6a82edba89fe4e99
[]
no_license
ionson100/myassistant
0d8cfe70c91038dd6f5c6457d5800232afb47b55
43a1bec5030f307d6bea7b2fe6005a2e220f3bc4
refs/heads/master
2020-05-23T08:19:21.363056
2017-10-30T04:53:36
2017-10-30T04:53:36
70,228,251
0
0
null
null
null
null
UTF-8
Java
false
false
2,263
java
package com.example.user.ling; import android.app.Activity; import android.content.Intent; import android.content.pm.PackageManager; import android.speech.RecognizerIntent; import android.view.View; import android.widget.ImageButton; import java.util.List; class SpeechSearch{ static final int SPEECH=23; private ImageButton imageButton; private final MainActivity activity; SpeechSearch(MainActivity activity){ this.imageButton = (ImageButton) activity.findViewById(R.id.image_microphone); this.activity = activity; } void activate(){ if(!isSpeechRecognitionActivityPresented(activity)){ activity.findViewById(R.id.parent_microphon).setVisibility(View.GONE); return; } imageButton.setOnClickListener(new View.OnClickListener() { @Override public void onClick(View v) { // создаем Intent с действием RecognizerIntent.ACTION_RECOGNIZE_SPEECH Intent intent = new Intent(RecognizerIntent.ACTION_RECOGNIZE_SPEECH); // добавляем дополнительные параметры: if(Settings.core().directTraslate){ }else{ intent.putExtra(RecognizerIntent.EXTRA_LANGUAGE, "en-US"); } intent.putExtra(RecognizerIntent.EXTRA_PROMPT, "Голосовой поиск"); intent.putExtra(RecognizerIntent.EXTRA_LANGUAGE_MODEL,"ru-RU" );//RecognizerIntent.LANGUAGE_MODEL_FREE_FORM intent.putExtra(RecognizerIntent.EXTRA_MAX_RESULTS, 1); // стартуем Activity и ждем от нее результата activity.startActivityForResult(intent, SPEECH); } }); } private static boolean isSpeechRecognitionActivityPresented(Activity ownerActivity) { try { PackageManager pm = ownerActivity.getPackageManager(); List activities = pm.queryIntentActivities(new Intent(RecognizerIntent.ACTION_RECOGNIZE_SPEECH), 0); if (activities.size() != 0) { return true; } } catch (Exception ignore) {} return false; } }
[ "ion100@mail.ru" ]
ion100@mail.ru
865730fbfef66ab01f22df2ccad8e705656e7a15
94d1128e0ac0a463598f6fb8190f7ab4370c4cd6
/android/app/src/main/java/com/kadirnacar/callbackup/utils/OpusEncoder.java
af811078b7dbad1b21646274da0876ea20b197ed
[]
no_license
kadirnacar/callbackup
794deff7c628add000a52c7ff7412f603c953580
1866e08324c3acb660d80efb28e46a8cf5e6fcb6
refs/heads/master
2023-01-24T10:33:35.694767
2020-12-03T13:41:11
2020-12-03T13:41:11
317,187,512
0
0
null
null
null
null
UTF-8
Java
false
false
2,294
java
package com.kadirnacar.callbackup.utils; import androidx.annotation.IntDef; import androidx.annotation.IntRange; import java.lang.annotation.Retention; import java.lang.annotation.RetentionPolicy; public class OpusEncoder { // Native pointer to OpusEncoder. private long address; public static final int OPUS_AUTO = -1; public static final int OPUS_BITRATE_MAX = -1; public static final int OPUS_COMPLEXITY_MAX = 10; @Retention(RetentionPolicy.SOURCE) @IntDef({OPUS_APPLICATION_VOIP, OPUS_APPLICATION_AUDIO, OPUS_APPLICATION_RESTRICTED_LOWDELAY}) public @interface ApplicationType {} public static final int OPUS_APPLICATION_VOIP = 2048; public static final int OPUS_APPLICATION_AUDIO = 2049; public static final int OPUS_APPLICATION_RESTRICTED_LOWDELAY = 2051; private native int nativeInitEncoder(@Annotations.SamplingRate int samplingRate, @Annotations.NumberOfChannels int numberOfChannels, @ApplicationType int application); private native int nativeSetBitrate(int bitrate); private native int nativeSetComplexity(@IntRange(from=0, to=10) int complexity); private native int nativeEncodeShorts(short[] in, int frames, byte[] out); private native int nativeEncodeBytes(byte[] in, int frames, byte[] out); private native boolean nativeReleaseEncoder(); static { System.loadLibrary("callbackup"); } public void init(int sampleRate, int channels, int application) { OpusError.throwIfError(this.nativeInitEncoder(sampleRate, channels, application)); } public void setBitrate(int bitrate) { OpusError.throwIfError(this.nativeSetBitrate(bitrate)); } public void setComplexity(int complexity) { OpusError.throwIfError(this.nativeSetComplexity(complexity)); } public int encode(short[] buffer, int frames, byte[] out) { return OpusError.throwIfError(this.nativeEncodeShorts(buffer, frames, out)); } public int encode(byte[] buffer, int frames, byte[] out) { return OpusError.throwIfError(this.nativeEncodeBytes(buffer, frames, out)); } public void close() { this.nativeReleaseEncoder(); } }
[ "kadirnacar@kadirnacar.com" ]
kadirnacar@kadirnacar.com
271056e7e86a7edaf42f3d97c5d00d9c0c00779c
d4261417db59c92bb118cb7ec12c0bc43c85d62f
/src/de/uni/bielefeld/sc/hterhors/psink/obie/projects/soccerplayer/ontology/interfaces/IBuenaventuraFerreira.java
664035d358e41cf2ead905ddeb74b6673b64b360
[ "Apache-2.0" ]
permissive
berezovskyi/SoccerPlayerOntology
ed3a24a7ace88ba209f5439a49b04c11a8e6034a
c7dafee008911b45a2b9e8c55ffd43c1e69c3660
refs/heads/master
2022-06-20T02:17:21.385038
2018-09-21T17:09:38
2018-09-21T17:09:38
149,870,122
0
0
Apache-2.0
2022-05-20T22:00:24
2018-09-22T11:19:31
Java
UTF-8
Java
false
false
611
java
package de.uni.bielefeld.sc.hterhors.psink.obie.projects.soccerplayer.ontology.interfaces; import de.uni.bielefeld.sc.hterhors.psink.obie.core.ontology.annotations.AssignableSubInterfaces; import de.uni.bielefeld.sc.hterhors.psink.obie.core.ontology.annotations.ImplementationClass; import de.uni.bielefeld.sc.hterhors.psink.obie.projects.soccerplayer.ontology.classes.BuenaventuraFerreira; /** * * @author hterhors * * * Sep 6, 2018 */ @AssignableSubInterfaces(get = {}) @ImplementationClass(get = BuenaventuraFerreira.class) public interface IBuenaventuraFerreira extends ISoccerPlayer { }
[ "hterhors@techfak.uni-bielefeld.de" ]
hterhors@techfak.uni-bielefeld.de
101809cc32abca9f4e4151d9c8ac21786f90e189
6c7b83e078844fa43fad651e2d7908666316f88c
/src/main/java/org/cn/lyh/util/tag/ByteToStringTag.java
2a4ef4254ce42b09c9aca780751fa4b4c3acb97f
[]
no_license
liuyihuansmm/Blog
ee0cf6f3d786b87086a2071a8f187cab14d8c089
99dbbd7557e9bea865d72716b332b810bf360953
refs/heads/master
2021-01-21T05:09:50.725261
2017-03-28T02:56:28
2017-03-28T02:56:28
83,114,117
0
0
null
null
null
null
UTF-8
Java
false
false
2,064
java
package org.cn.lyh.util.tag; /** * Created by LYH on 2017/3/2. */ import javax.servlet.jsp.JspException; import javax.servlet.jsp.JspWriter; import javax.servlet.jsp.tagext.SimpleTagSupport; import java.io.IOException; import java.util.Random; import java.util.regex.Matcher; import java.util.regex.Pattern; public class ByteToStringTag extends SimpleTagSupport { private byte[] content; public void setContent(byte[] content) { this.content = content; } private byte[] summary; public void setSummary(byte[] summary) { this.summary = summary; } @Override public void doTag() throws JspException, IOException { JspWriter out = getJspContext().getOut(); if (content != null){ out.write(new String(content,"UTF-8")); } if (summary !=null){ String strTxt = replaceHtml(new String(summary,"UTF-8")); if(strTxt.length()>50){ out.write(strTxt.substring(0,50)); }else{ out.write(strTxt.substring(0,strTxt.length())); } } } public String replaceHtml(String htmlStr){ String regEx_script="<script[^>]*?>[\\s\\S]*?<\\/script>"; //定义script的正则表达式 String regEx_style="<style[^>]*?>[\\s\\S]*?<\\/style>"; //定义style的正则表达式 String regEx_html="<[^>]+>"; //定义HTML标签的正则表达式 Pattern p_script=Pattern.compile(regEx_script,Pattern.CASE_INSENSITIVE); Matcher m_script=p_script.matcher(htmlStr); htmlStr=m_script.replaceAll(""); //过滤script标签 Pattern p_style=Pattern.compile(regEx_style,Pattern.CASE_INSENSITIVE); Matcher m_style=p_style.matcher(htmlStr); htmlStr=m_style.replaceAll(""); //过滤style标签 Pattern p_html=Pattern.compile(regEx_html,Pattern.CASE_INSENSITIVE); Matcher m_html=p_html.matcher(htmlStr); htmlStr=m_html.replaceAll(""); //过滤html标签 return htmlStr.trim(); //返回文本字符串 } }
[ "liuyihuansmm@163.com" ]
liuyihuansmm@163.com
efae921ff69224f3a00a8ba779a312f5b00b8b17
c84b6d66be3d7545452e9916f3809861a668a88f
/foundation/src/main/java/com/further/foundation/download/ProgressResponseBody.java
46416269ff025be3f04510c83288a06b52b0dcc2
[]
no_license
smilewant/A-J
874d89d97be773ec1e4a98f57f2a5f3015eceb4e
7dda68d3ea78f5579132d0e52bd03c6f48dde5b5
refs/heads/master
2021-08-08T09:22:03.144055
2021-06-21T05:50:18
2021-06-21T05:50:18
171,210,729
0
0
null
null
null
null
UTF-8
Java
false
false
1,829
java
package com.further.foundation.download; import java.io.IOException; import okhttp3.MediaType; import okhttp3.ResponseBody; import okio.Buffer; import okio.BufferedSource; import okio.ForwardingSource; import okio.Okio; import okio.Source; public class ProgressResponseBody extends ResponseBody { private final ResponseBody responseBody; private final com.aihuishou.jdx.jdx_common.download.ProgressListener progressListener; private BufferedSource bufferedSource; private final String url; ProgressResponseBody(String url, ResponseBody responseBody, com.aihuishou.jdx.jdx_common.download.ProgressListener progressListener) { this.responseBody = responseBody; this.progressListener = progressListener; this.url = url; } @Override public MediaType contentType() { return responseBody.contentType(); } @Override public long contentLength() { return responseBody.contentLength(); } @Override public BufferedSource source() { if (bufferedSource == null) { bufferedSource = Okio.buffer(source(responseBody.source())); } return bufferedSource; } private Source source(final Source source) { return new ForwardingSource(source) { long totalBytesRead = 0L; @Override public long read(Buffer sink, long byteCount) throws IOException { long bytesRead = super.read(sink, byteCount); // read() returns the number of bytes read, or -1 if this source is exhausted. totalBytesRead += bytesRead != -1 ? bytesRead : 0; progressListener.update(url, totalBytesRead, responseBody.contentLength(), String.valueOf(bytesRead)); return bytesRead; } }; } }
[ "zion.hu@aihuishou.com" ]
zion.hu@aihuishou.com
3389d1fda1a0ce711209668d6028d49ad1559d2e
19a5e40a287b980e9f2a0620e1cd1435a613182a
/src/LinkedList/Controller.java
820de143e4182344273f69d07425a661b96b2181
[]
no_license
adianand13/Data_Structures
1b8ee30f9b0e3893350b5496bf630c8f10cbdd78
f64d27fef1d3627655bbb7d2debadbe569658402
refs/heads/master
2023-01-03T20:18:36.971400
2019-06-16T16:50:26
2019-06-16T16:50:26
null
0
0
null
null
null
null
UTF-8
Java
false
false
6,276
java
package LinkedList; public class Controller { private Node Head; private Node Tail; private int Length; public Controller() { Head = null; Tail = null; Length = 0; } public boolean isEmpty() { return (Head == null); } public int length() { return Length; } public void push(int value) { if (Head == null) { Head = Tail = new Node(value); Length ++; } else { Tail.setNext(new Node(value)); Tail = Tail.getNext(); Length ++; } } public Node pop() { if (Head == null) return null; else if (Head == Tail) { Node temp = Head; Head = Tail = null; Length = 0; return Head; } else { Node newTail = Head; while (newTail.getNext().hasNext()){ newTail = newTail.getNext(); } Node temp = Tail; Tail = newTail; Tail.setNext(null); Length --; return temp; } } //traverses the entire Linked list public void traverse() { if (Head == null) System.out.println("Empty List"); else { Node iterator = Head; for (int i = 0; i < Length; i++) { System.out.print(iterator.getValue() + " "); iterator = iterator.getNext(); } System.out.println(); } } public Node getHead() { return Head; } //Shifts head by one node public Node shift(){ if (Head == null) return null; Head = Head.hasNext() ? Head.getNext() : null; Length --; return Head; } public Node remove(int index){ if (index < 0 || index >= Length) System.out.println("IndexOutOfBoundsException"); else if(index == 0) return shift(); else if (index == Length-1) return pop(); else { Node iterator = Head.getNext(); for (int i = 1; i < index-1; i++) iterator = iterator.getNext(); Node temp = iterator.getNext(); iterator.setNext(iterator.getNext().getNext()); Length --; return temp; } return null; } //Insert a new node to start public void insertHead(int value){ Head = Head == null ? new Node(value,null) : new Node(value, Head); Length ++; } //insert at specific index public boolean insert(int index, int value){ if (index < 0 || index >= Length) System.out.println("IndexOutOfBoundsException"); else if(index == 0){ insertHead(value); return true; } else if (index == Length-1){ push(value); return true; } else { Node iterator = Head.getNext(); for (int i = 1; i < index; i++) iterator = iterator.getNext(); iterator.setNext(new Node(value,iterator.getNext())); Length ++; return true; } return false; } public int get(int index){ if (index < 0 || index >= Length) System.out.println("IndexOutOfBoundsException"); else if(index == 0) return Head.getValue(); else if (index == Length-1) return Tail.getValue(); else { Node iterator = Head.getNext(); for (int i = 1; i <= index; i++) iterator = iterator.getNext(); return iterator.getValue(); } return Integer.MIN_VALUE; } public boolean set(int value, int index){ if (index < 0 && index >= Length){ System.out.println("IndexOutOfBoundsException"); return false; } else if(index == 0) Head.setValue(value); else if (index == Length-1) Tail.setValue(value); else { Node iterator = Head.getNext(); for (int i = 1; i < index; i++) iterator = iterator.getNext(); iterator.setValue(value); } return true; } //to reverse the linked list public void reverse(){ Node node = Head; Head = Tail; Tail = node; Node prev = null, next; for (int i = 0; i < Length; i++) { next = node.getNext(); node.setNext(prev); prev = node; node = next; } } //test code public static void main(String[] args) { Controller Dlist = new Controller(); System.out.println(Dlist.isEmpty()); System.out.println("push operation"); Dlist.push(10); Dlist.push(20); Dlist.push(30);Dlist.push(40); Dlist.push(50); Dlist.push(60); Dlist.push(70); Dlist.traverse(); System.out.println(Dlist.length()); System.out.println("pop operation"); Dlist.pop(); Dlist.pop(); Dlist.pop(); Dlist.pop(); Dlist.traverse(); System.out.println(Dlist.length()); System.out.println("Shift Operation"); Dlist.shift(); Dlist.traverse(); System.out.println("Insert head operation"); Dlist.insertHead(10); Dlist.traverse(); System.out.println(Dlist.length()); System.out.println("set operation"); Dlist.set(22, 1); Dlist.traverse(); System.out.println("push operation"); Dlist.push(30); Dlist.push(40); Dlist.push(50); Dlist.push(60); Dlist.push(70); Dlist.traverse(); System.out.println(Dlist.length()); System.out.println("Get operation"); System.out.println(Dlist.get(3)); System.out.println(Dlist.get(1)); System.out.println(Dlist.length()); System.out.println("remove operation"); Dlist.remove(3); Dlist.traverse(); System.out.println(Dlist.length()); System.out.println("Insert operation"); Dlist.insert(5,55); System.out.println(Dlist.length()); Dlist.traverse(); Dlist.reverse(); Dlist.traverse(); Dlist.reverse(); Dlist.traverse(); } }
[ "anand.aditya.anand@gmail.com" ]
anand.aditya.anand@gmail.com
4a98116457136bcf4b553176a03158dec846bd9f
45f18a850595ad4dd417c1991a0ef69cefde99dd
/gablum-contracts/src/main/java/com/gablum/contract/contracts/model/othermodels/User.java
1454dc729ffe61f75200cbf8f7b3e7434f67d295
[]
no_license
imperfect-abhi/stackroute-gablum-project
3a8fb030f7b0f3213cf0c47486fff5036f9531b5
58e6934be60d4dc22ef0f9b897a02d396693a455
refs/heads/master
2022-06-19T16:15:45.446765
2019-12-18T07:04:59
2019-12-18T07:04:59
228,779,040
0
0
null
2022-06-03T00:58:26
2019-12-18T07:03:21
TypeScript
UTF-8
Java
false
false
2,118
java
package com.gablum.contract.contracts.model.othermodels; import com.gablum.contract.contracts.model.Block; import lombok.*; import java.util.*; @Getter @Setter @NoArgsConstructor @AllArgsConstructor @ToString public class User { private String _id; private String name; private String email; private String password; private String address; private String phone; private String companyName; private String userName; private String businessLicense; private String businessDomain; private String businessSubDomain; private List<Map<String, List<String>>> userDomainDetails; private Map<String, String> hashEncryptionKeyList; private List<Block> blockchain; private List<String> contractIdList; private List<String> proposalIdList; private List<String> auctionIdList; private List<String> bidIdList; public void addDomainDetails(String domain, String subDomain){ if(domain == null){ domain = "Agriculture"; } List<String> newDetails = new ArrayList<String>(); newDetails.add(subDomain); Map<String, List<String>> singleDomainDetails = new HashMap<>(); singleDomainDetails.put(domain, newDetails); userDomainDetails.add(singleDomainDetails); } private Set<Role> role = Set.of(new Role(1, "buyer")); private Integer active=1; private boolean isLocked=false; private boolean isExpired=false; private boolean isEnabled=true; private float rating; private Date createdOn; public boolean isLocked() { return isLocked; } public void setLocked(boolean locked) { isLocked = locked; } public boolean isExpired() { return isExpired; } public void setExpired(boolean expired) { isExpired = expired; } public boolean isEnabled() { return isEnabled; } public void setEnabled(boolean enabled) { isEnabled = enabled; } public Set<Role> getRole() { return role; } public void setRole(Set<Role> role) { this.role = role; } }
[ "er.abhisheksingh2764@gmail.com" ]
er.abhisheksingh2764@gmail.com
afe1ccc32a1e06974badcf64e0222f51793769c0
5308297e063c59a065a025711ae62b0b7b015886
/SDK/src/com/skyworth/ui/skydata/TVOrderItem.java
f86dbfb00d679d7b90133f64ce1e6867291428bd
[]
no_license
bibiRe/AppStore
77ddde3261cabe9294ffb74714c00febd0ec7268
06f5e05050ad01753fd9e6a9f6ec251474e3c6f1
refs/heads/master
2020-12-29T01:54:54.175750
2014-02-12T07:30:44
2014-02-12T07:30:44
null
0
0
null
null
null
null
UTF-8
Java
false
false
1,638
java
/** * Copyright (C) 2012 The SkyTvOS Project * * Version Date Author * ───────────────────────────────────── * 2012-12-16 rico * */ package com.skyworth.ui.skydata; import java.util.UUID; import com.skyworth.framework.SkyData; /** * @ClassName TVOrderItem * @Description TODO (write something) * @author rico * @date 2012-12-16 * @version TODO (write something) */ public class TVOrderItem { public String itemleftStr = ""; public String itemmiddleStr = ""; public String itemrightStr = ""; public String itembtnStr = ""; public String itemid = UUID.randomUUID().toString(); public TVOrderItem(String leftStr, String middleStr,String rightStr,String btnStr) { this.itemleftStr = leftStr; this.itemmiddleStr = middleStr; this.itemrightStr = rightStr; this.itembtnStr = btnStr; } public TVOrderItem(String serialized) { SkyData data = new SkyData(serialized); itemleftStr = data.getString("leftStr"); itemmiddleStr = data.getString("middleStr"); itemrightStr = data.getString("rightStr"); itembtnStr = data.getString("btnStr"); itemid = data.getString("id"); } public String toString() { SkyData data = new SkyData(); data.add("leftStr", itemleftStr); data.add("middleStr", itemmiddleStr); data.add("rightStr", itemrightStr); data.add("btnStr", itembtnStr); data.add("id", itemid); return data.toString(); } }
[ "haotie1990@gmail.com" ]
haotie1990@gmail.com
05e9ae572ca7107b262e590e813e2a842e1fc101
16dfd8dc0ee6a51807b60c51175b7a2f4aba3686
/src/main/java/com/jd/stackoverflow/ServletInitializer.java
b90bba5d336ceb80376653747c8d37b811fe0af5
[]
no_license
Jamey-Dogom/StackOverflow_clone
0e2e2a2a005712682696652e980a3028aef0ea58
208356e1d496600edaab8f2c12e7e0a878c75352
refs/heads/master
2020-07-04T21:40:04.405298
2019-08-14T21:22:34
2019-08-14T21:22:34
202,427,690
3
1
null
null
null
null
UTF-8
Java
false
false
422
java
package com.jd.stackoverflow; import org.springframework.boot.builder.SpringApplicationBuilder; import org.springframework.boot.web.servlet.support.SpringBootServletInitializer; public class ServletInitializer extends SpringBootServletInitializer { @Override protected SpringApplicationBuilder configure(SpringApplicationBuilder application) { return application.sources(StackOverflowCloneApplication.class); } }
[ "33010705+AppJedi@users.noreply.github.com" ]
33010705+AppJedi@users.noreply.github.com
9f37944dfb1345a067cc5fc60b2c63c25d319ea9
9b4f3a245afe9b18adf715657faf8d3c1591636c
/backtoken/src/main/java/com/example/backtoken/repository/EventtkRepository.java
a191985f4af48041b99d8b2781f8189e397031eb
[]
no_license
JoaoVSN/TestTokenlab
426ad9ce4c2127740cb45467c6f3133ec044375d
e0ca422e38d48be548abbd57f0bd03bd76248c9c
refs/heads/main
2022-12-30T12:30:29.947928
2020-10-14T02:37:37
2020-10-14T02:37:37
303,879,757
0
0
null
null
null
null
UTF-8
Java
false
false
779
java
package com.example.backtoken.repository; import com.example.backtoken.model.Eventtk; import org.springframework.data.jpa.repository.Query; import org.springframework.data.repository.NoRepositoryBean; import org.springframework.data.repository.PagingAndSortingRepository; import org.springframework.data.repository.query.Param; import java.util.List; public interface EventtkRepository extends PagingAndSortingRepository<Eventtk, Long> { @Query("SELECT ev FROM Eventtk ev WHERE UPPER(ev.ev_desc) LIKE UPPER (concat('%', :desc, '%'))") List<Eventtk> findByEv_descIgnoreCaseContaining(@Param("desc") String ev_desc); @Query("SELECT ev FROM Eventtk ev WHERE ev.ev_us_id.us_login LIKE :user ") List<Eventtk> findAllByEv_us_login(@Param("user") String ev_us_id); }
[ "noreply@github.com" ]
JoaoVSN.noreply@github.com
5dd7c0fc824c47fb3930d0a81e658ea6ff982e1b
6cc979ac7b8b102650942e659fad65f2a91843ae
/app/src/main/java/com/homeless/jackrututorialretrofit/remote/UserService.java
189b76c4239fa511c85295cf8d9fa610bcb29c62
[]
no_license
mustafacakar/basicLogin
3658b78ed2aa569c862e5008a4535cf8d703338b
2e7437590a5a6e6c6392fbde7483e3dcb0ec3a5c
refs/heads/master
2020-08-20T02:52:18.280008
2019-10-18T08:27:07
2019-10-18T08:27:07
215,977,124
0
0
null
null
null
null
UTF-8
Java
false
false
365
java
package com.homeless.jackrututorialretrofit.remote; import com.homeless.jackrututorialretrofit.model.ResObj; import retrofit2.Call; import retrofit2.http.GET; import retrofit2.http.Path; public interface UserService { @GET("/Meterial/{username}/{password} ") Call<ResObj> login(@Path("username") String username,@Path("password") String password); }
[ "mistik_cakar@hotmail.com" ]
mistik_cakar@hotmail.com
4962790cdc3bf72f3562b3e0aa25a94acd579b58
f4a3647b534ece30d909d3295686feddefd40e99
/rsen/src/main/java/com/rsen/db/sqlite/WhereBuilder.java
929c626b9fe8a81fed7f8d085cda90eb29c84d2f
[]
no_license
bryant1410/RJcenter
c503ad25af48364c28c131f205f62b469fb7b4fc
dd09708f5826457d54ddd95cb55714321fdc64a1
refs/heads/master
2021-01-19T19:52:39.450107
2017-04-17T22:38:31
2017-04-17T22:38:31
88,458,756
1
0
null
2017-04-17T02:21:02
2017-04-17T02:21:02
null
UTF-8
Java
false
false
9,178
java
/* * Copyright (c) 2013. wyouflf (wyouflf@gmail.com) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ package com.rsen.db.sqlite; import android.text.TextUtils; import com.rsen.db.converter.ColumnConverterFactory; import com.rsen.db.table.ColumnUtils; import java.lang.reflect.Array; import java.util.ArrayList; import java.util.Iterator; import java.util.List; /** * Author: wyouflf * Date: 13-7-29 * Time: 上午9:35 */ public class WhereBuilder { private final List<String> whereItems; private WhereBuilder() { this.whereItems = new ArrayList<String>(); } /** * create new instance * * @return */ public static WhereBuilder b() { return new WhereBuilder(); } /** * create new instance * * @param columnName * @param op operator: "=","LIKE","IN","BETWEEN"... * @param value * @return */ public static WhereBuilder b(String columnName, String op, Object value) { WhereBuilder result = new WhereBuilder(); result.appendCondition(null, columnName, op, value); return result; } /** * add AND condition * * @param columnName * @param op operator: "=","LIKE","IN","BETWEEN"... * @param value * @return */ public WhereBuilder and(String columnName, String op, Object value) { appendCondition(whereItems.size() == 0 ? null : "AND", columnName, op, value); return this; } /** * add AND condition * * @param where expr("[AND] (" + where.toString() + ")") * @return */ public WhereBuilder and(WhereBuilder where) { String condition = whereItems.size() == 0 ? " " : "AND "; return expr(condition + "(" + where.toString() + ")"); } /** * add OR condition * * @param columnName * @param op operator: "=","LIKE","IN","BETWEEN"... * @param value * @return */ public WhereBuilder or(String columnName, String op, Object value) { appendCondition(whereItems.size() == 0 ? null : "OR", columnName, op, value); return this; } /** * add OR condition * * @param where expr("[OR] (" + where.toString() + ")") * @return */ public WhereBuilder or(WhereBuilder where) { String condition = whereItems.size() == 0 ? " " : "OR "; return expr(condition + "(" + where.toString() + ")"); } public WhereBuilder expr(String expr) { whereItems.add(" " + expr); return this; } public int getWhereItemSize() { return whereItems.size(); } @Override public String toString() { if (whereItems.size() == 0) { return ""; } StringBuilder sb = new StringBuilder(); for (String item : whereItems) { sb.append(item); } return sb.toString(); } private void appendCondition(String conj, String columnName, String op, Object value) { StringBuilder builder = new StringBuilder(); if (whereItems.size() > 0) { builder.append(" "); } // append conj if (!TextUtils.isEmpty(conj)) { builder.append(conj).append(" "); } // append columnName builder.append("\"").append(columnName).append("\""); // convert op if ("!=".equals(op)) { op = "<>"; } else if ("==".equals(op)) { op = "="; } // append op & value if (value == null) { if ("=".equals(op)) { builder.append(" IS NULL"); } else if ("<>".equals(op)) { builder.append(" IS NOT NULL"); } else { builder.append(" ").append(op).append(" NULL"); } } else { builder.append(" ").append(op).append(" "); if ("IN".equalsIgnoreCase(op)) { Iterable<?> items = null; if (value instanceof Iterable) { items = (Iterable<?>) value; } else if (value.getClass().isArray()) { int len = Array.getLength(value); List<Object> arrayList = new ArrayList<Object>(len); for (int i = 0; i < len; i++) { arrayList.add(Array.get(value, i)); } items = arrayList; } if (items != null) { StringBuilder inSb = new StringBuilder("("); for (Object item : items) { Object itemColValue = ColumnUtils.convert2DbValueIfNeeded(item); if (ColumnDbType.TEXT.equals(ColumnConverterFactory.getDbColumnType(itemColValue.getClass()))) { String valueStr = itemColValue.toString(); if (valueStr.indexOf('\'') != -1) { // convert single quotations valueStr = valueStr.replace("'", "''"); } inSb.append("'").append(valueStr).append("'"); } else { inSb.append(itemColValue); } inSb.append(","); } inSb.deleteCharAt(inSb.length() - 1); inSb.append(")"); builder.append(inSb.toString()); } else { throw new IllegalArgumentException("value must be an Array or an Iterable."); } } else if ("BETWEEN".equalsIgnoreCase(op)) { Iterable<?> items = null; if (value instanceof Iterable) { items = (Iterable<?>) value; } else if (value.getClass().isArray()) { int len = Array.getLength(value); List<Object> arrayList = new ArrayList<Object>(len); for (int i = 0; i < len; i++) { arrayList.add(Array.get(value, i)); } items = arrayList; } if (items != null) { Iterator<?> iterator = items.iterator(); if (!iterator.hasNext()) throw new IllegalArgumentException("value must have tow items."); Object start = iterator.next(); if (!iterator.hasNext()) throw new IllegalArgumentException("value must have tow items."); Object end = iterator.next(); Object startColValue = ColumnUtils.convert2DbValueIfNeeded(start); Object endColValue = ColumnUtils.convert2DbValueIfNeeded(end); if (ColumnDbType.TEXT.equals(ColumnConverterFactory.getDbColumnType(startColValue.getClass()))) { String startStr = startColValue.toString(); if (startStr.indexOf('\'') != -1) { // convert single quotations startStr = startStr.replace("'", "''"); } String endStr = endColValue.toString(); if (endStr.indexOf('\'') != -1) { // convert single quotations endStr = endStr.replace("'", "''"); } builder.append("'").append(startStr).append("'"); builder.append(" AND "); builder.append("'").append(endStr).append("'"); } else { builder.append(startColValue); builder.append(" AND "); builder.append(endColValue); } } else { throw new IllegalArgumentException("value must be an Array or an Iterable."); } } else { value = ColumnUtils.convert2DbValueIfNeeded(value); if (ColumnDbType.TEXT.equals(ColumnConverterFactory.getDbColumnType(value.getClass()))) { String valueStr = value.toString(); if (valueStr.indexOf('\'') != -1) { // convert single quotations valueStr = valueStr.replace("'", "''"); } builder.append("'").append(valueStr).append("'"); } else { builder.append(value); } } } whereItems.add(builder.toString()); } }
[ "angcyo@126.com" ]
angcyo@126.com
fefbbc860fc2fa603cf012aac23c2e77b7180288
3bb9e1a187cb72e2620a40aa208bf94e5cee46f5
/mobile_catalog/src/ong/eu/soon/mobile/client/model/CredentialType.java
947031b0377f22a825ca0463e76d26df1e50a0ad
[]
no_license
eusoon/Mobile-Catalog
2e6f766864ea25f659f87548559502358ac5466c
869d7588447117b751fcd1387cd84be0bd66ef26
refs/heads/master
2021-01-22T23:49:12.717052
2013-12-10T08:22:20
2013-12-10T08:22:20
null
0
0
null
null
null
null
UTF-8
Java
false
false
983
java
/* This file is part of Cyclos. Cyclos is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version. Cyclos is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with Cyclos; if not, write to the Free Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */ package ong.eu.soon.mobile.client.model; /** * Contains the possible credential types for accessing the rest services. * * @author luis */ public enum CredentialType { LOGIN_PASSWORD, TRANSACTION_PASSWORD, PIN, CARD_SECURITY_CODE }
[ "eusoon@gmail.com" ]
eusoon@gmail.com
56561c710ea8c37f4fab740acdf8a10f309a0e27
1e993b2d43036b7e15d1cc74507535d252c84e65
/src/test/java/com/el/sys/mapper/UdcMapperTest.java
f0612f014b099a8bce38b1f4c272eeb34c420e31
[]
no_license
juedaishusheng/stp-svr
9157624172607c5a060bcbef11d5d903f6ccf6d3
c1448c3c5b087d4742d81f2fe071d400164af3c5
refs/heads/master
2020-12-25T14:23:42.363886
2016-08-29T08:07:11
2016-08-29T08:07:11
66,818,112
0
0
null
null
null
null
UTF-8
Java
false
false
944
java
package com.el.sys.mapper; import com.el.sys.domain.UdcMetas; import com.el.test.TestRepositoryConfiguration; import org.junit.Test; import org.junit.runner.RunWith; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.test.context.ContextConfiguration; import org.springframework.test.context.junit4.SpringJUnit4ClassRunner; /** * Created on 16/7/29. * * @author panlw */ @RunWith(SpringJUnit4ClassRunner.class) @ContextConfiguration(classes = TestRepositoryConfiguration.class) public class UdcMapperTest { @Autowired private UdcMapper udcMapper; @Test public void codeNames() throws Exception { System.out.println("[APP-TEST] UDC of COUNTRY: " + udcMapper.codeNames(UdcMetas.COUNTRY).size()); } @Test public void codeName() throws Exception { System.out.println("[APP-TEST] UDC of COUNTRY/NL: " + udcMapper.codeName(UdcMetas.COUNTRY, "NL")); } }
[ "billy.zhang@elitesland.com" ]
billy.zhang@elitesland.com
3eb06657a38c694a109772302d0c7d4d8eb1902f
c205f07463d9e44584153f31970d18a1b99a7427
/Peluqueria/src/co/com/peluqueria/model/SessionHomePageDTO.java
84190ff05574d79742425cc23cb188f55592bb11
[]
no_license
lauramaru03/Peluqueria
7ba7334a260cf30f19e1461e96f9c685bfcb8fc4
3f4e6f1406f7ef9f422a7b88d9b3b84561a631fe
refs/heads/master
2020-12-24T18:54:38.205764
2016-05-19T12:25:17
2016-05-19T12:25:17
57,269,733
0
0
null
null
null
null
UTF-8
Java
false
false
1,552
java
package co.com.peluqueria.model; import java.io.Serializable; public class SessionHomePageDTO implements Serializable{ /** * */ private static final long serialVersionUID = 3617017567096298802L; public String imagePath; public String title; public String service1; public String service2; public String service3; public String descService1; public String descService2; public String descService3; public String getImagePath() { return imagePath; } public void setImagePath(String imagePath) { this.imagePath = imagePath; } public String getTitle() { return title; } public void setTitle(String title) { this.title = title; } public String getService1() { return service1; } public void setService1(String service1) { this.service1 = service1; } public String getService2() { return service2; } public void setService2(String service2) { this.service2 = service2; } public String getService3() { return service3; } public void setService3(String service3) { this.service3 = service3; } public String getDescService1() { return descService1; } public void setDescService1(String descService1) { this.descService1 = descService1; } public String getDescService2() { return descService2; } public void setDescService2(String descService2) { this.descService2 = descService2; } public String getDescService3() { return descService3; } public void setDescService3(String descService3) { this.descService3 = descService3; } }
[ "laura marulanda" ]
laura marulanda
51813166ce6a379aad759737d3b668a90317c7e1
ef04f3a682644c1970ed2caa89bc9d24669cad62
/DS Project/sst/execute/Fee.java
cff27fd77d20df20632fee3d6ea1301780096635
[]
no_license
LoganSathi/DreamCorporation
f5da6df895cd3d1e287ae241c80728b1f6e3925c
efa8f263daa5f19a732110540daafe912f048609
refs/heads/main
2023-07-23T18:28:04.461879
2021-09-07T18:23:34
2021-09-07T18:23:34
404,081,611
0
0
null
null
null
null
UTF-8
Java
false
false
2,137
java
package sst.execute; import sst.dao.CompanyAccess; import sst.exception.OperationHaltException; import sst.util.Methods; import java.util.Map; public class Fee implements Command { private CompanyAccess accessComp; public Fee(CompanyAccess companyDO) { this.accessComp = companyDO; } @Override public void execute() throws OperationHaltException { String action = chooseAction(); if (action.equals("1")) { Double currentRegistrationFee = accessComp.getCompany().getRegistrationFee(); System.out.println("Previous registration fee: " + currentRegistrationFee); System.out.println("Please enter new registration fee:"); Double newRegistrationFee = Double.parseDouble(Methods.askDouble()); accessComp.getCompany().setRegistrationFee(newRegistrationFee); System.out.println("Successfully updated registration fee."); } else if (action.equals("2")) { Map<Integer, Double> currentCommission = accessComp.getCompany().getCommission(); System.out.println("Previous commission: "); currentCommission.forEach((key, value) -> System.out.println(String.format("Generation %d: %f", key, value))); System.out.println("Please enter the generation for new commision set:"); int gen = Integer.parseInt(Methods.askNumber(1,5)); System.out.println("Enter new commission for generation " + gen + ":"); Double newCommission = Double.parseDouble(Methods.askDouble()); accessComp.getCompany().setCommission(gen, newCommission); System.out.println("Successfully updated commision fee."); } postExecute(); } private String chooseAction() { System.out.println("1. Change registration fee"); System.out.println("2. Change commission"); return Methods.askNumber(1, 2); } private void postExecute() { System.out.println("Press enter to continue.."); Methods.readLine(); } }
[ "noreply@github.com" ]
LoganSathi.noreply@github.com
02c1d9b1d6907b55c8b44936dc4380715db2b2a0
bc8fa9a21bcb1c60a48cc6372b6dbb4321b08c7e
/app/src/main/java/com/example/dell/main.java
3795a6f9355ab2d498420f74bc529943177685a7
[]
no_license
Utkarsh272/dell-trouble-coders
1877e5aa3af477e6916493eb2f792e592d5cacbd
142820d70993c6c1f51bc31a886aa335933f4728
refs/heads/master
2020-07-12T15:03:30.443516
2019-08-28T04:13:43
2019-08-28T04:13:43
204,846,204
0
0
null
null
null
null
UTF-8
Java
false
false
8,578
java
package com.example.dell; import androidx.appcompat.app.AppCompatActivity; import androidx.swiperefreshlayout.widget.SwipeRefreshLayout; import com.android.volley.Request; import com.android.volley.RequestQueue; import com.android.volley.Response; import com.android.volley.VolleyError; import com.android.volley.toolbox.JsonObjectRequest; import com.android.volley.toolbox.StringRequest; import com.android.volley.toolbox.Volley; import android.app.VoiceInteractor; import android.content.Intent; import android.os.Bundle; import android.util.Log; import android.view.View; import android.widget.AdapterView; import android.widget.Button; import android.widget.ListView; import android.widget.SimpleAdapter; import android.widget.TextView; import android.widget.Toast; import org.json.JSONObject; import java.util.ArrayList; import java.util.HashMap; import java.util.Map; public class main extends AppCompatActivity { static int res=0; static String str=""; static int totalcost=0; static int max=0; static int rem=0; String url=""; TextView t1; static ArrayList<String> al; ArrayList<result> rse; ArrayList<String> cos; Button bt,bt1; SwipeRefreshLayout sp; // static Intent inten; @Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.activity_main3); t1 = (TextView) findViewById(R.id.cost); bt = (Button) findViewById(R.id.bt); bt1 = (Button) findViewById(R.id.ref); // Instantiate the RequestQueue. al = new ArrayList<String>(); rse = new ArrayList<>(); cos = new ArrayList<>(); // if(input_variables.getComponents().equals("LAPTOP")){ // int x1=0,x2=0,x3=0,x4=0,x5=0,x6=0,x7=0; //// int rem=0; // x1=(int)(input_variables.getCost()*0.379); // x2=(int)(input_variables.getCost()*0.110); // x3=(int)(input_variables.getCost()*0.0664); // x4=(int)(input_variables.getCost()*0.166); // x5=(int)(input_variables.getCost()*0.029); // x6=(int)(input_variables.getCost()*0.020); // x7=(int)(input_variables.getCost()*0.227); //// for(int i=1;i<=7;i++){ // // url ="http://10.6.0.55:5000/"+x1+"/"; // url += 1; // res1(url); // //// x2+=rem; // String url1 ="http://10.6.0.55:5000/"+x2+"/"; // url1 += 2; // res1(url1); // //// x3+=rem; // url ="http://10.6.0.55:5000/"+x3+"/"; // url += 3; // res1(url); // //// x4+=rem; // url ="http://10.6.0.55:5000/"+x4+"/"; // url += 4; // res1(url); // //// x5+=rem; // url ="http://10.6.0.55:5000/"+x5+"/"; // url += 5; // res1(url); // //// x6+=rem; // url ="http://10.6.0.55:5000/"+x6+"/"; // url += 6; // res1(url); // x7+=rem; // url ="http://10.6.0.55:5000/"+input_variables.getCost()+"/"; // url += 7; // res1(url); // } // else{ url ="http://10.6.0.55:5000/"+input_variables.getCost()+"/"; url += res; res1(url); // } // Request a string response from the provided URL. /*RequestQueue rq = Volley.newRequestQueue(this);*/ /* String URL = "http://10.6.0.55:5000/4000/1"; JsonObjectRequest jor = new JsonObjectRequest( Request.Method.GET, URL, null, new Response.Listener<JSONObject>() { @Override public void onResponse(JSONObject response) { Log.e("Rest response",response.toString()); Toast.makeText(main.this, "Worked!!!", Toast.LENGTH_SHORT).show(); } }, new Response.ErrorListener() { @Override public void onErrorResponse(VolleyError error) { Log.e("Rest response",error.toString()); } } ); rq.add(jor);*/ // try{ // Thread.sleep(5000);} // catch(Exception e){ // // } this.simpleAdapterListView(); bt.setOnClickListener(new View.OnClickListener() { @Override public void onClick(View view) { Intent intent = new Intent(main.this,Payment.class); startActivity(intent); } }); bt1.setOnClickListener(new View.OnClickListener() { @Override public void onClick(View view) { Intent intent = new Intent(main.this,main.class); startActivity(intent); } }); } public void res1(String url){ // str=""; RequestQueue queue = Volley.newRequestQueue(this); StringRequest stringRequest = new StringRequest(Request.Method.GET, url, new Response.Listener<String>() { @Override public void onResponse(String response) { // Display the first 500 characters of the response string. main.str = response.toString(); // Toast.makeText(main.this, str+" YAY", Toast.LENGTH_SHORT).show(); } }, new Response.ErrorListener() { @Override public void onErrorResponse(VolleyError error) { // Toast.makeText(getApplicationContext(), "Nay", Toast.LENGTH_SHORT).show(); } }); al.add(main.str+""); // String s1 = main.str+""; // Toast.makeText(this,s1.split(" ").length+" ",Toast.LENGTH_LONG).show(); // result rs = new result(); // String[] s1 = str.split(" "); //// for(int i=1;i<s1.length;i++){ //// String[] s2 = s1[1].split(" "); // rs.setComponents(s1[3]); // al.add(rs.getComponents()); //// } //// s2 = s1[2].split(" "); // rs.setPriority1(s1[5]); //// s2 = s1[3].split(" "); // rs.setCost(Integer.parseInt(s1[7])); //// s2 = s1[4].split(" "); // rs.setSpr(Integer.parseInt(s1[11])); //// s2 = s1[5].split(" "); // rs.setCpr(Integer.parseInt(s1[15])); // rse.add(rs); // cos.add(Integer.toString(rs.getCost())); // Add the request to the RequestQueue. queue.add(stringRequest); } private void simpleAdapterListView() { // setTitle("dev2qa.com - SimpleAdapter List View Example"); // String[] titleArr = { "LAPTOP","MONITOR", "HDD", "CPU", "RAM","KEYBOARD","MOUSE","GRAPHICS CARD"}; // String[] descArr = { "Jerry", "Male", "43", "Singapore", "webmaster@dev2qa.com" }; ArrayList<Map<String,String>> itemDataList = new ArrayList<Map<String,String>>(); // int titleLen = al.size(); Toast.makeText(this,al.size()+" ",Toast.LENGTH_SHORT).show(); for(int i =0; i < al.size(); i++) { Map<String,String> listItemMap = new HashMap<String,String>(); listItemMap.put("title", al.get(i)+""); listItemMap.put("description", ""); itemDataList.add(listItemMap); } SimpleAdapter simpleAdapter = new SimpleAdapter(this,itemDataList,android.R.layout.simple_list_item_2, new String[]{"title","description"},new int[]{android.R.id.text1,android.R.id.text2}); ListView listView = (ListView)findViewById(R.id.listViewExample1); listView.setAdapter(simpleAdapter); listView.setOnItemClickListener(new AdapterView.OnItemClickListener() { @Override public void onItemClick(AdapterView<?> adapterView, View view, int index, long l) { Object clickItemObj = adapterView.getAdapter().getItem(index); // input_variables.setComponents(clickItemObj.toString().split("=")[2].substring(0,clickItemObj.toString().split("=")[2].length()-1)); // String str = input_variables.getComponents(); // Cart.rs=rse.get(index); // Toast.makeText(Component_Selection.this, "You clicked " + clickItemObj.toString().split("=")[2].substring(0,clickItemObj.toString().split("=")[2].length()-1), Toast.LENGTH_SHORT).show(); Intent intent = new Intent(main.this,Cart.class); startActivity(intent); } }); } }
[ "utkarshm272@gmail.com" ]
utkarshm272@gmail.com
cdcce8cb829c902e2a9627c99f75ac32d2c34714
a6e18a95b7b57c8f5af5bda83d9579cf8342a567
/ORDEV/src/net/tak/action/BaseAction.java
ef886835e642fd0234dcfbb7f4d7e715f649f163
[]
no_license
listakwong/githubRepository
cd9988934d5cfee5c5af522c3bd711240bb9191a
57c9ffadd961dc774bccbec8d6d3fb4a11d35e64
refs/heads/master
2020-05-22T13:07:38.957816
2014-01-24T02:00:04
2014-01-24T02:00:04
null
0
0
null
null
null
null
UTF-8
Java
false
false
5,621
java
package net.tak.action; import java.sql.Date; import java.sql.Timestamp; import java.util.HashMap; import java.util.Map; import net.tak.TConstant; import net.tak.bean.common.PageBean; import net.tak.service.ISystemService; import org.apache.commons.lang3.StringUtils; import org.apache.struts2.interceptor.RequestAware; import org.apache.struts2.interceptor.SessionAware; import com.list.or.Constant; import com.list.or.bean.admin.SysUser; import com.list.or.bean.common.LoginBean; import com.list.or.service.admin.ISysParameterService; import com.list.or.service.admin.ISysUserService; import com.list.or.service.maint.IMaintOctopusService; import com.opensymphony.xwork2.ActionSupport; public abstract class BaseAction extends ActionSupport implements SessionAware ,RequestAware{ private static final long serialVersionUID = -4995925857746196472L; protected ISystemService systemService; protected ISysUserService sysUserService; protected ISysParameterService sysParameterService; protected IMaintOctopusService maintOctopusService; public Map<String, Object> session; public Map<String, Object> request; protected String page; protected String tableTagCheckbox; private PageBean pagebean; public PageBean getPagebean() { return pagebean; } public void setPagebean(PageBean pagebean) { this.pagebean = pagebean; } public String getPage() { return page; } public void setPage(String page) { this.page = page; } public String getTableTagCheckbox() { return tableTagCheckbox; } public void setTableTagCheckbox(String tableTagCheckbox) { this.tableTagCheckbox = tableTagCheckbox; } public ISysParameterService getSysParameterService() { return sysParameterService; } public void setSysParameterService(ISysParameterService sysParameterService) { this.sysParameterService = sysParameterService; } public ISystemService getSystemService() { return systemService; } public void setSystemService(ISystemService systemService) { this.systemService = systemService; } public ISysUserService getSysUserService() { return sysUserService; } public void setSysUserService(ISysUserService sysUserService) { this.sysUserService = sysUserService; } public IMaintOctopusService getMaintOctopusService() { return maintOctopusService; } public void setMaintOctopusService(IMaintOctopusService maintOctopusService) { this.maintOctopusService = maintOctopusService; } @Override public String execute() throws Exception { return init(); } protected abstract Class<?> getFormClass(); protected abstract String init(); protected void putSessionUser(SysUser pSysUser) { LoginBean loginBean = new LoginBean(); loginBean.setUser_id(pSysUser.getUser_id()); loginBean.setUser_name(pSysUser.getUser_name()); loginBean.setPassword(pSysUser.getPassword()); loginBean.setLast_login_date(pSysUser.getLast_upd_date()); session.remove(TConstant.SESSION_USER_KEY); session.put(TConstant.SESSION_USER_KEY, loginBean); } protected Timestamp retrieveCurrentTime(){ return systemService.retrieveSysTimestamp(); } protected Date retrieveCurrentDate(){ return systemService.retrieveSysdate(); } protected void putSessionMenu(LoginBean loginBean) { session.remove(TConstant.SESSION_MENU_KEY); session.put(TConstant.SESSION_MENU_KEY, systemService.retrieveSysMenu(loginBean)); } protected void putSessionBean(Object object) { session.remove(TConstant.SESSION_BEAN_KEY); session.put(TConstant.SESSION_BEAN_KEY, object); } protected void putRequsetBean(Object object) { request.remove(TConstant.REQUEST_BEAN_KEY); request.put(TConstant.REQUEST_BEAN_KEY, object); } @Override public void setSession(Map<String, Object> session) { this.session = session; } protected void removeSession() { session.remove(TConstant.SESSION_USER_KEY); session.remove(TConstant.SESSION_MENU_KEY); session.remove(TConstant.SESSION_BEAN_KEY); } @Override public void setRequest(Map<String, Object> request) { this.request = request; } public Integer getCurrentPage() { Integer current_page = 1; if(StringUtils.isNotEmpty(page)) { String[] pages = page.split(","); if(StringUtils.isNotEmpty(pages[0].trim())) { current_page = Integer.valueOf(pages[0].trim()); } } return current_page; } public void setPagingBean(Map<String, Map<String, Object>> parameters, Map<String,String> ordering) { if(pagebean == null) pagebean = new PageBean(); if(parameters != null){ if(parameters.size() > 0) { pagebean.setParameters(parameters); } } Map<String, String> orderings = new HashMap<String,String> (); if(StringUtils.isNotEmpty(pagebean.getSortBy())) { orderings.clear(); orderings.put(pagebean.getSortBy(), pagebean.getSort()); } else { if(ordering != null && ordering.size() > 0) { pagebean.setSort(Constant.EMPTY); pagebean.setSortBy(Constant.EMPTY); orderings.putAll(ordering); } } pagebean.setOrdering(orderings); pagebean.setSearch_ind(true); pagebean.setCurrent_page(getCurrentPage()); request.put(TConstant.REQUEST_PAGE_BEAN_KEY, pagebean); } public void setPagingBean2(Map<String, Map<String, Object>> parameters, Map<String,String> ordering,String pageBeanKey) { pagebean = new PageBean(); if(parameters != null){ if(parameters.size() > 0) { pagebean.setParameters(parameters); } } pagebean.setOrdering(ordering); pagebean.setSearch_ind(true); pagebean.setCurrent_page(getCurrentPage()); pagebean.setRecord_per_page(9999); request.put(pageBeanKey, pagebean); } }
[ "wtakwong@gmail.com" ]
wtakwong@gmail.com
70d7ab1d0e10ffabada4ece12345834cc61afa4b
202148d206dfb6c50ab21c3a7cf7cecb50dbb7f8
/Sample/src/com/myc/sample/threads/Util.java
fd4dfb124aec55ebf0de3e45d669e2742941eada
[]
no_license
sreekanthrayapalli/JavaPrograms
0990dd4942d663c024cf2006635e188b17148685
ef2b5ff7071792f6da8d07ede10c86062d33ac23
refs/heads/master
2021-01-20T18:16:23.714237
2020-09-30T01:51:32
2020-09-30T01:51:32
61,763,348
0
0
null
null
null
null
UTF-8
Java
false
false
606
java
package com.myc.sample.threads; public class Util { private boolean flag = true; private int val; public synchronized void set(int i){ if(!flag){ try { wait(); } catch (InterruptedException e) { // TODO Auto-generated catch block e.printStackTrace(); } } this.val = i; flag = false; notify(); } public synchronized int get(){ if(flag){ try { wait(); } catch (InterruptedException e) { // TODO Auto-generated catch block e.printStackTrace(); } } flag = true; notify(); return val; } }
[ "sreekanth.rayapalli@gmail.com" ]
sreekanth.rayapalli@gmail.com
4439c2e226be90811eff56a1e1a38ce4b5d615d8
96b6271381c6cef5308aab6f5311492c672fa733
/src/de/hdm/itprojektss18/team01/sontact/shared/report/SimpleParagraph.java
64fec14fe6a54fa75507d54e54a820ea984e19d7
[]
no_license
MieschaGotthilfAfshar/ItpSS18Gruppe01
d508991f6b27a7bf40f0c49b3c7a87dd5340cb43
eb20bb7804e761bcfd9891524d640dbba84d3404
refs/heads/master
2020-04-16T11:20:08.818480
2018-07-07T19:22:44
2018-07-07T19:22:44
null
0
0
null
null
null
null
UTF-8
Java
false
false
2,112
java
package de.hdm.itprojektss18.team01.sontact.shared.report; import java.io.Serializable; /** * Diese Klasse stellt einzelne Absaetze dar. Der Absatzinhalt wird als String * gespeichert. Der Anwender sollte in diesem Strinig keinerlei * Formatierungssymbole einfuegen, da diese in der Regel zielformatspezifisch * sind. * * @author Thies */ public class SimpleParagraph extends Paragraph implements Serializable { private static final long serialVersionUID = 1L; /** * Inhalt des Absatzes. */ private String text = ""; /** * <p> * Serialisierbare Klassen, die mittels GWT-RPC transportiert werden sollen, * muessen einen No-Argument-Konstruktor besitzen. Ist kein Konstruktor explizit * angegeben, so existiert ini Java-Klassen implizit der Default-Konstruktor, * der dem No-Argument-Konstruktor entspricht. * </p> * <p> * Besitzt eine Klasse mind. einen explizit implementierten Konstruktor, so * gelten nur diese explizit implementierten Konstruktoren. Der * Default-Konstruktor gilt dann nicht. Wenn wir in einer solchen Situation aber * dennoch einen No-Argument-Konstruktor benoetigen, muessen wir diesen wie in * diesem Beispiel explizit implementieren. * </p> * * @see #SimpleParagraph(String) */ public SimpleParagraph() { } /** * Dieser Konstruktor ermoelicht es, bereits bei Instantiierung von * <code>SimpleParagraph</code>-Objekten deren Inhalt angeben zu koennen. * * @param value * der Inhalt des Absatzes * @see #SimpleParagraph() */ public SimpleParagraph(String value) { this.text = value; } /** * Auslesen des Inhalts. * * @return Inhalt als String */ public String getText() { return this.text; } /** * Ueberschreiben des Inhalts. * * @param text * der neue Inhalt des Absatzes. */ public void setText(String text) { this.text = text; } /** * Umwandeln des <code>SimpleParagraph</code>-Objekts in einen String. */ @Override public String toString() { return this.text; } }
[ "mg153@hdm-stuttgart.de" ]
mg153@hdm-stuttgart.de
073c9633705e44ea998a12bccc8cda268c883fa6
57d5a05e01b3112b9d3a560434ad24aa85290192
/src/main/java/org/dice/solrenhancements/queryparsers/VectorQParser.java
babec6f3e9f41887e3faeafc94734bd9db1d2ea6
[ "Apache-2.0" ]
permissive
obinna240/SolrPlugins
2595319d7ed536f773e8df73b6db2ce7c95c8167
e363c6b57b40f99d9ad92824a9c9ace80872b5ac
refs/heads/master
2021-05-26T05:50:52.707273
2018-04-02T10:31:30
2018-04-02T10:31:30
127,740,743
0
0
Apache-2.0
2021-05-12T00:18:21
2018-04-02T10:21:53
Java
UTF-8
Java
false
false
1,082
java
package org.dice.solrenhancements.queryparsers; import org.apache.lucene.search.Query; import org.apache.solr.common.params.SolrParams; import org.apache.solr.request.SolrQueryRequest; import org.apache.solr.search.ExtendedDismaxQParser; /** * Created by simon.hughes on 3/29/14. */ public class VectorQParser extends PayloadAwareExtendDismaxQParser { public VectorQParser( java.lang.String qstr, SolrParams localParams, SolrParams params, SolrQueryRequest req) { super(preProcessQuery(qstr,localParams, params, req), localParams, params, req); } private static String preProcessQuery(String qstr, SolrParams localParams, SolrParams params, SolrQueryRequest req){ // prevent white space tokenization ExtendedDismaxQParser qParser = new ExtendedDismaxQParser(qstr.replace(" ",","), localParams, params, req); try{ Query query = qParser.parse(); return query.toString(); } catch (Exception ex){ return "ERROR"; } } }
[ "obinna240@yahoo.co.uk" ]
obinna240@yahoo.co.uk
11e8da73729a00c03083c1cff2fc1b9ad8e0ded3
59c58c6c4f74c58903f9a03271de349cfb94cc12
/java-base-study/src/main/java/org.person.dfw/program/primitive/TestInteger.java
14ff0877603ea3e85f25cd050a267f0ab8f046fc
[]
no_license
dxy9/TestJava
7b51373abc30fd9b79e321080cef706a124229d3
0bb1a15806afc24780c1dd716b192801f67d45c5
refs/heads/master
2020-05-22T13:14:57.971927
2019-05-16T01:48:55
2019-05-16T01:48:55
186,355,203
0
0
null
2019-05-16T01:48:56
2019-05-13T06:03:26
Java
UTF-8
Java
false
false
681
java
package org.person.dfw.program.primitive; import org.junit.Test; public class TestInteger { @Test public void test(){ Integer i = new Integer(10); i = 5; i = Integer.valueOf(5); } @Test public void toBinaryString(){ int i = 1111111170; System.out.println("Number = " + i); /* returns the string representation of the unsigned integer value represented by the argument in binary (base 2) */ System.out.println("Binary is " + Integer.toBinaryString(i)); // returns the number of one-bits System.out.println("Number of one bits = " + Integer.bitCount(i)); } }
[ "1375049265@qq.com" ]
1375049265@qq.com
33e76bb829a19b55b9cf645357273ccbd3ffb394
d61cbe04b46e3480d5f2acf356f8ccdbab28dbc7
/Patrones de diseño de software y Principios SOLID/17_Mediator/test/org/formacion/mediator/TestSistema.java
ec034824649607f2ef32f70084bdcd455437d6d4
[]
no_license
decalion/Formaciones-Platzi-Udemy
d479548c50f3413eba5bad3d01bdd6a33ba75f60
3180d5062d847cc466d4a614863a731189137e50
refs/heads/master
2022-11-30T18:59:39.796599
2021-06-08T20:11:18
2021-06-08T20:11:18
200,000,005
1
2
null
2022-11-24T09:11:48
2019-08-01T07:27:00
Java
UTF-8
Java
false
false
1,102
java
package org.formacion.mediator; import static org.junit.Assert.*; import org.junit.Before; import org.junit.Test; public class TestSistema { private Radio radio; private Telefono telefono; private Coche coche; @Before public void init() { radio = new Radio(); telefono = new Telefono(); coche = new Coche(); new Coordinador(telefono, coche, radio); } @Test public void test_encender_apagar_coche() { assertFalse(radio.encendida()); assertFalse(telefono.musicaEncendida()); telefono.enciendeMusica(); assertTrue(telefono.musicaEncendida()); coche.enciende(); assertTrue(radio.encendida()); assertFalse(telefono.musicaEncendida()); coche.apaga(); assertFalse(radio.encendida()); } @Test public void test_suena_telefono() { radio.enciende(); assertTrue(radio.encendida()); telefono.recibeLlamada(); assertFalse(radio.encendida()); } @Test public void test_enciende_radio() { telefono.enciendeMusica(); assertTrue(telefono.musicaEncendida()); radio.enciende(); assertFalse(telefono.musicaEncendida()); } }
[ "icaballerohernandez@gmail.com" ]
icaballerohernandez@gmail.com
8b8aaccbff35b8ca51dd4b3e9de30eab088c1e4e
21beab6128d869c6f7bcb573b88fb9b772c97781
/app/src/main/java/de/ricoklimpel/newslink/NewsSource.java
77c8d9d7139e43bc15970b6d99cdb51f1fdf4935
[]
no_license
rklimpel/NewsLink
5c6efdd339d8fd2866397dcc51a41bf9c12944a3
17cf7095a2063e86b4d2ce42e4218cbb26514592
refs/heads/master
2021-09-22T11:00:14.147876
2018-09-08T21:44:32
2018-09-08T21:44:32
71,499,328
0
0
null
2017-01-31T14:55:11
2016-10-20T19:57:38
Java
UTF-8
Java
false
false
2,397
java
package de.ricoklimpel.newslink; /** * Created by ricoklimpel on 03.12.16. * * NewsSource Object, created for saving one news sources data into this class * */ public class NewsSource { String sourceID; String sourceName; String description; String url; String category; String language; String country; String[] urlLogo; Boolean[] sortAvailable; public NewsSource(String sourceID){ new NewsSource(sourceID,null,null,null,null,null,null,null); } public NewsSource(String sourceID, String sourceName, String description, String url, String category, String language, String country, String[] urlLogo){ this.sourceID = sourceID; this.sourceName = sourceName; this.description = description; this.url = url; this.category = category; this.language = language; this.country = country; this.urlLogo = urlLogo; } public String getSourceID() { return sourceID; } public String getSourceName() { return sourceName; } public String getDescription() { return description; } public String getUrl() { return url; } public String getCategory() { return category; } public String getLanguage() { return language; } public String getCountry() { return country; } public String[] getUrlLogo() { return urlLogo; } public Boolean[] getSortAvailable() { return sortAvailable; } public void setSourceID(String sourceID) { this.sourceID = sourceID; } public void setSourceName(String sourceName) { this.sourceName = sourceName; } public void setDescription(String description) { this.description = description; } public void setUrl(String url) { this.url = url; } public void setCategory(String category) { this.category = category; } public void setLanguage(String language) { this.language = language; } public void setCountry(String country) { this.country = country; } public void setUrlLogo(String[] urlLogo) { this.urlLogo = urlLogo; } public void setSortAvailable(Boolean[] sortAvailable) { this.sortAvailable = sortAvailable; } }
[ "rico@tklimpel.de" ]
rico@tklimpel.de
e2d4a1a9bbd8aa833bf92ba01f3683d4e96aa778
7ca77d9aa67e0c52dbdd41c0527d9a9de95303ea
/src/com/genustin/easy/P58.java
97429042975529fe336c3eeb486d3b576efe7b1f
[]
no_license
genustin/LeetCode
3b575f4814f4e42c027c96438270557bca4993e8
fd305210b65e3d4f18186c2683853f6c0f9fb7fc
refs/heads/master
2020-05-21T22:09:23.236653
2018-09-09T01:36:47
2018-09-09T01:36:47
26,398,769
0
0
null
null
null
null
UTF-8
Java
false
false
633
java
package com.genustin.easy; /** * Created by Genustin on 12/7/14. * Given a string s consists of upper/lower-case alphabets * and empty space characters ' ', * return the length of last word in the string. * <p/> * case 1: s="", return 0; * case 2: s="a b", return 1; * case 3: s="a ", return 1; * case 4: s =" ", return 0; */ public class P58 { public int lengthOfLastWord(String s) { if (s.isEmpty()) return 0; int k = s.lastIndexOf(' '); if (k != s.length() - 1) return s.length() - 1 - k; else return lengthOfLastWord(s.substring(0, s.length() - 1)); } }
[ "wqhuang@me.com" ]
wqhuang@me.com
72279d77a8a1a4e2fd8ca287d92660b5b6f99902
22657f710a9a27707eb09c1318fd6bbeeb2267b3
/src/main/java/com/trivago/triava/tcache/util/ChangeStatus.java
3a90a677ab37d33cbf8dacc3fed04aea040a93cd
[ "Apache-2.0" ]
permissive
harsha549/triava
f68fed5e1a9156030acb36e563ada1d693204ec0
049484fa865691a7e27db4de7a57aed98c0654d9
refs/heads/master
2023-01-01T19:26:26.746692
2018-11-26T10:51:23
2018-11-26T10:51:23
null
0
0
null
null
null
null
UTF-8
Java
false
false
885
java
/********************************************************************************* * Copyright 2015-present trivago GmbH * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. **********************************************************************************/ package com.trivago.triava.tcache.util; public enum ChangeStatus { CREATED, CHANGED, UNCHANGED, CAS_FAILED_EQUALS }
[ "Christian.Esken@trivago.com" ]
Christian.Esken@trivago.com
1873f2c066e645c44b6538efc3ea47a5445cdf97
486bf2978501b46c47653a5083e343d6e09469ba
/hello-byte-buddy/src/main/java/cn/chenhenry/hello/bytebuddy/method/delegation/MethodDelegationDemo.java
4446097d6eab069473bc95cacfb71797919657a9
[ "MIT" ]
permissive
HenryChenV/hello-java
5b6f0b56e55dee262f7a22171981093a2f02f332
d71bce1cd5ff717a01eb2e95e38028c195434a4c
refs/heads/master
2023-01-11T23:12:23.622700
2022-12-25T03:58:05
2022-12-25T03:58:05
157,085,535
0
0
MIT
2022-12-25T03:59:02
2018-11-11T14:06:19
Java
UTF-8
Java
false
false
1,254
java
package cn.chenhenry.hello.bytebuddy.method.delegation; import net.bytebuddy.ByteBuddy; import net.bytebuddy.matcher.ElementMatchers; import java.util.function.Function; /** * @author chenhanli * @date 2022/3/19 11:50 下午 */ public class MethodDelegationDemo { public static class GreetingInterceptor { public String greet(Object argument) { // 会匹配到这个, 因为不指定泛型类型的Function等于Function<Object, Object> // 匹配是貌似只看了入参, 没关心返回值 return "Greet from " + argument; } public String hello(String name) { return "Hello from " + name; } } public static void main(String[] args) throws InstantiationException, IllegalAccessException { Class<? extends Function> dynamicType = new ByteBuddy() .subclass(Function.class) .method(ElementMatchers.named("apply")) .intercept(net.bytebuddy.implementation.MethodDelegation.to(new GreetingInterceptor())) .make() .load(MethodDelegationDemo.class.getClassLoader()) .getLoaded(); System.out.println(dynamicType.newInstance().apply("CHL")); } }
[ "chenhanli@bigo.sg" ]
chenhanli@bigo.sg
21f09dfc8f1d17efda94d4f55a9507f4cfb4904a
b770df1acd1fad2530e05fdc88df15b103ca4676
/blog-infrastructure/src/main/java/com/ripple/blog/infrastructure/dao/CountDao.java
6d5df5d6950d1b4699d42bf785499bb00c2a548e
[]
no_license
wlstone119/ripple-blog
f637635892cf6dffbd414b12e12e35b8eaa72aa0
8d301cb0eeadd03760b2518d2ed1aeaefef6e204
refs/heads/master
2022-09-16T06:54:54.443276
2020-01-21T05:54:42
2020-01-21T05:54:42
234,287,323
0
0
null
2022-09-01T23:19:09
2020-01-16T09:48:54
Java
UTF-8
Java
false
false
462
java
package com.ripple.blog.infrastructure.dao; import java.util.List; import java.util.Map; import java.util.Set; import com.ripple.blog.infrastructure.dao.entity.CountEntity; public interface CountDao { CountEntity create(CountEntity entity); CountEntity findCountById(String id); Map<String, Long> findCountByIds(Set<String> ids); CountEntity createOrUpdate(CountEntity entity); CountEntity inc(CountEntity entity); List<CountEntity> findHot(); }
[ "wanglei11074@hellobike.com" ]
wanglei11074@hellobike.com
bad3a6559eacb351af5363f05b270325bf501ddf
2416daf36f1b72ae46d9470a40514d90e8802a15
/GameConfig.java
83da4711c5972d42d4d11bab48731e7562a361d8
[]
no_license
Danny-Rosenberg/OrganismsGame
673556602738138fb22bcdd5b1ef4af070b5ebba
d9c9a3b23e3bca84823406a6f1f2e0e7f4fa9375
refs/heads/master
2021-03-16T09:48:32.732971
2017-02-10T15:37:19
2017-02-10T15:37:19
81,252,220
0
0
null
null
null
null
UTF-8
Java
false
false
622
java
/** * This is the game configuration that is publicly known. * @author swapneel * */ public interface GameConfig { /** * The energy consumed in staying put * @return should always return 1 (other parameters scale) */ public int s(); /** * The energy consumed in moving or reproducing * @return the value of v */ public int v(); /** * The energy per unit of food * @return the value of u */ public int u(); /** * The maximum energy per organisms * @return the value of M */ public int M(); /** * The maximum food units per cell * @return the value of K */ public int K(); }
[ "marilynrosenberg@vagvlan536.293.wlan.library.upenn.edu" ]
marilynrosenberg@vagvlan536.293.wlan.library.upenn.edu
969e670f62118966ff2749208d32ed08dcdd621e
f66b42c4eb937378069a817c78b39498c8726996
/app/src/main/java/com/zhizun/zhizunwifi/utils/JmTools.java
1fd34bb993d75e3542204eae0bb49aa9c9e9b3fc
[]
no_license
yipeng0428/zhizunWiFi
35a9cc60ac10f0aac44e6cf8a952455b94aa0329
85bcd9831e03195b2c5bdacee53adeaa5dc3999e
refs/heads/master
2021-04-28T02:03:38.727202
2017-06-20T08:14:00
2017-06-20T08:14:00
null
0
0
null
null
null
null
UTF-8
Java
false
false
5,849
java
package com.zhizun.zhizunwifi.utils; import android.content.Context; import org.json.JSONException; import org.json.JSONObject; import java.util.ArrayList; import java.util.HashMap; import java.util.Iterator; import java.util.List; import java.util.Map; /** * Created by wbb on 2016/4/6. */ public class JmTools { public final static String DKAETYA = "@#-*¥cxmx^&+#@*"; /** * 输入加密 T * @param str * @return */ public static String DKAETYA16(String str){ String a=str.substring(0, 16); return a; } /** * json 解密 * @param object * @return */ public static String DecryptKey(JSONObject object){ String result = object.optString("result"); String t = object.optString("T"); String keyString= Security.md5(t + DKAETYA); String key=DKAETYA16(keyString); //解密 String data= Security.decrypt(key, result); return data; } /** * 字符串 解密 * @param object * @return */ public static String DecryptString(String object,String T){ String keyString= Security.md5(T + DKAETYA); String key=DKAETYA16(keyString); //解密 String data= Security.decrypt(key, object); return data; } /** * 字符串 加密 * @param time * @param mString * @return */ public static String encryptionEnhanced(String time,String mString){ String key= Security.md5(time+DKAETYA); String key16=DKAETYA16(key); String date= Security.encrypt(key16,mString); return date; } /** * 加密 url signkey * * @param hashMap * @return */ public static String NRJM(Map<String, String> hashMap) { List<String> listKey = new ArrayList(); Iterator it = hashMap.keySet().iterator(); while (it.hasNext()) { String key = it.next().toString(); listKey.add(key); } List<String> listSort = Sorting.listSort(listKey); String key = ""; StringBuilder sb = new StringBuilder(); for (String string : listSort) { String name = hashMap.get(string); key = sb.append(name).toString(); } return Security.md5(key + "hfqhjy1sbm8icc23"); } /** * 用户加密 * * @param hashMap * @param methond * @return */ // public static String USER_NRJM(HashMap<String, String> hashMap, String methond) { // hashMap.put("service", methond); // List<String> listKey = new ArrayList(); // Iterator it = hashMap.keySet().iterator(); // while (it.hasNext()) { // String key = it.next().toString(); // listKey.add(key); // } // List<String> listSort = Sorting.listSort(listKey); // String key = ""; // StringBuilder sb = new StringBuilder(); // for (String string : listSort) { // String name = hashMap.get(string); // key = sb.append(name).toString(); // } // return Security.md5(key + ConnectionConstants.DJCCUSERKEY); // } /** * 短信验证码加密方法 * * @return */ public static HashMap<String, String> JM(Context context,String phone) throws JSONException { HashMap<String,String> hashMap = new HashMap<>(); hashMap.put("name", phone);//账号:手机号码/邮箱 hashMap.put("service", "User.SendMark"); hashMap.put("api", "3");//接口的版本号 hashMap.put("condition","0"); hashMap.put("c_appid","12");//客户端应用平台标识ID hashMap.put("c_os","1");//客户端操作系统:1是安卓,2是IOS,3是WAP,4是PC,5是其它 hashMap.put("c_version",DeviceUtil.getVersionName(context));//客户端应用版本号 String s = JmTools.NRJM(hashMap); hashMap.put("s", s); Iterator iter = hashMap.keySet().iterator(); JSONObject jsonObject = new JSONObject(); while (iter.hasNext()) { String key = (String) iter.next(); jsonObject.put(key, hashMap.get(key)); } long time = System.currentTimeMillis() / 1000; HashMap<String, String> hashMap1 = new HashMap<>(); hashMap1.put("data", JmTools.encryptionEnhanced(time + "", jsonObject.toString())); hashMap1.put("T", time + ""); return hashMap1; } /** * 短信验证码加密方法 * * @return */ public static HashMap<String, String> JM_check(Context context,String phone,String mark) throws JSONException { HashMap<String,String> hashMap = new HashMap<>(); hashMap.put("name", phone);//账号:手机号码/邮箱 hashMap.put("mark", mark);//账号:手机号码/邮箱 hashMap.put("service", "User.CheckMark"); hashMap.put("api", "3");//接口的版本号 hashMap.put("c_appid","12");//客户端应用平台标识ID hashMap.put("c_os","1");//客户端操作系统:1是安卓,2是IOS,3是WAP,4是PC,5是其它 hashMap.put("c_version",DeviceUtil.getVersionName(context));//客户端应用版本号 String s = JmTools.NRJM(hashMap); hashMap.put("s", s); Iterator iter = hashMap.keySet().iterator(); JSONObject jsonObject = new JSONObject(); while (iter.hasNext()) { String key = (String) iter.next(); jsonObject.put(key, hashMap.get(key)); } long time = System.currentTimeMillis() / 1000; HashMap<String, String> hashMap1 = new HashMap<>(); hashMap1.put("data", JmTools.encryptionEnhanced(time + "", jsonObject.toString())); hashMap1.put("T", time + ""); return hashMap1; } }
[ "1599211820@qq.com" ]
1599211820@qq.com
5944452f5525edee14c8ef07a6c1b0e1803cf80c
2ff875fac7f338bbb0f42a237239c6f12e32c4a1
/src/com/course/dao/ProblemDao.java
aaafcfc4327182a508ce93d19a4ffce5f94394be
[ "MIT" ]
permissive
wangfin/OnlineLearningPlatform
b6b9fb2b018b26ff9398aeeafdd93e05b88326ce
2640f320c05f7bc629ef495746dc8caf6266cb89
refs/heads/master
2021-08-27T21:39:01.091057
2021-08-19T08:04:08
2021-08-19T08:05:55
181,508,756
0
0
MIT
2019-04-15T14:53:01
2019-04-15T14:53:01
null
GB18030
Java
false
false
5,964
java
package com.course.dao; import java.util.ArrayList; import java.util.List; import org.hibernate.Criteria; import org.hibernate.Query; import org.hibernate.Session; import org.hibernate.criterion.Order; import org.hibernate.criterion.Restrictions; import com.learning.dao.HibernateSessionFactory; import com.learning.entity.Comment; import com.learning.entity.Course; import com.learning.entity.Page; import com.learning.entity.Problems; public class ProblemDao { public static List showallProblembycourseid(Page page,int courseid){ Session session = HibernateSessionFactory.getSession(); List<Problems> list ; try { session.beginTransaction(); Criteria criteria = session.createCriteria(Problems.class).add(Restrictions.eq("fromid", courseid)); int pagenow = page.getPagenow(); int pagesize = page.getPagesize(); int firstIndex = (pagenow-1)*pagesize; criteria.addOrder(Order.desc("submit_time")); criteria.setFirstResult(firstIndex); criteria.setMaxResults(pagesize); list = (List<Problems>) criteria.list(); session.getTransaction().commit(); return list; } catch (Exception e) { session.getTransaction().rollback(); e.printStackTrace(); return null; } finally { session.close(); } } public static void attachproblemtoCourse(Problems problem){ Session session = HibernateSessionFactory.getSession(); try { session.beginTransaction(); session.save(problem); session.getTransaction().commit(); } catch (Exception e) { session.getTransaction().rollback(); e.printStackTrace(); } finally { session.close(); } } //获得最新的几个问题 public static List getsomeproblemsbypage(){ Session session = HibernateSessionFactory.getSession(); List<Problems> list ; try { session.beginTransaction(); Query q=session.createQuery("from Problems order by id desc"); list = q.setFirstResult(0).setMaxResults(10).list(); list = q.list(); session.getTransaction().commit(); return list; } catch (Exception e) { session.getTransaction().rollback(); e.printStackTrace(); return null; } finally { session.close(); } } //根据所有问题分页 public static List page(Page page) { Session session = HibernateSessionFactory.getSession(); try { List list=new ArrayList<Problems>(); session.beginTransaction(); int pagenow = page.getPagenow(); int pagesize = page.getPagesize(); // System.out.println("总记录数是"+allcount); String hql2 = " from Problems p order by p.submit_time desc"; Query q = session.createQuery(hql2); int firstIndex = (pagenow-1)*pagesize; list = q.setFirstResult(firstIndex).setMaxResults(pagesize).list(); //取出8条 session.getTransaction().commit(); return list; }catch (Exception e) { session.getTransaction().rollback(); e.printStackTrace(); }finally{ session.close(); } return null; } public static List getProblemsByname(String keywords){ Session session = HibernateSessionFactory.getSession(); try{ session.beginTransaction(); List list=new ArrayList<Problems>(); String hql="from Problems as p where p.title like :name or p.content like :con"; Query query = session.createQuery(hql); query.setString("name", "%" + keywords + "%"); query.setString("con", "%" + keywords + "%"); list = query.list(); session.getTransaction().commit(); // Iterator it = list.iterator(); // while(it.hasNext()) { // System.out.println(it.next()); // } // System.out.println(list); return list; }catch (Exception e) { session.getTransaction().rollback(); e.printStackTrace(); } finally { session.close(); } return null; } public static void addviewnum(int problemid){ Session session = HibernateSessionFactory.getSession(); try{ session.beginTransaction(); Query q = session.createQuery("update Problems p set p.viewnum = p.viewnum+1 where p.id = ?"); q.setInteger(0, problemid); q.executeUpdate(); session.getTransaction().commit(); }catch(Exception e){ session.getTransaction().rollback(); e.printStackTrace(); }finally{ session.close(); } } public static Problems getProByid(int problemid){ Session session = HibernateSessionFactory.getSession(); try{ session.beginTransaction(); Problems pro=(Problems)session.get(Problems.class, problemid); return pro; }catch(Exception e){ session.getTransaction().rollback(); e.printStackTrace(); }finally{ session.close(); } return null; } public static int getCommcount(int problemid){ Session session = HibernateSessionFactory.getSession(); try{ session.beginTransaction(); String hql= "select count(*) from Comment c where c.problemid = ?"; Query q = session.createQuery(hql); q.setInteger(0, problemid); int count = ((Long) q.iterate().next()).intValue(); //int count = (Integer) q.uniqueResult(); return count; }catch(Exception e){ session.getTransaction().rollback(); e.printStackTrace(); }finally{ session.close(); } return 0; } public static List getrelevantPro(int problemid){ Session session = HibernateSessionFactory.getSession(); try{ session.beginTransaction(); List list = new ArrayList<Problems>(); Problems pro = (Problems)session.get(Problems.class, problemid); String type = pro.getType(); String[] typelist = type.split(","); for(int i=0;i<typelist.length;i++){ String hql = "from Problems p where p.type like ?"; Query q = session.createQuery(hql); q.setString(0, "%"+typelist[i]+"%"); List somelist = q.list(); list.addAll(somelist); } return list; }catch(Exception e){ e.printStackTrace(); session.getTransaction().rollback(); }finally{ session.close(); } return null; } }
[ "1205022533@qq.com" ]
1205022533@qq.com
8a582a1fbe42c693b3966d18acd9309812065918
d381092dd5f26df756dc9d0a2474b253b9e97bfb
/impe3/impe3-core/src/main/java/com/isotrol/impe3/core/WebExceptions.java
2b5954d1b36d648db194673eb39a16a133c61e23
[]
no_license
isotrol-portal3/portal3
2d21cbe07a6f874fff65e85108dcfb0d56651aab
7bd4dede31efbaf659dd5aec72b193763bfc85fe
refs/heads/master
2016-09-15T13:32:35.878605
2016-03-07T09:50:45
2016-03-07T09:50:45
39,732,690
0
1
null
null
null
null
UTF-8
Java
false
false
1,926
java
/** * This file is part of Port@l * Port@l 3.0 - Portal Engine and Management System * Copyright (C) 2010 Isotrol, SA. http://www.isotrol.com * * Port@l is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation, either version 3 of the License, or * (at your option) any later version. * * Port@l is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with Port@l. If not, see <http://www.gnu.org/licenses/>. */ package com.isotrol.impe3.core; import com.isotrol.impe3.api.ActionNotFoundPortalException; import com.isotrol.impe3.api.NotFoundPortalException; /** * Web exceptions helper class. * @author Andres Rodriguez */ public final class WebExceptions { /** Not instantiable. */ private WebExceptions() { throw new AssertionError(); } public static NotFoundPortalException notFound(String message) { return new NotFoundPortalException(message); } public static ActionNotFoundPortalException actionNotFound(String message) { return new ActionNotFoundPortalException(message); } public static void found(boolean condition, String message) { if (!condition) { throw notFound(message); } } public static <T> T found(T object, String message) { found(object != null, message); return object; } public static void actionFound(boolean condition, String message) { if (!condition) { throw actionNotFound(message); } } public static <T> T actionFound(T object, String message) { actionFound(object != null, message); return object; } }
[ "isotrol-portal@portal.isotrol.com" ]
isotrol-portal@portal.isotrol.com
b3e0088d2f664f654241623f9b59c869f04ccbf1
3f8b6f060d30239a5ccf3ff456263d7c1f9a4f0f
/SAPJCoTest/src/CustomDestinationDataProvider.java
f4a5f987e0dd2d103485872dbaad8f32dba67135
[]
no_license
kacyan/incubator
5d67d00585aca3df07c3b6e5996c35b5360bf2cd
8a50848bb54731e904fb20fdd0d037ec316f7095
refs/heads/master
2020-04-06T23:11:06.882044
2014-05-19T04:46:48
2014-05-19T04:46:48
null
0
0
null
null
null
null
UTF-8
Java
false
false
6,878
java
import java.util.HashMap; import java.util.Properties; import com.sap.conn.jco.JCoDestination; import com.sap.conn.jco.JCoDestinationManager; import com.sap.conn.jco.JCoException; import com.sap.conn.jco.ext.DataProviderException; import com.sap.conn.jco.ext.DestinationDataEventListener; import com.sap.conn.jco.ext.DestinationDataProvider; /** * Each application using Java Connector 3 deals with destinations. A destination represents a logical address * of an ABAP system and thus separates the destination configuration from application logic. JCo retrieves * the destination parameters required at runtime from DestinationDataProvider and ServerDataProvider registered * in the runtime environment. If no provider is registered, JCo uses the default implementation that reads the * configuration from a properties file. It is expected that each environment provides a suitable * implementation that meets security and other requirements. Furthermore, only one DestinationDataProvider * and only one ServerDataProvider can be registered per process. The reason behind this design decision * is the following: the provider implementations are part of the environment infrastructure. * The implementation should not be application specific, and in particular must be separated from * application logic. * * This example demonstrates a simple implementation of the DestinationDataProvider interface and shows how * to register it. A real world implementation should save the configuration data in a secure way. */ public class CustomDestinationDataProvider { //The custom destination data provider implements DestinationDataProvider and //provides an implementation for at least getDestinationProperties(String). //Whenever possible the implementation should support events and notify the JCo runtime //if a destination is being created, changed, or deleted. Otherwise JCo runtime //will check regularly if a cached destination configuration is still valid which incurs //a performance penalty. static class MyDestinationDataProvider implements DestinationDataProvider { private DestinationDataEventListener eL; private HashMap<String, Properties> secureDBStorage = new HashMap<String, Properties>(); public Properties getDestinationProperties(String destinationName) { try { //read the destination from DB Properties p = secureDBStorage.get(destinationName); if(p!=null) { //check if all is correct, for example if(p.isEmpty()) throw new DataProviderException(DataProviderException.Reason.INVALID_CONFIGURATION, "destination configuration is incorrect", null); return p; } return null; } catch(RuntimeException re) { throw new DataProviderException(DataProviderException.Reason.INTERNAL_ERROR, re); } } //An implementation supporting events has to retain the eventListener instance provided //by the JCo runtime. This listener instance shall be used to notify the JCo runtime //about all changes in destination configurations. public void setDestinationDataEventListener(DestinationDataEventListener eventListener) { this.eL = eventListener; } public boolean supportsEvents() { return true; } //implementation that saves the properties in a very secure way void changeProperties(String destName, Properties properties) { synchronized(secureDBStorage) { if(properties==null) { if(secureDBStorage.remove(destName)!=null) eL.deleted(destName); } else { secureDBStorage.put(destName, properties); eL.updated(destName); // create or updated } } } } // end of MyDestinationDataProvider //business logic void executeCalls(String destName) { JCoDestination dest; try { dest = JCoDestinationManager.getDestination(destName); System.out.println( dest ); dest.ping(); System.out.println("Destination " + destName + " works"); } catch(JCoException e) { e.printStackTrace(); System.out.println("Execution on destination " + destName+ " failed"); } } static Properties getDestinationPropertiesFromUI() { //adapt parameters in order to configure a valid destination Properties connectProperties = new Properties(); connectProperties.setProperty(DestinationDataProvider.JCO_ASHOST, "172.16.98.214"); connectProperties.setProperty(DestinationDataProvider.JCO_SYSNR, "00"); connectProperties.setProperty(DestinationDataProvider.JCO_CLIENT, "902"); connectProperties.setProperty(DestinationDataProvider.JCO_USER, ""); connectProperties.setProperty(DestinationDataProvider.JCO_PASSWD, ""); connectProperties.setProperty(DestinationDataProvider.JCO_LANG, "ja"); connectProperties.setProperty(DestinationDataProvider.JCO_TRACE, "enable"); connectProperties.setProperty(DestinationDataProvider.JCO_AUTH_TYPE,""); return connectProperties; } public static void main(String[] args) { MyDestinationDataProvider myProvider = new MyDestinationDataProvider(); //register the provider with the JCo environment; //catch IllegalStateException if an instance is already registered try { com.sap.conn.jco.ext.Environment.registerDestinationDataProvider(myProvider); } catch(IllegalStateException providerAlreadyRegisteredException) { //somebody else registered its implementation, //stop the execution throw new Error(providerAlreadyRegisteredException); } String destName = "ABAP_AS"; CustomDestinationDataProvider test = new CustomDestinationDataProvider(); //set properties for the destination and ... myProvider.changeProperties(destName, getDestinationPropertiesFromUI()); //... work with it test.executeCalls(destName); //now remove the properties and ... myProvider.changeProperties(destName, null); //... and let the test fail test.executeCalls(destName); } }
[ "kac@ksi.co.jp" ]
kac@ksi.co.jp
2121258e249be451cc99242ddbdb969cde94c6b4
63a63fa68cf1cf41605852a6352e5124d5bf88df
/clients/google-api-services-healthcare/v1beta1/1.30.1/com/google/api/services/healthcare/v1beta1/CloudHealthcare.java
057da0b1be7a4eef32844cc18802315f700eeb13
[ "Apache-2.0" ]
permissive
pmakani/google-api-java-client-services
1cf011deaf157b5b41b2acc0f7cc22ded10629d9
138314514da5b0f58574d33b0ae71c412ce86539
refs/heads/master
2020-04-23T16:53:12.955036
2020-01-22T19:02:52
2020-01-22T19:02:52
171,313,393
0
1
Apache-2.0
2020-01-10T08:18:26
2019-02-18T16:00:09
Java
UTF-8
Java
false
false
729,897
java
/* * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except * in compliance with the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software distributed under the License * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express * or implied. See the License for the specific language governing permissions and limitations under * the License. */ /* * This code was generated by https://github.com/googleapis/google-api-java-client-services/ * Modify at your own risk. */ package com.google.api.services.healthcare.v1beta1; /** * Service definition for CloudHealthcare (v1beta1). * * <p> * Manage, store, and access healthcare data in Google Cloud Platform. * </p> * * <p> * For more information about this service, see the * <a href="https://cloud.google.com/healthcare" target="_blank">API Documentation</a> * </p> * * <p> * This service uses {@link CloudHealthcareRequestInitializer} to initialize global parameters via its * {@link Builder}. * </p> * * @since 1.3 * @author Google, Inc. */ @SuppressWarnings("javadoc") public class CloudHealthcare extends com.google.api.client.googleapis.services.json.AbstractGoogleJsonClient { // Note: Leave this static initializer at the top of the file. static { com.google.api.client.util.Preconditions.checkState( com.google.api.client.googleapis.GoogleUtils.MAJOR_VERSION == 1 && com.google.api.client.googleapis.GoogleUtils.MINOR_VERSION >= 15, "You are currently running with version %s of google-api-client. " + "You need at least version 1.15 of google-api-client to run version " + "1.30.3 of the Cloud Healthcare API library.", com.google.api.client.googleapis.GoogleUtils.VERSION); } /** * The default encoded root URL of the service. This is determined when the library is generated * and normally should not be changed. * * @since 1.7 */ public static final String DEFAULT_ROOT_URL = "https://healthcare.googleapis.com/"; /** * The default encoded service path of the service. This is determined when the library is * generated and normally should not be changed. * * @since 1.7 */ public static final String DEFAULT_SERVICE_PATH = ""; /** * The default encoded batch path of the service. This is determined when the library is * generated and normally should not be changed. * * @since 1.23 */ public static final String DEFAULT_BATCH_PATH = "batch"; /** * The default encoded base URL of the service. This is determined when the library is generated * and normally should not be changed. */ public static final String DEFAULT_BASE_URL = DEFAULT_ROOT_URL + DEFAULT_SERVICE_PATH; /** * Constructor. * * <p> * Use {@link Builder} if you need to specify any of the optional parameters. * </p> * * @param transport HTTP transport, which should normally be: * <ul> * <li>Google App Engine: * {@code com.google.api.client.extensions.appengine.http.UrlFetchTransport}</li> * <li>Android: {@code newCompatibleTransport} from * {@code com.google.api.client.extensions.android.http.AndroidHttp}</li> * <li>Java: {@link com.google.api.client.googleapis.javanet.GoogleNetHttpTransport#newTrustedTransport()} * </li> * </ul> * @param jsonFactory JSON factory, which may be: * <ul> * <li>Jackson: {@code com.google.api.client.json.jackson2.JacksonFactory}</li> * <li>Google GSON: {@code com.google.api.client.json.gson.GsonFactory}</li> * <li>Android Honeycomb or higher: * {@code com.google.api.client.extensions.android.json.AndroidJsonFactory}</li> * </ul> * @param httpRequestInitializer HTTP request initializer or {@code null} for none * @since 1.7 */ public CloudHealthcare(com.google.api.client.http.HttpTransport transport, com.google.api.client.json.JsonFactory jsonFactory, com.google.api.client.http.HttpRequestInitializer httpRequestInitializer) { this(new Builder(transport, jsonFactory, httpRequestInitializer)); } /** * @param builder builder */ CloudHealthcare(Builder builder) { super(builder); } @Override protected void initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest<?> httpClientRequest) throws java.io.IOException { super.initialize(httpClientRequest); } /** * An accessor for creating requests from the Projects collection. * * <p>The typical use is:</p> * <pre> * {@code CloudHealthcare healthcare = new CloudHealthcare(...);} * {@code CloudHealthcare.Projects.List request = healthcare.projects().list(parameters ...)} * </pre> * * @return the resource collection */ public Projects projects() { return new Projects(); } /** * The "projects" collection of methods. */ public class Projects { /** * An accessor for creating requests from the Locations collection. * * <p>The typical use is:</p> * <pre> * {@code CloudHealthcare healthcare = new CloudHealthcare(...);} * {@code CloudHealthcare.Locations.List request = healthcare.locations().list(parameters ...)} * </pre> * * @return the resource collection */ public Locations locations() { return new Locations(); } /** * The "locations" collection of methods. */ public class Locations { /** * Gets information about a location. * * Create a request for the method "locations.get". * * This request holds the parameters needed by the healthcare server. After setting any optional * parameters, call the {@link Get#execute()} method to invoke the remote operation. * * @param name Resource name for the location. * @return the request */ public Get get(java.lang.String name) throws java.io.IOException { Get result = new Get(name); initialize(result); return result; } public class Get extends CloudHealthcareRequest<com.google.api.services.healthcare.v1beta1.model.Location> { private static final String REST_PATH = "v1beta1/{+name}"; private final java.util.regex.Pattern NAME_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+$"); /** * Gets information about a location. * * Create a request for the method "locations.get". * * This request holds the parameters needed by the the healthcare server. After setting any * optional parameters, call the {@link Get#execute()} method to invoke the remote operation. <p> * {@link Get#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} * must be called to initialize this instance immediately after invoking the constructor. </p> * * @param name Resource name for the location. * @since 1.13 */ protected Get(java.lang.String name) { super(CloudHealthcare.this, "GET", REST_PATH, null, com.google.api.services.healthcare.v1beta1.model.Location.class); this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), "Parameter name must conform to the pattern " + "^projects/[^/]+/locations/[^/]+$"); } } @Override public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException { return super.executeUsingHead(); } @Override public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException { return super.buildHttpRequestUsingHead(); } @Override public Get set$Xgafv(java.lang.String $Xgafv) { return (Get) super.set$Xgafv($Xgafv); } @Override public Get setAccessToken(java.lang.String accessToken) { return (Get) super.setAccessToken(accessToken); } @Override public Get setAlt(java.lang.String alt) { return (Get) super.setAlt(alt); } @Override public Get setCallback(java.lang.String callback) { return (Get) super.setCallback(callback); } @Override public Get setFields(java.lang.String fields) { return (Get) super.setFields(fields); } @Override public Get setKey(java.lang.String key) { return (Get) super.setKey(key); } @Override public Get setOauthToken(java.lang.String oauthToken) { return (Get) super.setOauthToken(oauthToken); } @Override public Get setPrettyPrint(java.lang.Boolean prettyPrint) { return (Get) super.setPrettyPrint(prettyPrint); } @Override public Get setQuotaUser(java.lang.String quotaUser) { return (Get) super.setQuotaUser(quotaUser); } @Override public Get setUploadType(java.lang.String uploadType) { return (Get) super.setUploadType(uploadType); } @Override public Get setUploadProtocol(java.lang.String uploadProtocol) { return (Get) super.setUploadProtocol(uploadProtocol); } /** Resource name for the location. */ @com.google.api.client.util.Key private java.lang.String name; /** Resource name for the location. */ public java.lang.String getName() { return name; } /** Resource name for the location. */ public Get setName(java.lang.String name) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), "Parameter name must conform to the pattern " + "^projects/[^/]+/locations/[^/]+$"); } this.name = name; return this; } @Override public Get set(String parameterName, Object value) { return (Get) super.set(parameterName, value); } } /** * Lists information about the supported locations for this service. * * Create a request for the method "locations.list". * * This request holds the parameters needed by the healthcare server. After setting any optional * parameters, call the {@link List#execute()} method to invoke the remote operation. * * @param name The resource that owns the locations collection, if applicable. * @return the request */ public List list(java.lang.String name) throws java.io.IOException { List result = new List(name); initialize(result); return result; } public class List extends CloudHealthcareRequest<com.google.api.services.healthcare.v1beta1.model.ListLocationsResponse> { private static final String REST_PATH = "v1beta1/{+name}/locations"; private final java.util.regex.Pattern NAME_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+$"); /** * Lists information about the supported locations for this service. * * Create a request for the method "locations.list". * * This request holds the parameters needed by the the healthcare server. After setting any * optional parameters, call the {@link List#execute()} method to invoke the remote operation. <p> * {@link List#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} * must be called to initialize this instance immediately after invoking the constructor. </p> * * @param name The resource that owns the locations collection, if applicable. * @since 1.13 */ protected List(java.lang.String name) { super(CloudHealthcare.this, "GET", REST_PATH, null, com.google.api.services.healthcare.v1beta1.model.ListLocationsResponse.class); this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), "Parameter name must conform to the pattern " + "^projects/[^/]+$"); } } @Override public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException { return super.executeUsingHead(); } @Override public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException { return super.buildHttpRequestUsingHead(); } @Override public List set$Xgafv(java.lang.String $Xgafv) { return (List) super.set$Xgafv($Xgafv); } @Override public List setAccessToken(java.lang.String accessToken) { return (List) super.setAccessToken(accessToken); } @Override public List setAlt(java.lang.String alt) { return (List) super.setAlt(alt); } @Override public List setCallback(java.lang.String callback) { return (List) super.setCallback(callback); } @Override public List setFields(java.lang.String fields) { return (List) super.setFields(fields); } @Override public List setKey(java.lang.String key) { return (List) super.setKey(key); } @Override public List setOauthToken(java.lang.String oauthToken) { return (List) super.setOauthToken(oauthToken); } @Override public List setPrettyPrint(java.lang.Boolean prettyPrint) { return (List) super.setPrettyPrint(prettyPrint); } @Override public List setQuotaUser(java.lang.String quotaUser) { return (List) super.setQuotaUser(quotaUser); } @Override public List setUploadType(java.lang.String uploadType) { return (List) super.setUploadType(uploadType); } @Override public List setUploadProtocol(java.lang.String uploadProtocol) { return (List) super.setUploadProtocol(uploadProtocol); } /** The resource that owns the locations collection, if applicable. */ @com.google.api.client.util.Key private java.lang.String name; /** The resource that owns the locations collection, if applicable. */ public java.lang.String getName() { return name; } /** The resource that owns the locations collection, if applicable. */ public List setName(java.lang.String name) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), "Parameter name must conform to the pattern " + "^projects/[^/]+$"); } this.name = name; return this; } /** The standard list filter. */ @com.google.api.client.util.Key private java.lang.String filter; /** The standard list filter. */ public java.lang.String getFilter() { return filter; } /** The standard list filter. */ public List setFilter(java.lang.String filter) { this.filter = filter; return this; } /** The standard list page size. */ @com.google.api.client.util.Key private java.lang.Integer pageSize; /** The standard list page size. */ public java.lang.Integer getPageSize() { return pageSize; } /** The standard list page size. */ public List setPageSize(java.lang.Integer pageSize) { this.pageSize = pageSize; return this; } /** The standard list page token. */ @com.google.api.client.util.Key private java.lang.String pageToken; /** The standard list page token. */ public java.lang.String getPageToken() { return pageToken; } /** The standard list page token. */ public List setPageToken(java.lang.String pageToken) { this.pageToken = pageToken; return this; } @Override public List set(String parameterName, Object value) { return (List) super.set(parameterName, value); } } /** * An accessor for creating requests from the Datasets collection. * * <p>The typical use is:</p> * <pre> * {@code CloudHealthcare healthcare = new CloudHealthcare(...);} * {@code CloudHealthcare.Datasets.List request = healthcare.datasets().list(parameters ...)} * </pre> * * @return the resource collection */ public Datasets datasets() { return new Datasets(); } /** * The "datasets" collection of methods. */ public class Datasets { /** * Creates a new health dataset. Results are returned through the Operation interface which returns * either an `Operation.response` which contains a Dataset or `Operation.error`. The metadata field * type is OperationMetadata. A Google Cloud Platform project can contain up to 500 datasets across * all regions. * * Create a request for the method "datasets.create". * * This request holds the parameters needed by the healthcare server. After setting any optional * parameters, call the {@link Create#execute()} method to invoke the remote operation. * * @param parent The name of the project where the server creates the dataset. For example, * `projects/{project_id}/locations/{location_id}`. * @param content the {@link com.google.api.services.healthcare.v1beta1.model.Dataset} * @return the request */ public Create create(java.lang.String parent, com.google.api.services.healthcare.v1beta1.model.Dataset content) throws java.io.IOException { Create result = new Create(parent, content); initialize(result); return result; } public class Create extends CloudHealthcareRequest<com.google.api.services.healthcare.v1beta1.model.Operation> { private static final String REST_PATH = "v1beta1/{+parent}/datasets"; private final java.util.regex.Pattern PARENT_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+$"); /** * Creates a new health dataset. Results are returned through the Operation interface which * returns either an `Operation.response` which contains a Dataset or `Operation.error`. The * metadata field type is OperationMetadata. A Google Cloud Platform project can contain up to 500 * datasets across all regions. * * Create a request for the method "datasets.create". * * This request holds the parameters needed by the the healthcare server. After setting any * optional parameters, call the {@link Create#execute()} method to invoke the remote operation. * <p> {@link * Create#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} must * be called to initialize this instance immediately after invoking the constructor. </p> * * @param parent The name of the project where the server creates the dataset. For example, * `projects/{project_id}/locations/{location_id}`. * @param content the {@link com.google.api.services.healthcare.v1beta1.model.Dataset} * @since 1.13 */ protected Create(java.lang.String parent, com.google.api.services.healthcare.v1beta1.model.Dataset content) { super(CloudHealthcare.this, "POST", REST_PATH, content, com.google.api.services.healthcare.v1beta1.model.Operation.class); this.parent = com.google.api.client.util.Preconditions.checkNotNull(parent, "Required parameter parent must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), "Parameter parent must conform to the pattern " + "^projects/[^/]+/locations/[^/]+$"); } } @Override public Create set$Xgafv(java.lang.String $Xgafv) { return (Create) super.set$Xgafv($Xgafv); } @Override public Create setAccessToken(java.lang.String accessToken) { return (Create) super.setAccessToken(accessToken); } @Override public Create setAlt(java.lang.String alt) { return (Create) super.setAlt(alt); } @Override public Create setCallback(java.lang.String callback) { return (Create) super.setCallback(callback); } @Override public Create setFields(java.lang.String fields) { return (Create) super.setFields(fields); } @Override public Create setKey(java.lang.String key) { return (Create) super.setKey(key); } @Override public Create setOauthToken(java.lang.String oauthToken) { return (Create) super.setOauthToken(oauthToken); } @Override public Create setPrettyPrint(java.lang.Boolean prettyPrint) { return (Create) super.setPrettyPrint(prettyPrint); } @Override public Create setQuotaUser(java.lang.String quotaUser) { return (Create) super.setQuotaUser(quotaUser); } @Override public Create setUploadType(java.lang.String uploadType) { return (Create) super.setUploadType(uploadType); } @Override public Create setUploadProtocol(java.lang.String uploadProtocol) { return (Create) super.setUploadProtocol(uploadProtocol); } /** * The name of the project where the server creates the dataset. For example, * `projects/{project_id}/locations/{location_id}`. */ @com.google.api.client.util.Key private java.lang.String parent; /** The name of the project where the server creates the dataset. For example, `projects/{project_id}/locations/{location_id}`. */ public java.lang.String getParent() { return parent; } /** * The name of the project where the server creates the dataset. For example, * `projects/{project_id}/locations/{location_id}`. */ public Create setParent(java.lang.String parent) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), "Parameter parent must conform to the pattern " + "^projects/[^/]+/locations/[^/]+$"); } this.parent = parent; return this; } /** * The ID of the dataset that is being created. The string must match the following regex: * `[\p{L}\p{N}_\-\.]{1,256}`. */ @com.google.api.client.util.Key private java.lang.String datasetId; /** The ID of the dataset that is being created. The string must match the following regex: `[\p{L}\p{N}_\-\.]{1,256}`. */ public java.lang.String getDatasetId() { return datasetId; } /** * The ID of the dataset that is being created. The string must match the following regex: * `[\p{L}\p{N}_\-\.]{1,256}`. */ public Create setDatasetId(java.lang.String datasetId) { this.datasetId = datasetId; return this; } @Override public Create set(String parameterName, Object value) { return (Create) super.set(parameterName, value); } } /** * Creates a new dataset containing de-identified data from the source dataset. The metadata field * type is OperationMetadata. If the request is successful, the response field type is * DeidentifySummary. If errors occur, error details field type is DeidentifyErrorDetails. Errors * are also logged to Stackdriver Logging. For more information, see [Viewing logs](/healthcare/docs * /how-tos/stackdriver-logging). * * Create a request for the method "datasets.deidentify". * * This request holds the parameters needed by the healthcare server. After setting any optional * parameters, call the {@link Deidentify#execute()} method to invoke the remote operation. * * @param sourceDataset Source dataset resource name. For example, * `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}`. * @param content the {@link com.google.api.services.healthcare.v1beta1.model.DeidentifyDatasetRequest} * @return the request */ public Deidentify deidentify(java.lang.String sourceDataset, com.google.api.services.healthcare.v1beta1.model.DeidentifyDatasetRequest content) throws java.io.IOException { Deidentify result = new Deidentify(sourceDataset, content); initialize(result); return result; } public class Deidentify extends CloudHealthcareRequest<com.google.api.services.healthcare.v1beta1.model.Operation> { private static final String REST_PATH = "v1beta1/{+sourceDataset}:deidentify"; private final java.util.regex.Pattern SOURCE_DATASET_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/datasets/[^/]+$"); /** * Creates a new dataset containing de-identified data from the source dataset. The metadata field * type is OperationMetadata. If the request is successful, the response field type is * DeidentifySummary. If errors occur, error details field type is DeidentifyErrorDetails. Errors * are also logged to Stackdriver Logging. For more information, see [Viewing * logs](/healthcare/docs/how-tos/stackdriver-logging). * * Create a request for the method "datasets.deidentify". * * This request holds the parameters needed by the the healthcare server. After setting any * optional parameters, call the {@link Deidentify#execute()} method to invoke the remote * operation. <p> {@link * Deidentify#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} * must be called to initialize this instance immediately after invoking the constructor. </p> * * @param sourceDataset Source dataset resource name. For example, * `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}`. * @param content the {@link com.google.api.services.healthcare.v1beta1.model.DeidentifyDatasetRequest} * @since 1.13 */ protected Deidentify(java.lang.String sourceDataset, com.google.api.services.healthcare.v1beta1.model.DeidentifyDatasetRequest content) { super(CloudHealthcare.this, "POST", REST_PATH, content, com.google.api.services.healthcare.v1beta1.model.Operation.class); this.sourceDataset = com.google.api.client.util.Preconditions.checkNotNull(sourceDataset, "Required parameter sourceDataset must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(SOURCE_DATASET_PATTERN.matcher(sourceDataset).matches(), "Parameter sourceDataset must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+$"); } } @Override public Deidentify set$Xgafv(java.lang.String $Xgafv) { return (Deidentify) super.set$Xgafv($Xgafv); } @Override public Deidentify setAccessToken(java.lang.String accessToken) { return (Deidentify) super.setAccessToken(accessToken); } @Override public Deidentify setAlt(java.lang.String alt) { return (Deidentify) super.setAlt(alt); } @Override public Deidentify setCallback(java.lang.String callback) { return (Deidentify) super.setCallback(callback); } @Override public Deidentify setFields(java.lang.String fields) { return (Deidentify) super.setFields(fields); } @Override public Deidentify setKey(java.lang.String key) { return (Deidentify) super.setKey(key); } @Override public Deidentify setOauthToken(java.lang.String oauthToken) { return (Deidentify) super.setOauthToken(oauthToken); } @Override public Deidentify setPrettyPrint(java.lang.Boolean prettyPrint) { return (Deidentify) super.setPrettyPrint(prettyPrint); } @Override public Deidentify setQuotaUser(java.lang.String quotaUser) { return (Deidentify) super.setQuotaUser(quotaUser); } @Override public Deidentify setUploadType(java.lang.String uploadType) { return (Deidentify) super.setUploadType(uploadType); } @Override public Deidentify setUploadProtocol(java.lang.String uploadProtocol) { return (Deidentify) super.setUploadProtocol(uploadProtocol); } /** * Source dataset resource name. For example, * `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}`. */ @com.google.api.client.util.Key private java.lang.String sourceDataset; /** Source dataset resource name. For example, `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}`. */ public java.lang.String getSourceDataset() { return sourceDataset; } /** * Source dataset resource name. For example, * `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}`. */ public Deidentify setSourceDataset(java.lang.String sourceDataset) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(SOURCE_DATASET_PATTERN.matcher(sourceDataset).matches(), "Parameter sourceDataset must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+$"); } this.sourceDataset = sourceDataset; return this; } @Override public Deidentify set(String parameterName, Object value) { return (Deidentify) super.set(parameterName, value); } } /** * Deletes the specified health dataset and all data contained in the dataset. Deleting a dataset * does not affect the sources from which the dataset was imported (if any). * * Create a request for the method "datasets.delete". * * This request holds the parameters needed by the healthcare server. After setting any optional * parameters, call the {@link Delete#execute()} method to invoke the remote operation. * * @param name The name of the dataset to delete. For example, * `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}`. * @return the request */ public Delete delete(java.lang.String name) throws java.io.IOException { Delete result = new Delete(name); initialize(result); return result; } public class Delete extends CloudHealthcareRequest<com.google.api.services.healthcare.v1beta1.model.Empty> { private static final String REST_PATH = "v1beta1/{+name}"; private final java.util.regex.Pattern NAME_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/datasets/[^/]+$"); /** * Deletes the specified health dataset and all data contained in the dataset. Deleting a dataset * does not affect the sources from which the dataset was imported (if any). * * Create a request for the method "datasets.delete". * * This request holds the parameters needed by the the healthcare server. After setting any * optional parameters, call the {@link Delete#execute()} method to invoke the remote operation. * <p> {@link * Delete#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} must * be called to initialize this instance immediately after invoking the constructor. </p> * * @param name The name of the dataset to delete. For example, * `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}`. * @since 1.13 */ protected Delete(java.lang.String name) { super(CloudHealthcare.this, "DELETE", REST_PATH, null, com.google.api.services.healthcare.v1beta1.model.Empty.class); this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), "Parameter name must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+$"); } } @Override public Delete set$Xgafv(java.lang.String $Xgafv) { return (Delete) super.set$Xgafv($Xgafv); } @Override public Delete setAccessToken(java.lang.String accessToken) { return (Delete) super.setAccessToken(accessToken); } @Override public Delete setAlt(java.lang.String alt) { return (Delete) super.setAlt(alt); } @Override public Delete setCallback(java.lang.String callback) { return (Delete) super.setCallback(callback); } @Override public Delete setFields(java.lang.String fields) { return (Delete) super.setFields(fields); } @Override public Delete setKey(java.lang.String key) { return (Delete) super.setKey(key); } @Override public Delete setOauthToken(java.lang.String oauthToken) { return (Delete) super.setOauthToken(oauthToken); } @Override public Delete setPrettyPrint(java.lang.Boolean prettyPrint) { return (Delete) super.setPrettyPrint(prettyPrint); } @Override public Delete setQuotaUser(java.lang.String quotaUser) { return (Delete) super.setQuotaUser(quotaUser); } @Override public Delete setUploadType(java.lang.String uploadType) { return (Delete) super.setUploadType(uploadType); } @Override public Delete setUploadProtocol(java.lang.String uploadProtocol) { return (Delete) super.setUploadProtocol(uploadProtocol); } /** * The name of the dataset to delete. For example, * `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}`. */ @com.google.api.client.util.Key private java.lang.String name; /** The name of the dataset to delete. For example, `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}`. */ public java.lang.String getName() { return name; } /** * The name of the dataset to delete. For example, * `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}`. */ public Delete setName(java.lang.String name) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), "Parameter name must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+$"); } this.name = name; return this; } @Override public Delete set(String parameterName, Object value) { return (Delete) super.set(parameterName, value); } } /** * Gets any metadata associated with a dataset. * * Create a request for the method "datasets.get". * * This request holds the parameters needed by the healthcare server. After setting any optional * parameters, call the {@link Get#execute()} method to invoke the remote operation. * * @param name The name of the dataset to read. For example, * `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}`. * @return the request */ public Get get(java.lang.String name) throws java.io.IOException { Get result = new Get(name); initialize(result); return result; } public class Get extends CloudHealthcareRequest<com.google.api.services.healthcare.v1beta1.model.Dataset> { private static final String REST_PATH = "v1beta1/{+name}"; private final java.util.regex.Pattern NAME_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/datasets/[^/]+$"); /** * Gets any metadata associated with a dataset. * * Create a request for the method "datasets.get". * * This request holds the parameters needed by the the healthcare server. After setting any * optional parameters, call the {@link Get#execute()} method to invoke the remote operation. <p> * {@link Get#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} * must be called to initialize this instance immediately after invoking the constructor. </p> * * @param name The name of the dataset to read. For example, * `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}`. * @since 1.13 */ protected Get(java.lang.String name) { super(CloudHealthcare.this, "GET", REST_PATH, null, com.google.api.services.healthcare.v1beta1.model.Dataset.class); this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), "Parameter name must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+$"); } } @Override public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException { return super.executeUsingHead(); } @Override public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException { return super.buildHttpRequestUsingHead(); } @Override public Get set$Xgafv(java.lang.String $Xgafv) { return (Get) super.set$Xgafv($Xgafv); } @Override public Get setAccessToken(java.lang.String accessToken) { return (Get) super.setAccessToken(accessToken); } @Override public Get setAlt(java.lang.String alt) { return (Get) super.setAlt(alt); } @Override public Get setCallback(java.lang.String callback) { return (Get) super.setCallback(callback); } @Override public Get setFields(java.lang.String fields) { return (Get) super.setFields(fields); } @Override public Get setKey(java.lang.String key) { return (Get) super.setKey(key); } @Override public Get setOauthToken(java.lang.String oauthToken) { return (Get) super.setOauthToken(oauthToken); } @Override public Get setPrettyPrint(java.lang.Boolean prettyPrint) { return (Get) super.setPrettyPrint(prettyPrint); } @Override public Get setQuotaUser(java.lang.String quotaUser) { return (Get) super.setQuotaUser(quotaUser); } @Override public Get setUploadType(java.lang.String uploadType) { return (Get) super.setUploadType(uploadType); } @Override public Get setUploadProtocol(java.lang.String uploadProtocol) { return (Get) super.setUploadProtocol(uploadProtocol); } /** * The name of the dataset to read. For example, * `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}`. */ @com.google.api.client.util.Key private java.lang.String name; /** The name of the dataset to read. For example, `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}`. */ public java.lang.String getName() { return name; } /** * The name of the dataset to read. For example, * `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}`. */ public Get setName(java.lang.String name) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), "Parameter name must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+$"); } this.name = name; return this; } @Override public Get set(String parameterName, Object value) { return (Get) super.set(parameterName, value); } } /** * Gets the access control policy for a resource. Returns an empty policy if the resource exists and * does not have a policy set. * * Create a request for the method "datasets.getIamPolicy". * * This request holds the parameters needed by the healthcare server. After setting any optional * parameters, call the {@link GetIamPolicy#execute()} method to invoke the remote operation. * * @param resource REQUIRED: The resource for which the policy is being requested. See the operation documentation for * the appropriate value for this field. * @return the request */ public GetIamPolicy getIamPolicy(java.lang.String resource) throws java.io.IOException { GetIamPolicy result = new GetIamPolicy(resource); initialize(result); return result; } public class GetIamPolicy extends CloudHealthcareRequest<com.google.api.services.healthcare.v1beta1.model.Policy> { private static final String REST_PATH = "v1beta1/{+resource}:getIamPolicy"; private final java.util.regex.Pattern RESOURCE_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/datasets/[^/]+$"); /** * Gets the access control policy for a resource. Returns an empty policy if the resource exists * and does not have a policy set. * * Create a request for the method "datasets.getIamPolicy". * * This request holds the parameters needed by the the healthcare server. After setting any * optional parameters, call the {@link GetIamPolicy#execute()} method to invoke the remote * operation. <p> {@link * GetIamPolicy#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} * must be called to initialize this instance immediately after invoking the constructor. </p> * * @param resource REQUIRED: The resource for which the policy is being requested. See the operation documentation for * the appropriate value for this field. * @since 1.13 */ protected GetIamPolicy(java.lang.String resource) { super(CloudHealthcare.this, "GET", REST_PATH, null, com.google.api.services.healthcare.v1beta1.model.Policy.class); this.resource = com.google.api.client.util.Preconditions.checkNotNull(resource, "Required parameter resource must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(RESOURCE_PATTERN.matcher(resource).matches(), "Parameter resource must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+$"); } } @Override public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException { return super.executeUsingHead(); } @Override public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException { return super.buildHttpRequestUsingHead(); } @Override public GetIamPolicy set$Xgafv(java.lang.String $Xgafv) { return (GetIamPolicy) super.set$Xgafv($Xgafv); } @Override public GetIamPolicy setAccessToken(java.lang.String accessToken) { return (GetIamPolicy) super.setAccessToken(accessToken); } @Override public GetIamPolicy setAlt(java.lang.String alt) { return (GetIamPolicy) super.setAlt(alt); } @Override public GetIamPolicy setCallback(java.lang.String callback) { return (GetIamPolicy) super.setCallback(callback); } @Override public GetIamPolicy setFields(java.lang.String fields) { return (GetIamPolicy) super.setFields(fields); } @Override public GetIamPolicy setKey(java.lang.String key) { return (GetIamPolicy) super.setKey(key); } @Override public GetIamPolicy setOauthToken(java.lang.String oauthToken) { return (GetIamPolicy) super.setOauthToken(oauthToken); } @Override public GetIamPolicy setPrettyPrint(java.lang.Boolean prettyPrint) { return (GetIamPolicy) super.setPrettyPrint(prettyPrint); } @Override public GetIamPolicy setQuotaUser(java.lang.String quotaUser) { return (GetIamPolicy) super.setQuotaUser(quotaUser); } @Override public GetIamPolicy setUploadType(java.lang.String uploadType) { return (GetIamPolicy) super.setUploadType(uploadType); } @Override public GetIamPolicy setUploadProtocol(java.lang.String uploadProtocol) { return (GetIamPolicy) super.setUploadProtocol(uploadProtocol); } /** * REQUIRED: The resource for which the policy is being requested. See the operation * documentation for the appropriate value for this field. */ @com.google.api.client.util.Key private java.lang.String resource; /** REQUIRED: The resource for which the policy is being requested. See the operation documentation for the appropriate value for this field. */ public java.lang.String getResource() { return resource; } /** * REQUIRED: The resource for which the policy is being requested. See the operation * documentation for the appropriate value for this field. */ public GetIamPolicy setResource(java.lang.String resource) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(RESOURCE_PATTERN.matcher(resource).matches(), "Parameter resource must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+$"); } this.resource = resource; return this; } /** * Optional. The policy format version to be returned. * * Valid values are 0, 1, and 3. Requests specifying an invalid value will be rejected. * * Requests for policies with any conditional bindings must specify version 3. Policies * without any conditional bindings may specify any valid value or leave the field unset. */ @com.google.api.client.util.Key("options.requestedPolicyVersion") private java.lang.Integer optionsRequestedPolicyVersion; /** Optional. The policy format version to be returned. Valid values are 0, 1, and 3. Requests specifying an invalid value will be rejected. Requests for policies with any conditional bindings must specify version 3. Policies without any conditional bindings may specify any valid value or leave the field unset. */ public java.lang.Integer getOptionsRequestedPolicyVersion() { return optionsRequestedPolicyVersion; } /** * Optional. The policy format version to be returned. * * Valid values are 0, 1, and 3. Requests specifying an invalid value will be rejected. * * Requests for policies with any conditional bindings must specify version 3. Policies * without any conditional bindings may specify any valid value or leave the field unset. */ public GetIamPolicy setOptionsRequestedPolicyVersion(java.lang.Integer optionsRequestedPolicyVersion) { this.optionsRequestedPolicyVersion = optionsRequestedPolicyVersion; return this; } @Override public GetIamPolicy set(String parameterName, Object value) { return (GetIamPolicy) super.set(parameterName, value); } } /** * Lists the health datasets in the current project. * * Create a request for the method "datasets.list". * * This request holds the parameters needed by the healthcare server. After setting any optional * parameters, call the {@link List#execute()} method to invoke the remote operation. * * @param parent The name of the project whose datasets should be listed. For example, * `projects/{project_id}/locations/{location_id}`. * @return the request */ public List list(java.lang.String parent) throws java.io.IOException { List result = new List(parent); initialize(result); return result; } public class List extends CloudHealthcareRequest<com.google.api.services.healthcare.v1beta1.model.ListDatasetsResponse> { private static final String REST_PATH = "v1beta1/{+parent}/datasets"; private final java.util.regex.Pattern PARENT_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+$"); /** * Lists the health datasets in the current project. * * Create a request for the method "datasets.list". * * This request holds the parameters needed by the the healthcare server. After setting any * optional parameters, call the {@link List#execute()} method to invoke the remote operation. <p> * {@link List#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} * must be called to initialize this instance immediately after invoking the constructor. </p> * * @param parent The name of the project whose datasets should be listed. For example, * `projects/{project_id}/locations/{location_id}`. * @since 1.13 */ protected List(java.lang.String parent) { super(CloudHealthcare.this, "GET", REST_PATH, null, com.google.api.services.healthcare.v1beta1.model.ListDatasetsResponse.class); this.parent = com.google.api.client.util.Preconditions.checkNotNull(parent, "Required parameter parent must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), "Parameter parent must conform to the pattern " + "^projects/[^/]+/locations/[^/]+$"); } } @Override public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException { return super.executeUsingHead(); } @Override public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException { return super.buildHttpRequestUsingHead(); } @Override public List set$Xgafv(java.lang.String $Xgafv) { return (List) super.set$Xgafv($Xgafv); } @Override public List setAccessToken(java.lang.String accessToken) { return (List) super.setAccessToken(accessToken); } @Override public List setAlt(java.lang.String alt) { return (List) super.setAlt(alt); } @Override public List setCallback(java.lang.String callback) { return (List) super.setCallback(callback); } @Override public List setFields(java.lang.String fields) { return (List) super.setFields(fields); } @Override public List setKey(java.lang.String key) { return (List) super.setKey(key); } @Override public List setOauthToken(java.lang.String oauthToken) { return (List) super.setOauthToken(oauthToken); } @Override public List setPrettyPrint(java.lang.Boolean prettyPrint) { return (List) super.setPrettyPrint(prettyPrint); } @Override public List setQuotaUser(java.lang.String quotaUser) { return (List) super.setQuotaUser(quotaUser); } @Override public List setUploadType(java.lang.String uploadType) { return (List) super.setUploadType(uploadType); } @Override public List setUploadProtocol(java.lang.String uploadProtocol) { return (List) super.setUploadProtocol(uploadProtocol); } /** * The name of the project whose datasets should be listed. For example, * `projects/{project_id}/locations/{location_id}`. */ @com.google.api.client.util.Key private java.lang.String parent; /** The name of the project whose datasets should be listed. For example, `projects/{project_id}/locations/{location_id}`. */ public java.lang.String getParent() { return parent; } /** * The name of the project whose datasets should be listed. For example, * `projects/{project_id}/locations/{location_id}`. */ public List setParent(java.lang.String parent) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), "Parameter parent must conform to the pattern " + "^projects/[^/]+/locations/[^/]+$"); } this.parent = parent; return this; } /** * The maximum number of items to return. Capped to 100 if not specified. May not be * larger than 1000. */ @com.google.api.client.util.Key private java.lang.Integer pageSize; /** The maximum number of items to return. Capped to 100 if not specified. May not be larger than 1000. */ public java.lang.Integer getPageSize() { return pageSize; } /** * The maximum number of items to return. Capped to 100 if not specified. May not be * larger than 1000. */ public List setPageSize(java.lang.Integer pageSize) { this.pageSize = pageSize; return this; } /** The next_page_token value returned from a previous List request, if any. */ @com.google.api.client.util.Key private java.lang.String pageToken; /** The next_page_token value returned from a previous List request, if any. */ public java.lang.String getPageToken() { return pageToken; } /** The next_page_token value returned from a previous List request, if any. */ public List setPageToken(java.lang.String pageToken) { this.pageToken = pageToken; return this; } @Override public List set(String parameterName, Object value) { return (List) super.set(parameterName, value); } } /** * Updates dataset metadata. * * Create a request for the method "datasets.patch". * * This request holds the parameters needed by the healthcare server. After setting any optional * parameters, call the {@link Patch#execute()} method to invoke the remote operation. * * @param name Output only. Resource name of the dataset, of the form * `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}`. * @param content the {@link com.google.api.services.healthcare.v1beta1.model.Dataset} * @return the request */ public Patch patch(java.lang.String name, com.google.api.services.healthcare.v1beta1.model.Dataset content) throws java.io.IOException { Patch result = new Patch(name, content); initialize(result); return result; } public class Patch extends CloudHealthcareRequest<com.google.api.services.healthcare.v1beta1.model.Dataset> { private static final String REST_PATH = "v1beta1/{+name}"; private final java.util.regex.Pattern NAME_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/datasets/[^/]+$"); /** * Updates dataset metadata. * * Create a request for the method "datasets.patch". * * This request holds the parameters needed by the the healthcare server. After setting any * optional parameters, call the {@link Patch#execute()} method to invoke the remote operation. * <p> {@link * Patch#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} must * be called to initialize this instance immediately after invoking the constructor. </p> * * @param name Output only. Resource name of the dataset, of the form * `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}`. * @param content the {@link com.google.api.services.healthcare.v1beta1.model.Dataset} * @since 1.13 */ protected Patch(java.lang.String name, com.google.api.services.healthcare.v1beta1.model.Dataset content) { super(CloudHealthcare.this, "PATCH", REST_PATH, content, com.google.api.services.healthcare.v1beta1.model.Dataset.class); this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), "Parameter name must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+$"); } } @Override public Patch set$Xgafv(java.lang.String $Xgafv) { return (Patch) super.set$Xgafv($Xgafv); } @Override public Patch setAccessToken(java.lang.String accessToken) { return (Patch) super.setAccessToken(accessToken); } @Override public Patch setAlt(java.lang.String alt) { return (Patch) super.setAlt(alt); } @Override public Patch setCallback(java.lang.String callback) { return (Patch) super.setCallback(callback); } @Override public Patch setFields(java.lang.String fields) { return (Patch) super.setFields(fields); } @Override public Patch setKey(java.lang.String key) { return (Patch) super.setKey(key); } @Override public Patch setOauthToken(java.lang.String oauthToken) { return (Patch) super.setOauthToken(oauthToken); } @Override public Patch setPrettyPrint(java.lang.Boolean prettyPrint) { return (Patch) super.setPrettyPrint(prettyPrint); } @Override public Patch setQuotaUser(java.lang.String quotaUser) { return (Patch) super.setQuotaUser(quotaUser); } @Override public Patch setUploadType(java.lang.String uploadType) { return (Patch) super.setUploadType(uploadType); } @Override public Patch setUploadProtocol(java.lang.String uploadProtocol) { return (Patch) super.setUploadProtocol(uploadProtocol); } /** * Output only. Resource name of the dataset, of the form * `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}`. */ @com.google.api.client.util.Key private java.lang.String name; /** Output only. Resource name of the dataset, of the form `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}`. */ public java.lang.String getName() { return name; } /** * Output only. Resource name of the dataset, of the form * `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}`. */ public Patch setName(java.lang.String name) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), "Parameter name must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+$"); } this.name = name; return this; } /** * The update mask applies to the resource. For the `FieldMask` definition, see * https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#fieldmask */ @com.google.api.client.util.Key private String updateMask; /** The update mask applies to the resource. For the `FieldMask` definition, see https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#fieldmask */ public String getUpdateMask() { return updateMask; } /** * The update mask applies to the resource. For the `FieldMask` definition, see * https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#fieldmask */ public Patch setUpdateMask(String updateMask) { this.updateMask = updateMask; return this; } @Override public Patch set(String parameterName, Object value) { return (Patch) super.set(parameterName, value); } } /** * Sets the access control policy on the specified resource. Replaces any existing policy. * * Can return Public Errors: NOT_FOUND, INVALID_ARGUMENT and PERMISSION_DENIED * * Create a request for the method "datasets.setIamPolicy". * * This request holds the parameters needed by the healthcare server. After setting any optional * parameters, call the {@link SetIamPolicy#execute()} method to invoke the remote operation. * * @param resource REQUIRED: The resource for which the policy is being specified. See the operation documentation for * the appropriate value for this field. * @param content the {@link com.google.api.services.healthcare.v1beta1.model.SetIamPolicyRequest} * @return the request */ public SetIamPolicy setIamPolicy(java.lang.String resource, com.google.api.services.healthcare.v1beta1.model.SetIamPolicyRequest content) throws java.io.IOException { SetIamPolicy result = new SetIamPolicy(resource, content); initialize(result); return result; } public class SetIamPolicy extends CloudHealthcareRequest<com.google.api.services.healthcare.v1beta1.model.Policy> { private static final String REST_PATH = "v1beta1/{+resource}:setIamPolicy"; private final java.util.regex.Pattern RESOURCE_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/datasets/[^/]+$"); /** * Sets the access control policy on the specified resource. Replaces any existing policy. * * Can return Public Errors: NOT_FOUND, INVALID_ARGUMENT and PERMISSION_DENIED * * Create a request for the method "datasets.setIamPolicy". * * This request holds the parameters needed by the the healthcare server. After setting any * optional parameters, call the {@link SetIamPolicy#execute()} method to invoke the remote * operation. <p> {@link * SetIamPolicy#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} * must be called to initialize this instance immediately after invoking the constructor. </p> * * @param resource REQUIRED: The resource for which the policy is being specified. See the operation documentation for * the appropriate value for this field. * @param content the {@link com.google.api.services.healthcare.v1beta1.model.SetIamPolicyRequest} * @since 1.13 */ protected SetIamPolicy(java.lang.String resource, com.google.api.services.healthcare.v1beta1.model.SetIamPolicyRequest content) { super(CloudHealthcare.this, "POST", REST_PATH, content, com.google.api.services.healthcare.v1beta1.model.Policy.class); this.resource = com.google.api.client.util.Preconditions.checkNotNull(resource, "Required parameter resource must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(RESOURCE_PATTERN.matcher(resource).matches(), "Parameter resource must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+$"); } } @Override public SetIamPolicy set$Xgafv(java.lang.String $Xgafv) { return (SetIamPolicy) super.set$Xgafv($Xgafv); } @Override public SetIamPolicy setAccessToken(java.lang.String accessToken) { return (SetIamPolicy) super.setAccessToken(accessToken); } @Override public SetIamPolicy setAlt(java.lang.String alt) { return (SetIamPolicy) super.setAlt(alt); } @Override public SetIamPolicy setCallback(java.lang.String callback) { return (SetIamPolicy) super.setCallback(callback); } @Override public SetIamPolicy setFields(java.lang.String fields) { return (SetIamPolicy) super.setFields(fields); } @Override public SetIamPolicy setKey(java.lang.String key) { return (SetIamPolicy) super.setKey(key); } @Override public SetIamPolicy setOauthToken(java.lang.String oauthToken) { return (SetIamPolicy) super.setOauthToken(oauthToken); } @Override public SetIamPolicy setPrettyPrint(java.lang.Boolean prettyPrint) { return (SetIamPolicy) super.setPrettyPrint(prettyPrint); } @Override public SetIamPolicy setQuotaUser(java.lang.String quotaUser) { return (SetIamPolicy) super.setQuotaUser(quotaUser); } @Override public SetIamPolicy setUploadType(java.lang.String uploadType) { return (SetIamPolicy) super.setUploadType(uploadType); } @Override public SetIamPolicy setUploadProtocol(java.lang.String uploadProtocol) { return (SetIamPolicy) super.setUploadProtocol(uploadProtocol); } /** * REQUIRED: The resource for which the policy is being specified. See the operation * documentation for the appropriate value for this field. */ @com.google.api.client.util.Key private java.lang.String resource; /** REQUIRED: The resource for which the policy is being specified. See the operation documentation for the appropriate value for this field. */ public java.lang.String getResource() { return resource; } /** * REQUIRED: The resource for which the policy is being specified. See the operation * documentation for the appropriate value for this field. */ public SetIamPolicy setResource(java.lang.String resource) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(RESOURCE_PATTERN.matcher(resource).matches(), "Parameter resource must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+$"); } this.resource = resource; return this; } @Override public SetIamPolicy set(String parameterName, Object value) { return (SetIamPolicy) super.set(parameterName, value); } } /** * Returns permissions that a caller has on the specified resource. If the resource does not exist, * this will return an empty set of permissions, not a NOT_FOUND error. * * Note: This operation is designed to be used for building permission-aware UIs and command-line * tools, not for authorization checking. This operation may "fail open" without warning. * * Create a request for the method "datasets.testIamPermissions". * * This request holds the parameters needed by the healthcare server. After setting any optional * parameters, call the {@link TestIamPermissions#execute()} method to invoke the remote operation. * * @param resource REQUIRED: The resource for which the policy detail is being requested. See the operation * documentation for the appropriate value for this field. * @param content the {@link com.google.api.services.healthcare.v1beta1.model.TestIamPermissionsRequest} * @return the request */ public TestIamPermissions testIamPermissions(java.lang.String resource, com.google.api.services.healthcare.v1beta1.model.TestIamPermissionsRequest content) throws java.io.IOException { TestIamPermissions result = new TestIamPermissions(resource, content); initialize(result); return result; } public class TestIamPermissions extends CloudHealthcareRequest<com.google.api.services.healthcare.v1beta1.model.TestIamPermissionsResponse> { private static final String REST_PATH = "v1beta1/{+resource}:testIamPermissions"; private final java.util.regex.Pattern RESOURCE_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/datasets/[^/]+$"); /** * Returns permissions that a caller has on the specified resource. If the resource does not * exist, this will return an empty set of permissions, not a NOT_FOUND error. * * Note: This operation is designed to be used for building permission-aware UIs and command-line * tools, not for authorization checking. This operation may "fail open" without warning. * * Create a request for the method "datasets.testIamPermissions". * * This request holds the parameters needed by the the healthcare server. After setting any * optional parameters, call the {@link TestIamPermissions#execute()} method to invoke the remote * operation. <p> {@link TestIamPermissions#initialize(com.google.api.client.googleapis.services.A * bstractGoogleClientRequest)} must be called to initialize this instance immediately after * invoking the constructor. </p> * * @param resource REQUIRED: The resource for which the policy detail is being requested. See the operation * documentation for the appropriate value for this field. * @param content the {@link com.google.api.services.healthcare.v1beta1.model.TestIamPermissionsRequest} * @since 1.13 */ protected TestIamPermissions(java.lang.String resource, com.google.api.services.healthcare.v1beta1.model.TestIamPermissionsRequest content) { super(CloudHealthcare.this, "POST", REST_PATH, content, com.google.api.services.healthcare.v1beta1.model.TestIamPermissionsResponse.class); this.resource = com.google.api.client.util.Preconditions.checkNotNull(resource, "Required parameter resource must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(RESOURCE_PATTERN.matcher(resource).matches(), "Parameter resource must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+$"); } } @Override public TestIamPermissions set$Xgafv(java.lang.String $Xgafv) { return (TestIamPermissions) super.set$Xgafv($Xgafv); } @Override public TestIamPermissions setAccessToken(java.lang.String accessToken) { return (TestIamPermissions) super.setAccessToken(accessToken); } @Override public TestIamPermissions setAlt(java.lang.String alt) { return (TestIamPermissions) super.setAlt(alt); } @Override public TestIamPermissions setCallback(java.lang.String callback) { return (TestIamPermissions) super.setCallback(callback); } @Override public TestIamPermissions setFields(java.lang.String fields) { return (TestIamPermissions) super.setFields(fields); } @Override public TestIamPermissions setKey(java.lang.String key) { return (TestIamPermissions) super.setKey(key); } @Override public TestIamPermissions setOauthToken(java.lang.String oauthToken) { return (TestIamPermissions) super.setOauthToken(oauthToken); } @Override public TestIamPermissions setPrettyPrint(java.lang.Boolean prettyPrint) { return (TestIamPermissions) super.setPrettyPrint(prettyPrint); } @Override public TestIamPermissions setQuotaUser(java.lang.String quotaUser) { return (TestIamPermissions) super.setQuotaUser(quotaUser); } @Override public TestIamPermissions setUploadType(java.lang.String uploadType) { return (TestIamPermissions) super.setUploadType(uploadType); } @Override public TestIamPermissions setUploadProtocol(java.lang.String uploadProtocol) { return (TestIamPermissions) super.setUploadProtocol(uploadProtocol); } /** * REQUIRED: The resource for which the policy detail is being requested. See the * operation documentation for the appropriate value for this field. */ @com.google.api.client.util.Key private java.lang.String resource; /** REQUIRED: The resource for which the policy detail is being requested. See the operation documentation for the appropriate value for this field. */ public java.lang.String getResource() { return resource; } /** * REQUIRED: The resource for which the policy detail is being requested. See the * operation documentation for the appropriate value for this field. */ public TestIamPermissions setResource(java.lang.String resource) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(RESOURCE_PATTERN.matcher(resource).matches(), "Parameter resource must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+$"); } this.resource = resource; return this; } @Override public TestIamPermissions set(String parameterName, Object value) { return (TestIamPermissions) super.set(parameterName, value); } } /** * An accessor for creating requests from the DicomStores collection. * * <p>The typical use is:</p> * <pre> * {@code CloudHealthcare healthcare = new CloudHealthcare(...);} * {@code CloudHealthcare.DicomStores.List request = healthcare.dicomStores().list(parameters ...)} * </pre> * * @return the resource collection */ public DicomStores dicomStores() { return new DicomStores(); } /** * The "dicomStores" collection of methods. */ public class DicomStores { /** * Creates a new DICOM store within the parent dataset. * * Create a request for the method "dicomStores.create". * * This request holds the parameters needed by the healthcare server. After setting any optional * parameters, call the {@link Create#execute()} method to invoke the remote operation. * * @param parent The name of the dataset this DICOM store belongs to. * @param content the {@link com.google.api.services.healthcare.v1beta1.model.DicomStore} * @return the request */ public Create create(java.lang.String parent, com.google.api.services.healthcare.v1beta1.model.DicomStore content) throws java.io.IOException { Create result = new Create(parent, content); initialize(result); return result; } public class Create extends CloudHealthcareRequest<com.google.api.services.healthcare.v1beta1.model.DicomStore> { private static final String REST_PATH = "v1beta1/{+parent}/dicomStores"; private final java.util.regex.Pattern PARENT_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/datasets/[^/]+$"); /** * Creates a new DICOM store within the parent dataset. * * Create a request for the method "dicomStores.create". * * This request holds the parameters needed by the the healthcare server. After setting any * optional parameters, call the {@link Create#execute()} method to invoke the remote operation. * <p> {@link * Create#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} must * be called to initialize this instance immediately after invoking the constructor. </p> * * @param parent The name of the dataset this DICOM store belongs to. * @param content the {@link com.google.api.services.healthcare.v1beta1.model.DicomStore} * @since 1.13 */ protected Create(java.lang.String parent, com.google.api.services.healthcare.v1beta1.model.DicomStore content) { super(CloudHealthcare.this, "POST", REST_PATH, content, com.google.api.services.healthcare.v1beta1.model.DicomStore.class); this.parent = com.google.api.client.util.Preconditions.checkNotNull(parent, "Required parameter parent must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), "Parameter parent must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+$"); } } @Override public Create set$Xgafv(java.lang.String $Xgafv) { return (Create) super.set$Xgafv($Xgafv); } @Override public Create setAccessToken(java.lang.String accessToken) { return (Create) super.setAccessToken(accessToken); } @Override public Create setAlt(java.lang.String alt) { return (Create) super.setAlt(alt); } @Override public Create setCallback(java.lang.String callback) { return (Create) super.setCallback(callback); } @Override public Create setFields(java.lang.String fields) { return (Create) super.setFields(fields); } @Override public Create setKey(java.lang.String key) { return (Create) super.setKey(key); } @Override public Create setOauthToken(java.lang.String oauthToken) { return (Create) super.setOauthToken(oauthToken); } @Override public Create setPrettyPrint(java.lang.Boolean prettyPrint) { return (Create) super.setPrettyPrint(prettyPrint); } @Override public Create setQuotaUser(java.lang.String quotaUser) { return (Create) super.setQuotaUser(quotaUser); } @Override public Create setUploadType(java.lang.String uploadType) { return (Create) super.setUploadType(uploadType); } @Override public Create setUploadProtocol(java.lang.String uploadProtocol) { return (Create) super.setUploadProtocol(uploadProtocol); } /** The name of the dataset this DICOM store belongs to. */ @com.google.api.client.util.Key private java.lang.String parent; /** The name of the dataset this DICOM store belongs to. */ public java.lang.String getParent() { return parent; } /** The name of the dataset this DICOM store belongs to. */ public Create setParent(java.lang.String parent) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), "Parameter parent must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+$"); } this.parent = parent; return this; } /** * The ID of the DICOM store that is being created. Any string value up to 256 * characters in length. */ @com.google.api.client.util.Key private java.lang.String dicomStoreId; /** The ID of the DICOM store that is being created. Any string value up to 256 characters in length. */ public java.lang.String getDicomStoreId() { return dicomStoreId; } /** * The ID of the DICOM store that is being created. Any string value up to 256 * characters in length. */ public Create setDicomStoreId(java.lang.String dicomStoreId) { this.dicomStoreId = dicomStoreId; return this; } @Override public Create set(String parameterName, Object value) { return (Create) super.set(parameterName, value); } } /** * Creates a new DICOM store containing de-identified data from the source store. The metadata field * type is OperationMetadata. If the request is successful, the response field type is * DeidentifyDicomStoreSummary. If errors occur, error details field type is DeidentifyErrorDetails. * Errors are also logged to Stackdriver (see [Viewing logs](/healthcare/docs/how-tos/stackdriver- * logging)). * * Create a request for the method "dicomStores.deidentify". * * This request holds the parameters needed by the healthcare server. After setting any optional * parameters, call the {@link Deidentify#execute()} method to invoke the remote operation. * * @param sourceStore Source DICOM store resource name. For example, * `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_st * ore_id}`. * @param content the {@link com.google.api.services.healthcare.v1beta1.model.DeidentifyDicomStoreRequest} * @return the request */ public Deidentify deidentify(java.lang.String sourceStore, com.google.api.services.healthcare.v1beta1.model.DeidentifyDicomStoreRequest content) throws java.io.IOException { Deidentify result = new Deidentify(sourceStore, content); initialize(result); return result; } public class Deidentify extends CloudHealthcareRequest<com.google.api.services.healthcare.v1beta1.model.Operation> { private static final String REST_PATH = "v1beta1/{+sourceStore}:deidentify"; private final java.util.regex.Pattern SOURCE_STORE_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dicomStores/[^/]+$"); /** * Creates a new DICOM store containing de-identified data from the source store. The metadata * field type is OperationMetadata. If the request is successful, the response field type is * DeidentifyDicomStoreSummary. If errors occur, error details field type is * DeidentifyErrorDetails. Errors are also logged to Stackdriver (see [Viewing * logs](/healthcare/docs/how-tos/stackdriver-logging)). * * Create a request for the method "dicomStores.deidentify". * * This request holds the parameters needed by the the healthcare server. After setting any * optional parameters, call the {@link Deidentify#execute()} method to invoke the remote * operation. <p> {@link * Deidentify#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} * must be called to initialize this instance immediately after invoking the constructor. </p> * * @param sourceStore Source DICOM store resource name. For example, * `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_st * ore_id}`. * @param content the {@link com.google.api.services.healthcare.v1beta1.model.DeidentifyDicomStoreRequest} * @since 1.13 */ protected Deidentify(java.lang.String sourceStore, com.google.api.services.healthcare.v1beta1.model.DeidentifyDicomStoreRequest content) { super(CloudHealthcare.this, "POST", REST_PATH, content, com.google.api.services.healthcare.v1beta1.model.Operation.class); this.sourceStore = com.google.api.client.util.Preconditions.checkNotNull(sourceStore, "Required parameter sourceStore must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(SOURCE_STORE_PATTERN.matcher(sourceStore).matches(), "Parameter sourceStore must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dicomStores/[^/]+$"); } } @Override public Deidentify set$Xgafv(java.lang.String $Xgafv) { return (Deidentify) super.set$Xgafv($Xgafv); } @Override public Deidentify setAccessToken(java.lang.String accessToken) { return (Deidentify) super.setAccessToken(accessToken); } @Override public Deidentify setAlt(java.lang.String alt) { return (Deidentify) super.setAlt(alt); } @Override public Deidentify setCallback(java.lang.String callback) { return (Deidentify) super.setCallback(callback); } @Override public Deidentify setFields(java.lang.String fields) { return (Deidentify) super.setFields(fields); } @Override public Deidentify setKey(java.lang.String key) { return (Deidentify) super.setKey(key); } @Override public Deidentify setOauthToken(java.lang.String oauthToken) { return (Deidentify) super.setOauthToken(oauthToken); } @Override public Deidentify setPrettyPrint(java.lang.Boolean prettyPrint) { return (Deidentify) super.setPrettyPrint(prettyPrint); } @Override public Deidentify setQuotaUser(java.lang.String quotaUser) { return (Deidentify) super.setQuotaUser(quotaUser); } @Override public Deidentify setUploadType(java.lang.String uploadType) { return (Deidentify) super.setUploadType(uploadType); } @Override public Deidentify setUploadProtocol(java.lang.String uploadProtocol) { return (Deidentify) super.setUploadProtocol(uploadProtocol); } /** * Source DICOM store resource name. For example, `projects/{project_id}/locations/{loca * tion_id}/datasets/{dataset_id}/dicomStores/{dicom_store_id}`. */ @com.google.api.client.util.Key private java.lang.String sourceStore; /** Source DICOM store resource name. For example, `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_store_id}`. */ public java.lang.String getSourceStore() { return sourceStore; } /** * Source DICOM store resource name. For example, `projects/{project_id}/locations/{loca * tion_id}/datasets/{dataset_id}/dicomStores/{dicom_store_id}`. */ public Deidentify setSourceStore(java.lang.String sourceStore) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(SOURCE_STORE_PATTERN.matcher(sourceStore).matches(), "Parameter sourceStore must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dicomStores/[^/]+$"); } this.sourceStore = sourceStore; return this; } @Override public Deidentify set(String parameterName, Object value) { return (Deidentify) super.set(parameterName, value); } } /** * Deletes the specified DICOM store and removes all images that are contained within it. * * Create a request for the method "dicomStores.delete". * * This request holds the parameters needed by the healthcare server. After setting any optional * parameters, call the {@link Delete#execute()} method to invoke the remote operation. * * @param name The resource name of the DICOM store to delete. * @return the request */ public Delete delete(java.lang.String name) throws java.io.IOException { Delete result = new Delete(name); initialize(result); return result; } public class Delete extends CloudHealthcareRequest<com.google.api.services.healthcare.v1beta1.model.Empty> { private static final String REST_PATH = "v1beta1/{+name}"; private final java.util.regex.Pattern NAME_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dicomStores/[^/]+$"); /** * Deletes the specified DICOM store and removes all images that are contained within it. * * Create a request for the method "dicomStores.delete". * * This request holds the parameters needed by the the healthcare server. After setting any * optional parameters, call the {@link Delete#execute()} method to invoke the remote operation. * <p> {@link * Delete#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} must * be called to initialize this instance immediately after invoking the constructor. </p> * * @param name The resource name of the DICOM store to delete. * @since 1.13 */ protected Delete(java.lang.String name) { super(CloudHealthcare.this, "DELETE", REST_PATH, null, com.google.api.services.healthcare.v1beta1.model.Empty.class); this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), "Parameter name must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dicomStores/[^/]+$"); } } @Override public Delete set$Xgafv(java.lang.String $Xgafv) { return (Delete) super.set$Xgafv($Xgafv); } @Override public Delete setAccessToken(java.lang.String accessToken) { return (Delete) super.setAccessToken(accessToken); } @Override public Delete setAlt(java.lang.String alt) { return (Delete) super.setAlt(alt); } @Override public Delete setCallback(java.lang.String callback) { return (Delete) super.setCallback(callback); } @Override public Delete setFields(java.lang.String fields) { return (Delete) super.setFields(fields); } @Override public Delete setKey(java.lang.String key) { return (Delete) super.setKey(key); } @Override public Delete setOauthToken(java.lang.String oauthToken) { return (Delete) super.setOauthToken(oauthToken); } @Override public Delete setPrettyPrint(java.lang.Boolean prettyPrint) { return (Delete) super.setPrettyPrint(prettyPrint); } @Override public Delete setQuotaUser(java.lang.String quotaUser) { return (Delete) super.setQuotaUser(quotaUser); } @Override public Delete setUploadType(java.lang.String uploadType) { return (Delete) super.setUploadType(uploadType); } @Override public Delete setUploadProtocol(java.lang.String uploadProtocol) { return (Delete) super.setUploadProtocol(uploadProtocol); } /** The resource name of the DICOM store to delete. */ @com.google.api.client.util.Key private java.lang.String name; /** The resource name of the DICOM store to delete. */ public java.lang.String getName() { return name; } /** The resource name of the DICOM store to delete. */ public Delete setName(java.lang.String name) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), "Parameter name must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dicomStores/[^/]+$"); } this.name = name; return this; } @Override public Delete set(String parameterName, Object value) { return (Delete) super.set(parameterName, value); } } /** * Exports data to the specified destination by copying it from the DICOM store. The metadata field * type is OperationMetadata. * * Create a request for the method "dicomStores.export". * * This request holds the parameters needed by the healthcare server. After setting any optional * parameters, call the {@link Export#execute()} method to invoke the remote operation. * * @param name The DICOM store resource name from which to export the data. For example, * `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_st * ore_id}`. * @param content the {@link com.google.api.services.healthcare.v1beta1.model.ExportDicomDataRequest} * @return the request */ public Export export(java.lang.String name, com.google.api.services.healthcare.v1beta1.model.ExportDicomDataRequest content) throws java.io.IOException { Export result = new Export(name, content); initialize(result); return result; } public class Export extends CloudHealthcareRequest<com.google.api.services.healthcare.v1beta1.model.Operation> { private static final String REST_PATH = "v1beta1/{+name}:export"; private final java.util.regex.Pattern NAME_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dicomStores/[^/]+$"); /** * Exports data to the specified destination by copying it from the DICOM store. The metadata * field type is OperationMetadata. * * Create a request for the method "dicomStores.export". * * This request holds the parameters needed by the the healthcare server. After setting any * optional parameters, call the {@link Export#execute()} method to invoke the remote operation. * <p> {@link * Export#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} must * be called to initialize this instance immediately after invoking the constructor. </p> * * @param name The DICOM store resource name from which to export the data. For example, * `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_st * ore_id}`. * @param content the {@link com.google.api.services.healthcare.v1beta1.model.ExportDicomDataRequest} * @since 1.13 */ protected Export(java.lang.String name, com.google.api.services.healthcare.v1beta1.model.ExportDicomDataRequest content) { super(CloudHealthcare.this, "POST", REST_PATH, content, com.google.api.services.healthcare.v1beta1.model.Operation.class); this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), "Parameter name must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dicomStores/[^/]+$"); } } @Override public Export set$Xgafv(java.lang.String $Xgafv) { return (Export) super.set$Xgafv($Xgafv); } @Override public Export setAccessToken(java.lang.String accessToken) { return (Export) super.setAccessToken(accessToken); } @Override public Export setAlt(java.lang.String alt) { return (Export) super.setAlt(alt); } @Override public Export setCallback(java.lang.String callback) { return (Export) super.setCallback(callback); } @Override public Export setFields(java.lang.String fields) { return (Export) super.setFields(fields); } @Override public Export setKey(java.lang.String key) { return (Export) super.setKey(key); } @Override public Export setOauthToken(java.lang.String oauthToken) { return (Export) super.setOauthToken(oauthToken); } @Override public Export setPrettyPrint(java.lang.Boolean prettyPrint) { return (Export) super.setPrettyPrint(prettyPrint); } @Override public Export setQuotaUser(java.lang.String quotaUser) { return (Export) super.setQuotaUser(quotaUser); } @Override public Export setUploadType(java.lang.String uploadType) { return (Export) super.setUploadType(uploadType); } @Override public Export setUploadProtocol(java.lang.String uploadProtocol) { return (Export) super.setUploadProtocol(uploadProtocol); } /** * The DICOM store resource name from which to export the data. For example, `projects/{ * project_id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_store_id * }`. */ @com.google.api.client.util.Key private java.lang.String name; /** The DICOM store resource name from which to export the data. For example, `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_store_id}`. */ public java.lang.String getName() { return name; } /** * The DICOM store resource name from which to export the data. For example, `projects/{ * project_id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_store_id * }`. */ public Export setName(java.lang.String name) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), "Parameter name must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dicomStores/[^/]+$"); } this.name = name; return this; } @Override public Export set(String parameterName, Object value) { return (Export) super.set(parameterName, value); } } /** * Gets the specified DICOM store. * * Create a request for the method "dicomStores.get". * * This request holds the parameters needed by the healthcare server. After setting any optional * parameters, call the {@link Get#execute()} method to invoke the remote operation. * * @param name The resource name of the DICOM store to get. * @return the request */ public Get get(java.lang.String name) throws java.io.IOException { Get result = new Get(name); initialize(result); return result; } public class Get extends CloudHealthcareRequest<com.google.api.services.healthcare.v1beta1.model.DicomStore> { private static final String REST_PATH = "v1beta1/{+name}"; private final java.util.regex.Pattern NAME_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dicomStores/[^/]+$"); /** * Gets the specified DICOM store. * * Create a request for the method "dicomStores.get". * * This request holds the parameters needed by the the healthcare server. After setting any * optional parameters, call the {@link Get#execute()} method to invoke the remote operation. <p> * {@link Get#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} * must be called to initialize this instance immediately after invoking the constructor. </p> * * @param name The resource name of the DICOM store to get. * @since 1.13 */ protected Get(java.lang.String name) { super(CloudHealthcare.this, "GET", REST_PATH, null, com.google.api.services.healthcare.v1beta1.model.DicomStore.class); this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), "Parameter name must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dicomStores/[^/]+$"); } } @Override public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException { return super.executeUsingHead(); } @Override public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException { return super.buildHttpRequestUsingHead(); } @Override public Get set$Xgafv(java.lang.String $Xgafv) { return (Get) super.set$Xgafv($Xgafv); } @Override public Get setAccessToken(java.lang.String accessToken) { return (Get) super.setAccessToken(accessToken); } @Override public Get setAlt(java.lang.String alt) { return (Get) super.setAlt(alt); } @Override public Get setCallback(java.lang.String callback) { return (Get) super.setCallback(callback); } @Override public Get setFields(java.lang.String fields) { return (Get) super.setFields(fields); } @Override public Get setKey(java.lang.String key) { return (Get) super.setKey(key); } @Override public Get setOauthToken(java.lang.String oauthToken) { return (Get) super.setOauthToken(oauthToken); } @Override public Get setPrettyPrint(java.lang.Boolean prettyPrint) { return (Get) super.setPrettyPrint(prettyPrint); } @Override public Get setQuotaUser(java.lang.String quotaUser) { return (Get) super.setQuotaUser(quotaUser); } @Override public Get setUploadType(java.lang.String uploadType) { return (Get) super.setUploadType(uploadType); } @Override public Get setUploadProtocol(java.lang.String uploadProtocol) { return (Get) super.setUploadProtocol(uploadProtocol); } /** The resource name of the DICOM store to get. */ @com.google.api.client.util.Key private java.lang.String name; /** The resource name of the DICOM store to get. */ public java.lang.String getName() { return name; } /** The resource name of the DICOM store to get. */ public Get setName(java.lang.String name) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), "Parameter name must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dicomStores/[^/]+$"); } this.name = name; return this; } @Override public Get set(String parameterName, Object value) { return (Get) super.set(parameterName, value); } } /** * Gets the access control policy for a resource. Returns an empty policy if the resource exists and * does not have a policy set. * * Create a request for the method "dicomStores.getIamPolicy". * * This request holds the parameters needed by the healthcare server. After setting any optional * parameters, call the {@link GetIamPolicy#execute()} method to invoke the remote operation. * * @param resource REQUIRED: The resource for which the policy is being requested. See the operation documentation for * the appropriate value for this field. * @return the request */ public GetIamPolicy getIamPolicy(java.lang.String resource) throws java.io.IOException { GetIamPolicy result = new GetIamPolicy(resource); initialize(result); return result; } public class GetIamPolicy extends CloudHealthcareRequest<com.google.api.services.healthcare.v1beta1.model.Policy> { private static final String REST_PATH = "v1beta1/{+resource}:getIamPolicy"; private final java.util.regex.Pattern RESOURCE_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dicomStores/[^/]+$"); /** * Gets the access control policy for a resource. Returns an empty policy if the resource exists * and does not have a policy set. * * Create a request for the method "dicomStores.getIamPolicy". * * This request holds the parameters needed by the the healthcare server. After setting any * optional parameters, call the {@link GetIamPolicy#execute()} method to invoke the remote * operation. <p> {@link * GetIamPolicy#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} * must be called to initialize this instance immediately after invoking the constructor. </p> * * @param resource REQUIRED: The resource for which the policy is being requested. See the operation documentation for * the appropriate value for this field. * @since 1.13 */ protected GetIamPolicy(java.lang.String resource) { super(CloudHealthcare.this, "GET", REST_PATH, null, com.google.api.services.healthcare.v1beta1.model.Policy.class); this.resource = com.google.api.client.util.Preconditions.checkNotNull(resource, "Required parameter resource must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(RESOURCE_PATTERN.matcher(resource).matches(), "Parameter resource must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dicomStores/[^/]+$"); } } @Override public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException { return super.executeUsingHead(); } @Override public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException { return super.buildHttpRequestUsingHead(); } @Override public GetIamPolicy set$Xgafv(java.lang.String $Xgafv) { return (GetIamPolicy) super.set$Xgafv($Xgafv); } @Override public GetIamPolicy setAccessToken(java.lang.String accessToken) { return (GetIamPolicy) super.setAccessToken(accessToken); } @Override public GetIamPolicy setAlt(java.lang.String alt) { return (GetIamPolicy) super.setAlt(alt); } @Override public GetIamPolicy setCallback(java.lang.String callback) { return (GetIamPolicy) super.setCallback(callback); } @Override public GetIamPolicy setFields(java.lang.String fields) { return (GetIamPolicy) super.setFields(fields); } @Override public GetIamPolicy setKey(java.lang.String key) { return (GetIamPolicy) super.setKey(key); } @Override public GetIamPolicy setOauthToken(java.lang.String oauthToken) { return (GetIamPolicy) super.setOauthToken(oauthToken); } @Override public GetIamPolicy setPrettyPrint(java.lang.Boolean prettyPrint) { return (GetIamPolicy) super.setPrettyPrint(prettyPrint); } @Override public GetIamPolicy setQuotaUser(java.lang.String quotaUser) { return (GetIamPolicy) super.setQuotaUser(quotaUser); } @Override public GetIamPolicy setUploadType(java.lang.String uploadType) { return (GetIamPolicy) super.setUploadType(uploadType); } @Override public GetIamPolicy setUploadProtocol(java.lang.String uploadProtocol) { return (GetIamPolicy) super.setUploadProtocol(uploadProtocol); } /** * REQUIRED: The resource for which the policy is being requested. See the operation * documentation for the appropriate value for this field. */ @com.google.api.client.util.Key private java.lang.String resource; /** REQUIRED: The resource for which the policy is being requested. See the operation documentation for the appropriate value for this field. */ public java.lang.String getResource() { return resource; } /** * REQUIRED: The resource for which the policy is being requested. See the operation * documentation for the appropriate value for this field. */ public GetIamPolicy setResource(java.lang.String resource) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(RESOURCE_PATTERN.matcher(resource).matches(), "Parameter resource must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dicomStores/[^/]+$"); } this.resource = resource; return this; } /** * Optional. The policy format version to be returned. * * Valid values are 0, 1, and 3. Requests specifying an invalid value will be rejected. * * Requests for policies with any conditional bindings must specify version 3. Policies * without any conditional bindings may specify any valid value or leave the field * unset. */ @com.google.api.client.util.Key("options.requestedPolicyVersion") private java.lang.Integer optionsRequestedPolicyVersion; /** Optional. The policy format version to be returned. Valid values are 0, 1, and 3. Requests specifying an invalid value will be rejected. Requests for policies with any conditional bindings must specify version 3. Policies without any conditional bindings may specify any valid value or leave the field unset. */ public java.lang.Integer getOptionsRequestedPolicyVersion() { return optionsRequestedPolicyVersion; } /** * Optional. The policy format version to be returned. * * Valid values are 0, 1, and 3. Requests specifying an invalid value will be rejected. * * Requests for policies with any conditional bindings must specify version 3. Policies * without any conditional bindings may specify any valid value or leave the field * unset. */ public GetIamPolicy setOptionsRequestedPolicyVersion(java.lang.Integer optionsRequestedPolicyVersion) { this.optionsRequestedPolicyVersion = optionsRequestedPolicyVersion; return this; } @Override public GetIamPolicy set(String parameterName, Object value) { return (GetIamPolicy) super.set(parameterName, value); } } /** * Imports data into the DICOM store by copying it from the specified source. For errors, the * Operation is populated with error details (in the form of ImportDicomDataErrorDetails in * error.details), which hold finer-grained error information. Errors are also logged to Stackdriver * Logging. For more information, see [Viewing logs](/healthcare/docs/how-tos/stackdriver-logging). * The metadata field type is OperationMetadata. * * Create a request for the method "dicomStores.import". * * This request holds the parameters needed by the healthcare server. After setting any optional * parameters, call the {@link CloudHealthcareImport#execute()} method to invoke the remote * operation. * * @param name The name of the DICOM store resource into which the data is imported. For example, * `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_st * ore_id}`. * @param content the {@link com.google.api.services.healthcare.v1beta1.model.ImportDicomDataRequest} * @return the request */ public CloudHealthcareImport healthcareImport(java.lang.String name, com.google.api.services.healthcare.v1beta1.model.ImportDicomDataRequest content) throws java.io.IOException { CloudHealthcareImport result = new CloudHealthcareImport(name, content); initialize(result); return result; } public class CloudHealthcareImport extends CloudHealthcareRequest<com.google.api.services.healthcare.v1beta1.model.Operation> { private static final String REST_PATH = "v1beta1/{+name}:import"; private final java.util.regex.Pattern NAME_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dicomStores/[^/]+$"); /** * Imports data into the DICOM store by copying it from the specified source. For errors, the * Operation is populated with error details (in the form of ImportDicomDataErrorDetails in * error.details), which hold finer-grained error information. Errors are also logged to * Stackdriver Logging. For more information, see [Viewing logs](/healthcare/docs/how-tos * /stackdriver-logging). The metadata field type is OperationMetadata. * * Create a request for the method "dicomStores.import". * * This request holds the parameters needed by the the healthcare server. After setting any * optional parameters, call the {@link CloudHealthcareImport#execute()} method to invoke the * remote operation. <p> {@link CloudHealthcareImport#initialize(com.google.api.client.googleapis. * services.AbstractGoogleClientRequest)} must be called to initialize this instance immediately * after invoking the constructor. </p> * * @param name The name of the DICOM store resource into which the data is imported. For example, * `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_st * ore_id}`. * @param content the {@link com.google.api.services.healthcare.v1beta1.model.ImportDicomDataRequest} * @since 1.13 */ protected CloudHealthcareImport(java.lang.String name, com.google.api.services.healthcare.v1beta1.model.ImportDicomDataRequest content) { super(CloudHealthcare.this, "POST", REST_PATH, content, com.google.api.services.healthcare.v1beta1.model.Operation.class); this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), "Parameter name must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dicomStores/[^/]+$"); } } @Override public CloudHealthcareImport set$Xgafv(java.lang.String $Xgafv) { return (CloudHealthcareImport) super.set$Xgafv($Xgafv); } @Override public CloudHealthcareImport setAccessToken(java.lang.String accessToken) { return (CloudHealthcareImport) super.setAccessToken(accessToken); } @Override public CloudHealthcareImport setAlt(java.lang.String alt) { return (CloudHealthcareImport) super.setAlt(alt); } @Override public CloudHealthcareImport setCallback(java.lang.String callback) { return (CloudHealthcareImport) super.setCallback(callback); } @Override public CloudHealthcareImport setFields(java.lang.String fields) { return (CloudHealthcareImport) super.setFields(fields); } @Override public CloudHealthcareImport setKey(java.lang.String key) { return (CloudHealthcareImport) super.setKey(key); } @Override public CloudHealthcareImport setOauthToken(java.lang.String oauthToken) { return (CloudHealthcareImport) super.setOauthToken(oauthToken); } @Override public CloudHealthcareImport setPrettyPrint(java.lang.Boolean prettyPrint) { return (CloudHealthcareImport) super.setPrettyPrint(prettyPrint); } @Override public CloudHealthcareImport setQuotaUser(java.lang.String quotaUser) { return (CloudHealthcareImport) super.setQuotaUser(quotaUser); } @Override public CloudHealthcareImport setUploadType(java.lang.String uploadType) { return (CloudHealthcareImport) super.setUploadType(uploadType); } @Override public CloudHealthcareImport setUploadProtocol(java.lang.String uploadProtocol) { return (CloudHealthcareImport) super.setUploadProtocol(uploadProtocol); } /** * The name of the DICOM store resource into which the data is imported. For example, `p * rojects/{project_id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom * _store_id}`. */ @com.google.api.client.util.Key private java.lang.String name; /** The name of the DICOM store resource into which the data is imported. For example, `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_store_id}`. */ public java.lang.String getName() { return name; } /** * The name of the DICOM store resource into which the data is imported. For example, `p * rojects/{project_id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom * _store_id}`. */ public CloudHealthcareImport setName(java.lang.String name) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), "Parameter name must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dicomStores/[^/]+$"); } this.name = name; return this; } @Override public CloudHealthcareImport set(String parameterName, Object value) { return (CloudHealthcareImport) super.set(parameterName, value); } } /** * Lists the DICOM stores in the given dataset. * * Create a request for the method "dicomStores.list". * * This request holds the parameters needed by the healthcare server. After setting any optional * parameters, call the {@link List#execute()} method to invoke the remote operation. * * @param parent Name of the dataset. * @return the request */ public List list(java.lang.String parent) throws java.io.IOException { List result = new List(parent); initialize(result); return result; } public class List extends CloudHealthcareRequest<com.google.api.services.healthcare.v1beta1.model.ListDicomStoresResponse> { private static final String REST_PATH = "v1beta1/{+parent}/dicomStores"; private final java.util.regex.Pattern PARENT_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/datasets/[^/]+$"); /** * Lists the DICOM stores in the given dataset. * * Create a request for the method "dicomStores.list". * * This request holds the parameters needed by the the healthcare server. After setting any * optional parameters, call the {@link List#execute()} method to invoke the remote operation. <p> * {@link List#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} * must be called to initialize this instance immediately after invoking the constructor. </p> * * @param parent Name of the dataset. * @since 1.13 */ protected List(java.lang.String parent) { super(CloudHealthcare.this, "GET", REST_PATH, null, com.google.api.services.healthcare.v1beta1.model.ListDicomStoresResponse.class); this.parent = com.google.api.client.util.Preconditions.checkNotNull(parent, "Required parameter parent must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), "Parameter parent must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+$"); } } @Override public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException { return super.executeUsingHead(); } @Override public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException { return super.buildHttpRequestUsingHead(); } @Override public List set$Xgafv(java.lang.String $Xgafv) { return (List) super.set$Xgafv($Xgafv); } @Override public List setAccessToken(java.lang.String accessToken) { return (List) super.setAccessToken(accessToken); } @Override public List setAlt(java.lang.String alt) { return (List) super.setAlt(alt); } @Override public List setCallback(java.lang.String callback) { return (List) super.setCallback(callback); } @Override public List setFields(java.lang.String fields) { return (List) super.setFields(fields); } @Override public List setKey(java.lang.String key) { return (List) super.setKey(key); } @Override public List setOauthToken(java.lang.String oauthToken) { return (List) super.setOauthToken(oauthToken); } @Override public List setPrettyPrint(java.lang.Boolean prettyPrint) { return (List) super.setPrettyPrint(prettyPrint); } @Override public List setQuotaUser(java.lang.String quotaUser) { return (List) super.setQuotaUser(quotaUser); } @Override public List setUploadType(java.lang.String uploadType) { return (List) super.setUploadType(uploadType); } @Override public List setUploadProtocol(java.lang.String uploadProtocol) { return (List) super.setUploadProtocol(uploadProtocol); } /** Name of the dataset. */ @com.google.api.client.util.Key private java.lang.String parent; /** Name of the dataset. */ public java.lang.String getParent() { return parent; } /** Name of the dataset. */ public List setParent(java.lang.String parent) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), "Parameter parent must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+$"); } this.parent = parent; return this; } /** * Restricts stores returned to those matching a filter. Syntax: * https://cloud.google.com/appengine/docs/standard/python/search/query_strings Only * filtering on labels is supported. For example, `labels.key=value`. */ @com.google.api.client.util.Key private java.lang.String filter; /** Restricts stores returned to those matching a filter. Syntax: https://cloud.google.com/appengine/docs/standard/python/search/query_strings Only filtering on labels is supported. For example, `labels.key=value`. */ public java.lang.String getFilter() { return filter; } /** * Restricts stores returned to those matching a filter. Syntax: * https://cloud.google.com/appengine/docs/standard/python/search/query_strings Only * filtering on labels is supported. For example, `labels.key=value`. */ public List setFilter(java.lang.String filter) { this.filter = filter; return this; } /** * Limit on the number of DICOM stores to return in a single response. If zero the * default page size of 100 is used. */ @com.google.api.client.util.Key private java.lang.Integer pageSize; /** Limit on the number of DICOM stores to return in a single response. If zero the default page size of 100 is used. */ public java.lang.Integer getPageSize() { return pageSize; } /** * Limit on the number of DICOM stores to return in a single response. If zero the * default page size of 100 is used. */ public List setPageSize(java.lang.Integer pageSize) { this.pageSize = pageSize; return this; } /** The next_page_token value returned from the previous List request, if any. */ @com.google.api.client.util.Key private java.lang.String pageToken; /** The next_page_token value returned from the previous List request, if any. */ public java.lang.String getPageToken() { return pageToken; } /** The next_page_token value returned from the previous List request, if any. */ public List setPageToken(java.lang.String pageToken) { this.pageToken = pageToken; return this; } @Override public List set(String parameterName, Object value) { return (List) super.set(parameterName, value); } } /** * Updates the specified DICOM store. * * Create a request for the method "dicomStores.patch". * * This request holds the parameters needed by the healthcare server. After setting any optional * parameters, call the {@link Patch#execute()} method to invoke the remote operation. * * @param name Output only. Resource name of the DICOM store, of the form * `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_st * ore_id}`. * @param content the {@link com.google.api.services.healthcare.v1beta1.model.DicomStore} * @return the request */ public Patch patch(java.lang.String name, com.google.api.services.healthcare.v1beta1.model.DicomStore content) throws java.io.IOException { Patch result = new Patch(name, content); initialize(result); return result; } public class Patch extends CloudHealthcareRequest<com.google.api.services.healthcare.v1beta1.model.DicomStore> { private static final String REST_PATH = "v1beta1/{+name}"; private final java.util.regex.Pattern NAME_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dicomStores/[^/]+$"); /** * Updates the specified DICOM store. * * Create a request for the method "dicomStores.patch". * * This request holds the parameters needed by the the healthcare server. After setting any * optional parameters, call the {@link Patch#execute()} method to invoke the remote operation. * <p> {@link * Patch#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} must * be called to initialize this instance immediately after invoking the constructor. </p> * * @param name Output only. Resource name of the DICOM store, of the form * `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_st * ore_id}`. * @param content the {@link com.google.api.services.healthcare.v1beta1.model.DicomStore} * @since 1.13 */ protected Patch(java.lang.String name, com.google.api.services.healthcare.v1beta1.model.DicomStore content) { super(CloudHealthcare.this, "PATCH", REST_PATH, content, com.google.api.services.healthcare.v1beta1.model.DicomStore.class); this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), "Parameter name must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dicomStores/[^/]+$"); } } @Override public Patch set$Xgafv(java.lang.String $Xgafv) { return (Patch) super.set$Xgafv($Xgafv); } @Override public Patch setAccessToken(java.lang.String accessToken) { return (Patch) super.setAccessToken(accessToken); } @Override public Patch setAlt(java.lang.String alt) { return (Patch) super.setAlt(alt); } @Override public Patch setCallback(java.lang.String callback) { return (Patch) super.setCallback(callback); } @Override public Patch setFields(java.lang.String fields) { return (Patch) super.setFields(fields); } @Override public Patch setKey(java.lang.String key) { return (Patch) super.setKey(key); } @Override public Patch setOauthToken(java.lang.String oauthToken) { return (Patch) super.setOauthToken(oauthToken); } @Override public Patch setPrettyPrint(java.lang.Boolean prettyPrint) { return (Patch) super.setPrettyPrint(prettyPrint); } @Override public Patch setQuotaUser(java.lang.String quotaUser) { return (Patch) super.setQuotaUser(quotaUser); } @Override public Patch setUploadType(java.lang.String uploadType) { return (Patch) super.setUploadType(uploadType); } @Override public Patch setUploadProtocol(java.lang.String uploadProtocol) { return (Patch) super.setUploadProtocol(uploadProtocol); } /** * Output only. Resource name of the DICOM store, of the form `projects/{project_id}/loc * ations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_store_id}`. */ @com.google.api.client.util.Key private java.lang.String name; /** Output only. Resource name of the DICOM store, of the form `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_store_id}`. */ public java.lang.String getName() { return name; } /** * Output only. Resource name of the DICOM store, of the form `projects/{project_id}/loc * ations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_store_id}`. */ public Patch setName(java.lang.String name) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), "Parameter name must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dicomStores/[^/]+$"); } this.name = name; return this; } /** * The update mask applies to the resource. For the `FieldMask` definition, see * https://developers.google.com/protocol- * buffers/docs/reference/google.protobuf#fieldmask */ @com.google.api.client.util.Key private String updateMask; /** The update mask applies to the resource. For the `FieldMask` definition, see https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#fieldmask */ public String getUpdateMask() { return updateMask; } /** * The update mask applies to the resource. For the `FieldMask` definition, see * https://developers.google.com/protocol- * buffers/docs/reference/google.protobuf#fieldmask */ public Patch setUpdateMask(String updateMask) { this.updateMask = updateMask; return this; } @Override public Patch set(String parameterName, Object value) { return (Patch) super.set(parameterName, value); } } /** * SearchForInstances returns a list of matching instances. See * http://dicom.nema.org/medical/dicom/current/output/html/part18.html#sect_10.6. * * Create a request for the method "dicomStores.searchForInstances". * * This request holds the parameters needed by the healthcare server. After setting any optional * parameters, call the {@link SearchForInstances#execute()} method to invoke the remote operation. * * @param parent The name of the DICOM store that is being accessed. For example, * `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_st * ore_id}`. * @param dicomWebPath The path of the SearchForInstancesRequest DICOMweb request. For example, `instances`, * `series/{series_uid}/instances`, or `studies/{study_uid}/instances`. * @return the request */ public SearchForInstances searchForInstances(java.lang.String parent, java.lang.String dicomWebPath) throws java.io.IOException { SearchForInstances result = new SearchForInstances(parent, dicomWebPath); initialize(result); return result; } public class SearchForInstances extends CloudHealthcareRequest<com.google.api.services.healthcare.v1beta1.model.HttpBody> { private static final String REST_PATH = "v1beta1/{+parent}/dicomWeb/{+dicomWebPath}"; private final java.util.regex.Pattern PARENT_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dicomStores/[^/]+$"); private final java.util.regex.Pattern DICOM_WEB_PATH_PATTERN = java.util.regex.Pattern.compile("^instances$"); /** * SearchForInstances returns a list of matching instances. See * http://dicom.nema.org/medical/dicom/current/output/html/part18.html#sect_10.6. * * Create a request for the method "dicomStores.searchForInstances". * * This request holds the parameters needed by the the healthcare server. After setting any * optional parameters, call the {@link SearchForInstances#execute()} method to invoke the remote * operation. <p> {@link SearchForInstances#initialize(com.google.api.client.googleapis.services.A * bstractGoogleClientRequest)} must be called to initialize this instance immediately after * invoking the constructor. </p> * * @param parent The name of the DICOM store that is being accessed. For example, * `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_st * ore_id}`. * @param dicomWebPath The path of the SearchForInstancesRequest DICOMweb request. For example, `instances`, * `series/{series_uid}/instances`, or `studies/{study_uid}/instances`. * @since 1.13 */ protected SearchForInstances(java.lang.String parent, java.lang.String dicomWebPath) { super(CloudHealthcare.this, "GET", REST_PATH, null, com.google.api.services.healthcare.v1beta1.model.HttpBody.class); this.parent = com.google.api.client.util.Preconditions.checkNotNull(parent, "Required parameter parent must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), "Parameter parent must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dicomStores/[^/]+$"); } this.dicomWebPath = com.google.api.client.util.Preconditions.checkNotNull(dicomWebPath, "Required parameter dicomWebPath must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(DICOM_WEB_PATH_PATTERN.matcher(dicomWebPath).matches(), "Parameter dicomWebPath must conform to the pattern " + "^instances$"); } } @Override public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException { return super.executeUsingHead(); } @Override public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException { return super.buildHttpRequestUsingHead(); } @Override public SearchForInstances set$Xgafv(java.lang.String $Xgafv) { return (SearchForInstances) super.set$Xgafv($Xgafv); } @Override public SearchForInstances setAccessToken(java.lang.String accessToken) { return (SearchForInstances) super.setAccessToken(accessToken); } @Override public SearchForInstances setAlt(java.lang.String alt) { return (SearchForInstances) super.setAlt(alt); } @Override public SearchForInstances setCallback(java.lang.String callback) { return (SearchForInstances) super.setCallback(callback); } @Override public SearchForInstances setFields(java.lang.String fields) { return (SearchForInstances) super.setFields(fields); } @Override public SearchForInstances setKey(java.lang.String key) { return (SearchForInstances) super.setKey(key); } @Override public SearchForInstances setOauthToken(java.lang.String oauthToken) { return (SearchForInstances) super.setOauthToken(oauthToken); } @Override public SearchForInstances setPrettyPrint(java.lang.Boolean prettyPrint) { return (SearchForInstances) super.setPrettyPrint(prettyPrint); } @Override public SearchForInstances setQuotaUser(java.lang.String quotaUser) { return (SearchForInstances) super.setQuotaUser(quotaUser); } @Override public SearchForInstances setUploadType(java.lang.String uploadType) { return (SearchForInstances) super.setUploadType(uploadType); } @Override public SearchForInstances setUploadProtocol(java.lang.String uploadProtocol) { return (SearchForInstances) super.setUploadProtocol(uploadProtocol); } /** * The name of the DICOM store that is being accessed. For example, `projects/{project_i * d}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_store_id}`. */ @com.google.api.client.util.Key private java.lang.String parent; /** The name of the DICOM store that is being accessed. For example, `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_store_id}`. */ public java.lang.String getParent() { return parent; } /** * The name of the DICOM store that is being accessed. For example, `projects/{project_i * d}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_store_id}`. */ public SearchForInstances setParent(java.lang.String parent) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), "Parameter parent must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dicomStores/[^/]+$"); } this.parent = parent; return this; } /** * The path of the SearchForInstancesRequest DICOMweb request. For example, `instances`, * `series/{series_uid}/instances`, or `studies/{study_uid}/instances`. */ @com.google.api.client.util.Key private java.lang.String dicomWebPath; /** The path of the SearchForInstancesRequest DICOMweb request. For example, `instances`, `series/{series_uid}/instances`, or `studies/{study_uid}/instances`. */ public java.lang.String getDicomWebPath() { return dicomWebPath; } /** * The path of the SearchForInstancesRequest DICOMweb request. For example, `instances`, * `series/{series_uid}/instances`, or `studies/{study_uid}/instances`. */ public SearchForInstances setDicomWebPath(java.lang.String dicomWebPath) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(DICOM_WEB_PATH_PATTERN.matcher(dicomWebPath).matches(), "Parameter dicomWebPath must conform to the pattern " + "^instances$"); } this.dicomWebPath = dicomWebPath; return this; } @Override public SearchForInstances set(String parameterName, Object value) { return (SearchForInstances) super.set(parameterName, value); } } /** * SearchForSeries returns a list of matching series. See * http://dicom.nema.org/medical/dicom/current/output/html/part18.html#sect_10.6. * * Create a request for the method "dicomStores.searchForSeries". * * This request holds the parameters needed by the healthcare server. After setting any optional * parameters, call the {@link SearchForSeries#execute()} method to invoke the remote operation. * * @param parent The name of the DICOM store that is being accessed. For example, * `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_st * ore_id}`. * @param dicomWebPath The path of the SearchForSeries DICOMweb request. For example, `series` or * `studies/{study_uid}/series`. * @return the request */ public SearchForSeries searchForSeries(java.lang.String parent, java.lang.String dicomWebPath) throws java.io.IOException { SearchForSeries result = new SearchForSeries(parent, dicomWebPath); initialize(result); return result; } public class SearchForSeries extends CloudHealthcareRequest<com.google.api.services.healthcare.v1beta1.model.HttpBody> { private static final String REST_PATH = "v1beta1/{+parent}/dicomWeb/{+dicomWebPath}"; private final java.util.regex.Pattern PARENT_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dicomStores/[^/]+$"); private final java.util.regex.Pattern DICOM_WEB_PATH_PATTERN = java.util.regex.Pattern.compile("^series$"); /** * SearchForSeries returns a list of matching series. See * http://dicom.nema.org/medical/dicom/current/output/html/part18.html#sect_10.6. * * Create a request for the method "dicomStores.searchForSeries". * * This request holds the parameters needed by the the healthcare server. After setting any * optional parameters, call the {@link SearchForSeries#execute()} method to invoke the remote * operation. <p> {@link SearchForSeries#initialize(com.google.api.client.googleapis.services.Abst * ractGoogleClientRequest)} must be called to initialize this instance immediately after invoking * the constructor. </p> * * @param parent The name of the DICOM store that is being accessed. For example, * `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_st * ore_id}`. * @param dicomWebPath The path of the SearchForSeries DICOMweb request. For example, `series` or * `studies/{study_uid}/series`. * @since 1.13 */ protected SearchForSeries(java.lang.String parent, java.lang.String dicomWebPath) { super(CloudHealthcare.this, "GET", REST_PATH, null, com.google.api.services.healthcare.v1beta1.model.HttpBody.class); this.parent = com.google.api.client.util.Preconditions.checkNotNull(parent, "Required parameter parent must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), "Parameter parent must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dicomStores/[^/]+$"); } this.dicomWebPath = com.google.api.client.util.Preconditions.checkNotNull(dicomWebPath, "Required parameter dicomWebPath must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(DICOM_WEB_PATH_PATTERN.matcher(dicomWebPath).matches(), "Parameter dicomWebPath must conform to the pattern " + "^series$"); } } @Override public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException { return super.executeUsingHead(); } @Override public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException { return super.buildHttpRequestUsingHead(); } @Override public SearchForSeries set$Xgafv(java.lang.String $Xgafv) { return (SearchForSeries) super.set$Xgafv($Xgafv); } @Override public SearchForSeries setAccessToken(java.lang.String accessToken) { return (SearchForSeries) super.setAccessToken(accessToken); } @Override public SearchForSeries setAlt(java.lang.String alt) { return (SearchForSeries) super.setAlt(alt); } @Override public SearchForSeries setCallback(java.lang.String callback) { return (SearchForSeries) super.setCallback(callback); } @Override public SearchForSeries setFields(java.lang.String fields) { return (SearchForSeries) super.setFields(fields); } @Override public SearchForSeries setKey(java.lang.String key) { return (SearchForSeries) super.setKey(key); } @Override public SearchForSeries setOauthToken(java.lang.String oauthToken) { return (SearchForSeries) super.setOauthToken(oauthToken); } @Override public SearchForSeries setPrettyPrint(java.lang.Boolean prettyPrint) { return (SearchForSeries) super.setPrettyPrint(prettyPrint); } @Override public SearchForSeries setQuotaUser(java.lang.String quotaUser) { return (SearchForSeries) super.setQuotaUser(quotaUser); } @Override public SearchForSeries setUploadType(java.lang.String uploadType) { return (SearchForSeries) super.setUploadType(uploadType); } @Override public SearchForSeries setUploadProtocol(java.lang.String uploadProtocol) { return (SearchForSeries) super.setUploadProtocol(uploadProtocol); } /** * The name of the DICOM store that is being accessed. For example, `projects/{project_i * d}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_store_id}`. */ @com.google.api.client.util.Key private java.lang.String parent; /** The name of the DICOM store that is being accessed. For example, `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_store_id}`. */ public java.lang.String getParent() { return parent; } /** * The name of the DICOM store that is being accessed. For example, `projects/{project_i * d}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_store_id}`. */ public SearchForSeries setParent(java.lang.String parent) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), "Parameter parent must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dicomStores/[^/]+$"); } this.parent = parent; return this; } /** * The path of the SearchForSeries DICOMweb request. For example, `series` or * `studies/{study_uid}/series`. */ @com.google.api.client.util.Key private java.lang.String dicomWebPath; /** The path of the SearchForSeries DICOMweb request. For example, `series` or `studies/{study_uid}/series`. */ public java.lang.String getDicomWebPath() { return dicomWebPath; } /** * The path of the SearchForSeries DICOMweb request. For example, `series` or * `studies/{study_uid}/series`. */ public SearchForSeries setDicomWebPath(java.lang.String dicomWebPath) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(DICOM_WEB_PATH_PATTERN.matcher(dicomWebPath).matches(), "Parameter dicomWebPath must conform to the pattern " + "^series$"); } this.dicomWebPath = dicomWebPath; return this; } @Override public SearchForSeries set(String parameterName, Object value) { return (SearchForSeries) super.set(parameterName, value); } } /** * SearchForStudies returns a list of matching studies. See * http://dicom.nema.org/medical/dicom/current/output/html/part18.html#sect_10.6. * * Create a request for the method "dicomStores.searchForStudies". * * This request holds the parameters needed by the healthcare server. After setting any optional * parameters, call the {@link SearchForStudies#execute()} method to invoke the remote operation. * * @param parent The name of the DICOM store that is being accessed. For example, * `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_st * ore_id}`. * @param dicomWebPath The path of the SearchForStudies DICOMweb request. For example, `studies`. * @return the request */ public SearchForStudies searchForStudies(java.lang.String parent, java.lang.String dicomWebPath) throws java.io.IOException { SearchForStudies result = new SearchForStudies(parent, dicomWebPath); initialize(result); return result; } public class SearchForStudies extends CloudHealthcareRequest<com.google.api.services.healthcare.v1beta1.model.HttpBody> { private static final String REST_PATH = "v1beta1/{+parent}/dicomWeb/{+dicomWebPath}"; private final java.util.regex.Pattern PARENT_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dicomStores/[^/]+$"); private final java.util.regex.Pattern DICOM_WEB_PATH_PATTERN = java.util.regex.Pattern.compile("^studies$"); /** * SearchForStudies returns a list of matching studies. See * http://dicom.nema.org/medical/dicom/current/output/html/part18.html#sect_10.6. * * Create a request for the method "dicomStores.searchForStudies". * * This request holds the parameters needed by the the healthcare server. After setting any * optional parameters, call the {@link SearchForStudies#execute()} method to invoke the remote * operation. <p> {@link SearchForStudies#initialize(com.google.api.client.googleapis.services.Abs * tractGoogleClientRequest)} must be called to initialize this instance immediately after * invoking the constructor. </p> * * @param parent The name of the DICOM store that is being accessed. For example, * `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_st * ore_id}`. * @param dicomWebPath The path of the SearchForStudies DICOMweb request. For example, `studies`. * @since 1.13 */ protected SearchForStudies(java.lang.String parent, java.lang.String dicomWebPath) { super(CloudHealthcare.this, "GET", REST_PATH, null, com.google.api.services.healthcare.v1beta1.model.HttpBody.class); this.parent = com.google.api.client.util.Preconditions.checkNotNull(parent, "Required parameter parent must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), "Parameter parent must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dicomStores/[^/]+$"); } this.dicomWebPath = com.google.api.client.util.Preconditions.checkNotNull(dicomWebPath, "Required parameter dicomWebPath must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(DICOM_WEB_PATH_PATTERN.matcher(dicomWebPath).matches(), "Parameter dicomWebPath must conform to the pattern " + "^studies$"); } } @Override public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException { return super.executeUsingHead(); } @Override public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException { return super.buildHttpRequestUsingHead(); } @Override public SearchForStudies set$Xgafv(java.lang.String $Xgafv) { return (SearchForStudies) super.set$Xgafv($Xgafv); } @Override public SearchForStudies setAccessToken(java.lang.String accessToken) { return (SearchForStudies) super.setAccessToken(accessToken); } @Override public SearchForStudies setAlt(java.lang.String alt) { return (SearchForStudies) super.setAlt(alt); } @Override public SearchForStudies setCallback(java.lang.String callback) { return (SearchForStudies) super.setCallback(callback); } @Override public SearchForStudies setFields(java.lang.String fields) { return (SearchForStudies) super.setFields(fields); } @Override public SearchForStudies setKey(java.lang.String key) { return (SearchForStudies) super.setKey(key); } @Override public SearchForStudies setOauthToken(java.lang.String oauthToken) { return (SearchForStudies) super.setOauthToken(oauthToken); } @Override public SearchForStudies setPrettyPrint(java.lang.Boolean prettyPrint) { return (SearchForStudies) super.setPrettyPrint(prettyPrint); } @Override public SearchForStudies setQuotaUser(java.lang.String quotaUser) { return (SearchForStudies) super.setQuotaUser(quotaUser); } @Override public SearchForStudies setUploadType(java.lang.String uploadType) { return (SearchForStudies) super.setUploadType(uploadType); } @Override public SearchForStudies setUploadProtocol(java.lang.String uploadProtocol) { return (SearchForStudies) super.setUploadProtocol(uploadProtocol); } /** * The name of the DICOM store that is being accessed. For example, `projects/{project_i * d}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_store_id}`. */ @com.google.api.client.util.Key private java.lang.String parent; /** The name of the DICOM store that is being accessed. For example, `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_store_id}`. */ public java.lang.String getParent() { return parent; } /** * The name of the DICOM store that is being accessed. For example, `projects/{project_i * d}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_store_id}`. */ public SearchForStudies setParent(java.lang.String parent) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), "Parameter parent must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dicomStores/[^/]+$"); } this.parent = parent; return this; } /** The path of the SearchForStudies DICOMweb request. For example, `studies`. */ @com.google.api.client.util.Key private java.lang.String dicomWebPath; /** The path of the SearchForStudies DICOMweb request. For example, `studies`. */ public java.lang.String getDicomWebPath() { return dicomWebPath; } /** The path of the SearchForStudies DICOMweb request. For example, `studies`. */ public SearchForStudies setDicomWebPath(java.lang.String dicomWebPath) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(DICOM_WEB_PATH_PATTERN.matcher(dicomWebPath).matches(), "Parameter dicomWebPath must conform to the pattern " + "^studies$"); } this.dicomWebPath = dicomWebPath; return this; } @Override public SearchForStudies set(String parameterName, Object value) { return (SearchForStudies) super.set(parameterName, value); } } /** * Sets the access control policy on the specified resource. Replaces any existing policy. * * Can return Public Errors: NOT_FOUND, INVALID_ARGUMENT and PERMISSION_DENIED * * Create a request for the method "dicomStores.setIamPolicy". * * This request holds the parameters needed by the healthcare server. After setting any optional * parameters, call the {@link SetIamPolicy#execute()} method to invoke the remote operation. * * @param resource REQUIRED: The resource for which the policy is being specified. See the operation documentation for * the appropriate value for this field. * @param content the {@link com.google.api.services.healthcare.v1beta1.model.SetIamPolicyRequest} * @return the request */ public SetIamPolicy setIamPolicy(java.lang.String resource, com.google.api.services.healthcare.v1beta1.model.SetIamPolicyRequest content) throws java.io.IOException { SetIamPolicy result = new SetIamPolicy(resource, content); initialize(result); return result; } public class SetIamPolicy extends CloudHealthcareRequest<com.google.api.services.healthcare.v1beta1.model.Policy> { private static final String REST_PATH = "v1beta1/{+resource}:setIamPolicy"; private final java.util.regex.Pattern RESOURCE_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dicomStores/[^/]+$"); /** * Sets the access control policy on the specified resource. Replaces any existing policy. * * Can return Public Errors: NOT_FOUND, INVALID_ARGUMENT and PERMISSION_DENIED * * Create a request for the method "dicomStores.setIamPolicy". * * This request holds the parameters needed by the the healthcare server. After setting any * optional parameters, call the {@link SetIamPolicy#execute()} method to invoke the remote * operation. <p> {@link * SetIamPolicy#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} * must be called to initialize this instance immediately after invoking the constructor. </p> * * @param resource REQUIRED: The resource for which the policy is being specified. See the operation documentation for * the appropriate value for this field. * @param content the {@link com.google.api.services.healthcare.v1beta1.model.SetIamPolicyRequest} * @since 1.13 */ protected SetIamPolicy(java.lang.String resource, com.google.api.services.healthcare.v1beta1.model.SetIamPolicyRequest content) { super(CloudHealthcare.this, "POST", REST_PATH, content, com.google.api.services.healthcare.v1beta1.model.Policy.class); this.resource = com.google.api.client.util.Preconditions.checkNotNull(resource, "Required parameter resource must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(RESOURCE_PATTERN.matcher(resource).matches(), "Parameter resource must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dicomStores/[^/]+$"); } } @Override public SetIamPolicy set$Xgafv(java.lang.String $Xgafv) { return (SetIamPolicy) super.set$Xgafv($Xgafv); } @Override public SetIamPolicy setAccessToken(java.lang.String accessToken) { return (SetIamPolicy) super.setAccessToken(accessToken); } @Override public SetIamPolicy setAlt(java.lang.String alt) { return (SetIamPolicy) super.setAlt(alt); } @Override public SetIamPolicy setCallback(java.lang.String callback) { return (SetIamPolicy) super.setCallback(callback); } @Override public SetIamPolicy setFields(java.lang.String fields) { return (SetIamPolicy) super.setFields(fields); } @Override public SetIamPolicy setKey(java.lang.String key) { return (SetIamPolicy) super.setKey(key); } @Override public SetIamPolicy setOauthToken(java.lang.String oauthToken) { return (SetIamPolicy) super.setOauthToken(oauthToken); } @Override public SetIamPolicy setPrettyPrint(java.lang.Boolean prettyPrint) { return (SetIamPolicy) super.setPrettyPrint(prettyPrint); } @Override public SetIamPolicy setQuotaUser(java.lang.String quotaUser) { return (SetIamPolicy) super.setQuotaUser(quotaUser); } @Override public SetIamPolicy setUploadType(java.lang.String uploadType) { return (SetIamPolicy) super.setUploadType(uploadType); } @Override public SetIamPolicy setUploadProtocol(java.lang.String uploadProtocol) { return (SetIamPolicy) super.setUploadProtocol(uploadProtocol); } /** * REQUIRED: The resource for which the policy is being specified. See the operation * documentation for the appropriate value for this field. */ @com.google.api.client.util.Key private java.lang.String resource; /** REQUIRED: The resource for which the policy is being specified. See the operation documentation for the appropriate value for this field. */ public java.lang.String getResource() { return resource; } /** * REQUIRED: The resource for which the policy is being specified. See the operation * documentation for the appropriate value for this field. */ public SetIamPolicy setResource(java.lang.String resource) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(RESOURCE_PATTERN.matcher(resource).matches(), "Parameter resource must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dicomStores/[^/]+$"); } this.resource = resource; return this; } @Override public SetIamPolicy set(String parameterName, Object value) { return (SetIamPolicy) super.set(parameterName, value); } } /** * StoreInstances stores DICOM instances associated with study instance unique identifiers (SUID). * See http://dicom.nema.org/medical/dicom/current/output/html/part18.html#sect_10.5. * * Create a request for the method "dicomStores.storeInstances". * * This request holds the parameters needed by the healthcare server. After setting any optional * parameters, call the {@link StoreInstances#execute()} method to invoke the remote operation. * * @param parent The name of the DICOM store that is being accessed. For example, * `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_st * ore_id}`. * @param dicomWebPath The path of the StoreInstances DICOMweb request. For example, `studies/[{study_uid}]`. Note that the * `study_uid` is optional. * @param content the {@link com.google.api.services.healthcare.v1beta1.model.HttpBody} * @return the request */ public StoreInstances storeInstances(java.lang.String parent, java.lang.String dicomWebPath, com.google.api.services.healthcare.v1beta1.model.HttpBody content) throws java.io.IOException { StoreInstances result = new StoreInstances(parent, dicomWebPath, content); initialize(result); return result; } public class StoreInstances extends CloudHealthcareRequest<com.google.api.services.healthcare.v1beta1.model.HttpBody> { private static final String REST_PATH = "v1beta1/{+parent}/dicomWeb/{+dicomWebPath}"; private final java.util.regex.Pattern PARENT_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dicomStores/[^/]+$"); private final java.util.regex.Pattern DICOM_WEB_PATH_PATTERN = java.util.regex.Pattern.compile("^studies$"); /** * StoreInstances stores DICOM instances associated with study instance unique identifiers (SUID). * See http://dicom.nema.org/medical/dicom/current/output/html/part18.html#sect_10.5. * * Create a request for the method "dicomStores.storeInstances". * * This request holds the parameters needed by the the healthcare server. After setting any * optional parameters, call the {@link StoreInstances#execute()} method to invoke the remote * operation. <p> {@link StoreInstances#initialize(com.google.api.client.googleapis.services.Abstr * actGoogleClientRequest)} must be called to initialize this instance immediately after invoking * the constructor. </p> * * @param parent The name of the DICOM store that is being accessed. For example, * `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_st * ore_id}`. * @param dicomWebPath The path of the StoreInstances DICOMweb request. For example, `studies/[{study_uid}]`. Note that the * `study_uid` is optional. * @param content the {@link com.google.api.services.healthcare.v1beta1.model.HttpBody} * @since 1.13 */ protected StoreInstances(java.lang.String parent, java.lang.String dicomWebPath, com.google.api.services.healthcare.v1beta1.model.HttpBody content) { super(CloudHealthcare.this, "POST", REST_PATH, content, com.google.api.services.healthcare.v1beta1.model.HttpBody.class); this.parent = com.google.api.client.util.Preconditions.checkNotNull(parent, "Required parameter parent must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), "Parameter parent must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dicomStores/[^/]+$"); } this.dicomWebPath = com.google.api.client.util.Preconditions.checkNotNull(dicomWebPath, "Required parameter dicomWebPath must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(DICOM_WEB_PATH_PATTERN.matcher(dicomWebPath).matches(), "Parameter dicomWebPath must conform to the pattern " + "^studies$"); } } @Override public StoreInstances set$Xgafv(java.lang.String $Xgafv) { return (StoreInstances) super.set$Xgafv($Xgafv); } @Override public StoreInstances setAccessToken(java.lang.String accessToken) { return (StoreInstances) super.setAccessToken(accessToken); } @Override public StoreInstances setAlt(java.lang.String alt) { return (StoreInstances) super.setAlt(alt); } @Override public StoreInstances setCallback(java.lang.String callback) { return (StoreInstances) super.setCallback(callback); } @Override public StoreInstances setFields(java.lang.String fields) { return (StoreInstances) super.setFields(fields); } @Override public StoreInstances setKey(java.lang.String key) { return (StoreInstances) super.setKey(key); } @Override public StoreInstances setOauthToken(java.lang.String oauthToken) { return (StoreInstances) super.setOauthToken(oauthToken); } @Override public StoreInstances setPrettyPrint(java.lang.Boolean prettyPrint) { return (StoreInstances) super.setPrettyPrint(prettyPrint); } @Override public StoreInstances setQuotaUser(java.lang.String quotaUser) { return (StoreInstances) super.setQuotaUser(quotaUser); } @Override public StoreInstances setUploadType(java.lang.String uploadType) { return (StoreInstances) super.setUploadType(uploadType); } @Override public StoreInstances setUploadProtocol(java.lang.String uploadProtocol) { return (StoreInstances) super.setUploadProtocol(uploadProtocol); } /** * The name of the DICOM store that is being accessed. For example, `projects/{project_i * d}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_store_id}`. */ @com.google.api.client.util.Key private java.lang.String parent; /** The name of the DICOM store that is being accessed. For example, `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_store_id}`. */ public java.lang.String getParent() { return parent; } /** * The name of the DICOM store that is being accessed. For example, `projects/{project_i * d}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_store_id}`. */ public StoreInstances setParent(java.lang.String parent) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), "Parameter parent must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dicomStores/[^/]+$"); } this.parent = parent; return this; } /** * The path of the StoreInstances DICOMweb request. For example, * `studies/[{study_uid}]`. Note that the `study_uid` is optional. */ @com.google.api.client.util.Key private java.lang.String dicomWebPath; /** The path of the StoreInstances DICOMweb request. For example, `studies/[{study_uid}]`. Note that the `study_uid` is optional. */ public java.lang.String getDicomWebPath() { return dicomWebPath; } /** * The path of the StoreInstances DICOMweb request. For example, * `studies/[{study_uid}]`. Note that the `study_uid` is optional. */ public StoreInstances setDicomWebPath(java.lang.String dicomWebPath) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(DICOM_WEB_PATH_PATTERN.matcher(dicomWebPath).matches(), "Parameter dicomWebPath must conform to the pattern " + "^studies$"); } this.dicomWebPath = dicomWebPath; return this; } @Override public StoreInstances set(String parameterName, Object value) { return (StoreInstances) super.set(parameterName, value); } } /** * Returns permissions that a caller has on the specified resource. If the resource does not exist, * this will return an empty set of permissions, not a NOT_FOUND error. * * Note: This operation is designed to be used for building permission-aware UIs and command-line * tools, not for authorization checking. This operation may "fail open" without warning. * * Create a request for the method "dicomStores.testIamPermissions". * * This request holds the parameters needed by the healthcare server. After setting any optional * parameters, call the {@link TestIamPermissions#execute()} method to invoke the remote operation. * * @param resource REQUIRED: The resource for which the policy detail is being requested. See the operation * documentation for the appropriate value for this field. * @param content the {@link com.google.api.services.healthcare.v1beta1.model.TestIamPermissionsRequest} * @return the request */ public TestIamPermissions testIamPermissions(java.lang.String resource, com.google.api.services.healthcare.v1beta1.model.TestIamPermissionsRequest content) throws java.io.IOException { TestIamPermissions result = new TestIamPermissions(resource, content); initialize(result); return result; } public class TestIamPermissions extends CloudHealthcareRequest<com.google.api.services.healthcare.v1beta1.model.TestIamPermissionsResponse> { private static final String REST_PATH = "v1beta1/{+resource}:testIamPermissions"; private final java.util.regex.Pattern RESOURCE_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dicomStores/[^/]+$"); /** * Returns permissions that a caller has on the specified resource. If the resource does not * exist, this will return an empty set of permissions, not a NOT_FOUND error. * * Note: This operation is designed to be used for building permission-aware UIs and command-line * tools, not for authorization checking. This operation may "fail open" without warning. * * Create a request for the method "dicomStores.testIamPermissions". * * This request holds the parameters needed by the the healthcare server. After setting any * optional parameters, call the {@link TestIamPermissions#execute()} method to invoke the remote * operation. <p> {@link TestIamPermissions#initialize(com.google.api.client.googleapis.services.A * bstractGoogleClientRequest)} must be called to initialize this instance immediately after * invoking the constructor. </p> * * @param resource REQUIRED: The resource for which the policy detail is being requested. See the operation * documentation for the appropriate value for this field. * @param content the {@link com.google.api.services.healthcare.v1beta1.model.TestIamPermissionsRequest} * @since 1.13 */ protected TestIamPermissions(java.lang.String resource, com.google.api.services.healthcare.v1beta1.model.TestIamPermissionsRequest content) { super(CloudHealthcare.this, "POST", REST_PATH, content, com.google.api.services.healthcare.v1beta1.model.TestIamPermissionsResponse.class); this.resource = com.google.api.client.util.Preconditions.checkNotNull(resource, "Required parameter resource must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(RESOURCE_PATTERN.matcher(resource).matches(), "Parameter resource must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dicomStores/[^/]+$"); } } @Override public TestIamPermissions set$Xgafv(java.lang.String $Xgafv) { return (TestIamPermissions) super.set$Xgafv($Xgafv); } @Override public TestIamPermissions setAccessToken(java.lang.String accessToken) { return (TestIamPermissions) super.setAccessToken(accessToken); } @Override public TestIamPermissions setAlt(java.lang.String alt) { return (TestIamPermissions) super.setAlt(alt); } @Override public TestIamPermissions setCallback(java.lang.String callback) { return (TestIamPermissions) super.setCallback(callback); } @Override public TestIamPermissions setFields(java.lang.String fields) { return (TestIamPermissions) super.setFields(fields); } @Override public TestIamPermissions setKey(java.lang.String key) { return (TestIamPermissions) super.setKey(key); } @Override public TestIamPermissions setOauthToken(java.lang.String oauthToken) { return (TestIamPermissions) super.setOauthToken(oauthToken); } @Override public TestIamPermissions setPrettyPrint(java.lang.Boolean prettyPrint) { return (TestIamPermissions) super.setPrettyPrint(prettyPrint); } @Override public TestIamPermissions setQuotaUser(java.lang.String quotaUser) { return (TestIamPermissions) super.setQuotaUser(quotaUser); } @Override public TestIamPermissions setUploadType(java.lang.String uploadType) { return (TestIamPermissions) super.setUploadType(uploadType); } @Override public TestIamPermissions setUploadProtocol(java.lang.String uploadProtocol) { return (TestIamPermissions) super.setUploadProtocol(uploadProtocol); } /** * REQUIRED: The resource for which the policy detail is being requested. See the * operation documentation for the appropriate value for this field. */ @com.google.api.client.util.Key private java.lang.String resource; /** REQUIRED: The resource for which the policy detail is being requested. See the operation documentation for the appropriate value for this field. */ public java.lang.String getResource() { return resource; } /** * REQUIRED: The resource for which the policy detail is being requested. See the * operation documentation for the appropriate value for this field. */ public TestIamPermissions setResource(java.lang.String resource) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(RESOURCE_PATTERN.matcher(resource).matches(), "Parameter resource must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dicomStores/[^/]+$"); } this.resource = resource; return this; } @Override public TestIamPermissions set(String parameterName, Object value) { return (TestIamPermissions) super.set(parameterName, value); } } /** * An accessor for creating requests from the Studies collection. * * <p>The typical use is:</p> * <pre> * {@code CloudHealthcare healthcare = new CloudHealthcare(...);} * {@code CloudHealthcare.Studies.List request = healthcare.studies().list(parameters ...)} * </pre> * * @return the resource collection */ public Studies studies() { return new Studies(); } /** * The "studies" collection of methods. */ public class Studies { /** * DeleteStudy deletes all instances within the given study. Delete requests are equivalent to the * GET requests specified in the WADO-RS standard. * * Create a request for the method "studies.delete". * * This request holds the parameters needed by the healthcare server. After setting any optional * parameters, call the {@link Delete#execute()} method to invoke the remote operation. * * @param parent * @param dicomWebPath The path of the DeleteStudy request. For example, `studies/{study_uid}`. * @return the request */ public Delete delete(java.lang.String parent, java.lang.String dicomWebPath) throws java.io.IOException { Delete result = new Delete(parent, dicomWebPath); initialize(result); return result; } public class Delete extends CloudHealthcareRequest<com.google.api.services.healthcare.v1beta1.model.Empty> { private static final String REST_PATH = "v1beta1/{+parent}/dicomWeb/{+dicomWebPath}"; private final java.util.regex.Pattern PARENT_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dicomStores/[^/]+$"); private final java.util.regex.Pattern DICOM_WEB_PATH_PATTERN = java.util.regex.Pattern.compile("^studies/[^/]+$"); /** * DeleteStudy deletes all instances within the given study. Delete requests are equivalent to the * GET requests specified in the WADO-RS standard. * * Create a request for the method "studies.delete". * * This request holds the parameters needed by the the healthcare server. After setting any * optional parameters, call the {@link Delete#execute()} method to invoke the remote operation. * <p> {@link * Delete#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} must * be called to initialize this instance immediately after invoking the constructor. </p> * * @param parent * @param dicomWebPath The path of the DeleteStudy request. For example, `studies/{study_uid}`. * @since 1.13 */ protected Delete(java.lang.String parent, java.lang.String dicomWebPath) { super(CloudHealthcare.this, "DELETE", REST_PATH, null, com.google.api.services.healthcare.v1beta1.model.Empty.class); this.parent = com.google.api.client.util.Preconditions.checkNotNull(parent, "Required parameter parent must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), "Parameter parent must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dicomStores/[^/]+$"); } this.dicomWebPath = com.google.api.client.util.Preconditions.checkNotNull(dicomWebPath, "Required parameter dicomWebPath must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(DICOM_WEB_PATH_PATTERN.matcher(dicomWebPath).matches(), "Parameter dicomWebPath must conform to the pattern " + "^studies/[^/]+$"); } } @Override public Delete set$Xgafv(java.lang.String $Xgafv) { return (Delete) super.set$Xgafv($Xgafv); } @Override public Delete setAccessToken(java.lang.String accessToken) { return (Delete) super.setAccessToken(accessToken); } @Override public Delete setAlt(java.lang.String alt) { return (Delete) super.setAlt(alt); } @Override public Delete setCallback(java.lang.String callback) { return (Delete) super.setCallback(callback); } @Override public Delete setFields(java.lang.String fields) { return (Delete) super.setFields(fields); } @Override public Delete setKey(java.lang.String key) { return (Delete) super.setKey(key); } @Override public Delete setOauthToken(java.lang.String oauthToken) { return (Delete) super.setOauthToken(oauthToken); } @Override public Delete setPrettyPrint(java.lang.Boolean prettyPrint) { return (Delete) super.setPrettyPrint(prettyPrint); } @Override public Delete setQuotaUser(java.lang.String quotaUser) { return (Delete) super.setQuotaUser(quotaUser); } @Override public Delete setUploadType(java.lang.String uploadType) { return (Delete) super.setUploadType(uploadType); } @Override public Delete setUploadProtocol(java.lang.String uploadProtocol) { return (Delete) super.setUploadProtocol(uploadProtocol); } @com.google.api.client.util.Key private java.lang.String parent; /** */ public java.lang.String getParent() { return parent; } public Delete setParent(java.lang.String parent) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), "Parameter parent must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dicomStores/[^/]+$"); } this.parent = parent; return this; } /** The path of the DeleteStudy request. For example, `studies/{study_uid}`. */ @com.google.api.client.util.Key private java.lang.String dicomWebPath; /** The path of the DeleteStudy request. For example, `studies/{study_uid}`. */ public java.lang.String getDicomWebPath() { return dicomWebPath; } /** The path of the DeleteStudy request. For example, `studies/{study_uid}`. */ public Delete setDicomWebPath(java.lang.String dicomWebPath) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(DICOM_WEB_PATH_PATTERN.matcher(dicomWebPath).matches(), "Parameter dicomWebPath must conform to the pattern " + "^studies/[^/]+$"); } this.dicomWebPath = dicomWebPath; return this; } @Override public Delete set(String parameterName, Object value) { return (Delete) super.set(parameterName, value); } } /** * RetrieveStudyMetadata returns instance associated with the given study presented as metadata with * the bulk data removed. See * http://dicom.nema.org/medical/dicom/current/output/html/part18.html#sect_10.4. * * Create a request for the method "studies.retrieveMetadata". * * This request holds the parameters needed by the healthcare server. After setting any optional * parameters, call the {@link RetrieveMetadata#execute()} method to invoke the remote operation. * * @param parent The name of the DICOM store that is being accessed. For example, * `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_st * ore_id}`. * @param dicomWebPath The path of the RetrieveStudyMetadata DICOMweb request. For example, `studies/{study_uid}/metadata`. * @return the request */ public RetrieveMetadata retrieveMetadata(java.lang.String parent, java.lang.String dicomWebPath) throws java.io.IOException { RetrieveMetadata result = new RetrieveMetadata(parent, dicomWebPath); initialize(result); return result; } public class RetrieveMetadata extends CloudHealthcareRequest<com.google.api.services.healthcare.v1beta1.model.HttpBody> { private static final String REST_PATH = "v1beta1/{+parent}/dicomWeb/{+dicomWebPath}"; private final java.util.regex.Pattern PARENT_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dicomStores/[^/]+$"); private final java.util.regex.Pattern DICOM_WEB_PATH_PATTERN = java.util.regex.Pattern.compile("^studies/[^/]+/metadata$"); /** * RetrieveStudyMetadata returns instance associated with the given study presented as metadata * with the bulk data removed. See * http://dicom.nema.org/medical/dicom/current/output/html/part18.html#sect_10.4. * * Create a request for the method "studies.retrieveMetadata". * * This request holds the parameters needed by the the healthcare server. After setting any * optional parameters, call the {@link RetrieveMetadata#execute()} method to invoke the remote * operation. <p> {@link RetrieveMetadata#initialize(com.google.api.client.googleapis.services.Abs * tractGoogleClientRequest)} must be called to initialize this instance immediately after * invoking the constructor. </p> * * @param parent The name of the DICOM store that is being accessed. For example, * `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_st * ore_id}`. * @param dicomWebPath The path of the RetrieveStudyMetadata DICOMweb request. For example, `studies/{study_uid}/metadata`. * @since 1.13 */ protected RetrieveMetadata(java.lang.String parent, java.lang.String dicomWebPath) { super(CloudHealthcare.this, "GET", REST_PATH, null, com.google.api.services.healthcare.v1beta1.model.HttpBody.class); this.parent = com.google.api.client.util.Preconditions.checkNotNull(parent, "Required parameter parent must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), "Parameter parent must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dicomStores/[^/]+$"); } this.dicomWebPath = com.google.api.client.util.Preconditions.checkNotNull(dicomWebPath, "Required parameter dicomWebPath must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(DICOM_WEB_PATH_PATTERN.matcher(dicomWebPath).matches(), "Parameter dicomWebPath must conform to the pattern " + "^studies/[^/]+/metadata$"); } } @Override public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException { return super.executeUsingHead(); } @Override public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException { return super.buildHttpRequestUsingHead(); } @Override public RetrieveMetadata set$Xgafv(java.lang.String $Xgafv) { return (RetrieveMetadata) super.set$Xgafv($Xgafv); } @Override public RetrieveMetadata setAccessToken(java.lang.String accessToken) { return (RetrieveMetadata) super.setAccessToken(accessToken); } @Override public RetrieveMetadata setAlt(java.lang.String alt) { return (RetrieveMetadata) super.setAlt(alt); } @Override public RetrieveMetadata setCallback(java.lang.String callback) { return (RetrieveMetadata) super.setCallback(callback); } @Override public RetrieveMetadata setFields(java.lang.String fields) { return (RetrieveMetadata) super.setFields(fields); } @Override public RetrieveMetadata setKey(java.lang.String key) { return (RetrieveMetadata) super.setKey(key); } @Override public RetrieveMetadata setOauthToken(java.lang.String oauthToken) { return (RetrieveMetadata) super.setOauthToken(oauthToken); } @Override public RetrieveMetadata setPrettyPrint(java.lang.Boolean prettyPrint) { return (RetrieveMetadata) super.setPrettyPrint(prettyPrint); } @Override public RetrieveMetadata setQuotaUser(java.lang.String quotaUser) { return (RetrieveMetadata) super.setQuotaUser(quotaUser); } @Override public RetrieveMetadata setUploadType(java.lang.String uploadType) { return (RetrieveMetadata) super.setUploadType(uploadType); } @Override public RetrieveMetadata setUploadProtocol(java.lang.String uploadProtocol) { return (RetrieveMetadata) super.setUploadProtocol(uploadProtocol); } /** * The name of the DICOM store that is being accessed. For example, `projects/{project * _id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_store_id}`. */ @com.google.api.client.util.Key private java.lang.String parent; /** The name of the DICOM store that is being accessed. For example, `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_store_id}`. */ public java.lang.String getParent() { return parent; } /** * The name of the DICOM store that is being accessed. For example, `projects/{project * _id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_store_id}`. */ public RetrieveMetadata setParent(java.lang.String parent) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), "Parameter parent must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dicomStores/[^/]+$"); } this.parent = parent; return this; } /** * The path of the RetrieveStudyMetadata DICOMweb request. For example, * `studies/{study_uid}/metadata`. */ @com.google.api.client.util.Key private java.lang.String dicomWebPath; /** The path of the RetrieveStudyMetadata DICOMweb request. For example, `studies/{study_uid}/metadata`. */ public java.lang.String getDicomWebPath() { return dicomWebPath; } /** * The path of the RetrieveStudyMetadata DICOMweb request. For example, * `studies/{study_uid}/metadata`. */ public RetrieveMetadata setDicomWebPath(java.lang.String dicomWebPath) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(DICOM_WEB_PATH_PATTERN.matcher(dicomWebPath).matches(), "Parameter dicomWebPath must conform to the pattern " + "^studies/[^/]+/metadata$"); } this.dicomWebPath = dicomWebPath; return this; } @Override public RetrieveMetadata set(String parameterName, Object value) { return (RetrieveMetadata) super.set(parameterName, value); } } /** * RetrieveStudy returns all instances within the given study. See * http://dicom.nema.org/medical/dicom/current/output/html/part18.html#sect_10.4. * * Create a request for the method "studies.retrieveStudy". * * This request holds the parameters needed by the healthcare server. After setting any optional * parameters, call the {@link RetrieveStudy#execute()} method to invoke the remote operation. * * @param parent The name of the DICOM store that is being accessed. For example, * `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_st * ore_id}`. * @param dicomWebPath The path of the RetrieveStudy DICOMweb request. For example, `studies/{study_uid}`. * @return the request */ public RetrieveStudy retrieveStudy(java.lang.String parent, java.lang.String dicomWebPath) throws java.io.IOException { RetrieveStudy result = new RetrieveStudy(parent, dicomWebPath); initialize(result); return result; } public class RetrieveStudy extends CloudHealthcareRequest<com.google.api.services.healthcare.v1beta1.model.HttpBody> { private static final String REST_PATH = "v1beta1/{+parent}/dicomWeb/{+dicomWebPath}"; private final java.util.regex.Pattern PARENT_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dicomStores/[^/]+$"); private final java.util.regex.Pattern DICOM_WEB_PATH_PATTERN = java.util.regex.Pattern.compile("^studies/[^/]+$"); /** * RetrieveStudy returns all instances within the given study. See * http://dicom.nema.org/medical/dicom/current/output/html/part18.html#sect_10.4. * * Create a request for the method "studies.retrieveStudy". * * This request holds the parameters needed by the the healthcare server. After setting any * optional parameters, call the {@link RetrieveStudy#execute()} method to invoke the remote * operation. <p> {@link RetrieveStudy#initialize(com.google.api.client.googleapis.services.Abstra * ctGoogleClientRequest)} must be called to initialize this instance immediately after invoking * the constructor. </p> * * @param parent The name of the DICOM store that is being accessed. For example, * `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_st * ore_id}`. * @param dicomWebPath The path of the RetrieveStudy DICOMweb request. For example, `studies/{study_uid}`. * @since 1.13 */ protected RetrieveStudy(java.lang.String parent, java.lang.String dicomWebPath) { super(CloudHealthcare.this, "GET", REST_PATH, null, com.google.api.services.healthcare.v1beta1.model.HttpBody.class); this.parent = com.google.api.client.util.Preconditions.checkNotNull(parent, "Required parameter parent must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), "Parameter parent must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dicomStores/[^/]+$"); } this.dicomWebPath = com.google.api.client.util.Preconditions.checkNotNull(dicomWebPath, "Required parameter dicomWebPath must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(DICOM_WEB_PATH_PATTERN.matcher(dicomWebPath).matches(), "Parameter dicomWebPath must conform to the pattern " + "^studies/[^/]+$"); } } @Override public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException { return super.executeUsingHead(); } @Override public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException { return super.buildHttpRequestUsingHead(); } @Override public RetrieveStudy set$Xgafv(java.lang.String $Xgafv) { return (RetrieveStudy) super.set$Xgafv($Xgafv); } @Override public RetrieveStudy setAccessToken(java.lang.String accessToken) { return (RetrieveStudy) super.setAccessToken(accessToken); } @Override public RetrieveStudy setAlt(java.lang.String alt) { return (RetrieveStudy) super.setAlt(alt); } @Override public RetrieveStudy setCallback(java.lang.String callback) { return (RetrieveStudy) super.setCallback(callback); } @Override public RetrieveStudy setFields(java.lang.String fields) { return (RetrieveStudy) super.setFields(fields); } @Override public RetrieveStudy setKey(java.lang.String key) { return (RetrieveStudy) super.setKey(key); } @Override public RetrieveStudy setOauthToken(java.lang.String oauthToken) { return (RetrieveStudy) super.setOauthToken(oauthToken); } @Override public RetrieveStudy setPrettyPrint(java.lang.Boolean prettyPrint) { return (RetrieveStudy) super.setPrettyPrint(prettyPrint); } @Override public RetrieveStudy setQuotaUser(java.lang.String quotaUser) { return (RetrieveStudy) super.setQuotaUser(quotaUser); } @Override public RetrieveStudy setUploadType(java.lang.String uploadType) { return (RetrieveStudy) super.setUploadType(uploadType); } @Override public RetrieveStudy setUploadProtocol(java.lang.String uploadProtocol) { return (RetrieveStudy) super.setUploadProtocol(uploadProtocol); } /** * The name of the DICOM store that is being accessed. For example, `projects/{project * _id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_store_id}`. */ @com.google.api.client.util.Key private java.lang.String parent; /** The name of the DICOM store that is being accessed. For example, `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_store_id}`. */ public java.lang.String getParent() { return parent; } /** * The name of the DICOM store that is being accessed. For example, `projects/{project * _id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_store_id}`. */ public RetrieveStudy setParent(java.lang.String parent) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), "Parameter parent must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dicomStores/[^/]+$"); } this.parent = parent; return this; } /** * The path of the RetrieveStudy DICOMweb request. For example, `studies/{study_uid}`. */ @com.google.api.client.util.Key private java.lang.String dicomWebPath; /** The path of the RetrieveStudy DICOMweb request. For example, `studies/{study_uid}`. */ public java.lang.String getDicomWebPath() { return dicomWebPath; } /** * The path of the RetrieveStudy DICOMweb request. For example, `studies/{study_uid}`. */ public RetrieveStudy setDicomWebPath(java.lang.String dicomWebPath) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(DICOM_WEB_PATH_PATTERN.matcher(dicomWebPath).matches(), "Parameter dicomWebPath must conform to the pattern " + "^studies/[^/]+$"); } this.dicomWebPath = dicomWebPath; return this; } @Override public RetrieveStudy set(String parameterName, Object value) { return (RetrieveStudy) super.set(parameterName, value); } } /** * SearchForInstances returns a list of matching instances. See * http://dicom.nema.org/medical/dicom/current/output/html/part18.html#sect_10.6. * * Create a request for the method "studies.searchForInstances". * * This request holds the parameters needed by the healthcare server. After setting any optional * parameters, call the {@link SearchForInstances#execute()} method to invoke the remote operation. * * @param parent The name of the DICOM store that is being accessed. For example, * `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_st * ore_id}`. * @param dicomWebPath The path of the SearchForInstancesRequest DICOMweb request. For example, `instances`, * `series/{series_uid}/instances`, or `studies/{study_uid}/instances`. * @return the request */ public SearchForInstances searchForInstances(java.lang.String parent, java.lang.String dicomWebPath) throws java.io.IOException { SearchForInstances result = new SearchForInstances(parent, dicomWebPath); initialize(result); return result; } public class SearchForInstances extends CloudHealthcareRequest<com.google.api.services.healthcare.v1beta1.model.HttpBody> { private static final String REST_PATH = "v1beta1/{+parent}/dicomWeb/{+dicomWebPath}"; private final java.util.regex.Pattern PARENT_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dicomStores/[^/]+$"); private final java.util.regex.Pattern DICOM_WEB_PATH_PATTERN = java.util.regex.Pattern.compile("^studies/[^/]+/instances$"); /** * SearchForInstances returns a list of matching instances. See * http://dicom.nema.org/medical/dicom/current/output/html/part18.html#sect_10.6. * * Create a request for the method "studies.searchForInstances". * * This request holds the parameters needed by the the healthcare server. After setting any * optional parameters, call the {@link SearchForInstances#execute()} method to invoke the remote * operation. <p> {@link SearchForInstances#initialize(com.google.api.client.googleapis.services.A * bstractGoogleClientRequest)} must be called to initialize this instance immediately after * invoking the constructor. </p> * * @param parent The name of the DICOM store that is being accessed. For example, * `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_st * ore_id}`. * @param dicomWebPath The path of the SearchForInstancesRequest DICOMweb request. For example, `instances`, * `series/{series_uid}/instances`, or `studies/{study_uid}/instances`. * @since 1.13 */ protected SearchForInstances(java.lang.String parent, java.lang.String dicomWebPath) { super(CloudHealthcare.this, "GET", REST_PATH, null, com.google.api.services.healthcare.v1beta1.model.HttpBody.class); this.parent = com.google.api.client.util.Preconditions.checkNotNull(parent, "Required parameter parent must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), "Parameter parent must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dicomStores/[^/]+$"); } this.dicomWebPath = com.google.api.client.util.Preconditions.checkNotNull(dicomWebPath, "Required parameter dicomWebPath must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(DICOM_WEB_PATH_PATTERN.matcher(dicomWebPath).matches(), "Parameter dicomWebPath must conform to the pattern " + "^studies/[^/]+/instances$"); } } @Override public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException { return super.executeUsingHead(); } @Override public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException { return super.buildHttpRequestUsingHead(); } @Override public SearchForInstances set$Xgafv(java.lang.String $Xgafv) { return (SearchForInstances) super.set$Xgafv($Xgafv); } @Override public SearchForInstances setAccessToken(java.lang.String accessToken) { return (SearchForInstances) super.setAccessToken(accessToken); } @Override public SearchForInstances setAlt(java.lang.String alt) { return (SearchForInstances) super.setAlt(alt); } @Override public SearchForInstances setCallback(java.lang.String callback) { return (SearchForInstances) super.setCallback(callback); } @Override public SearchForInstances setFields(java.lang.String fields) { return (SearchForInstances) super.setFields(fields); } @Override public SearchForInstances setKey(java.lang.String key) { return (SearchForInstances) super.setKey(key); } @Override public SearchForInstances setOauthToken(java.lang.String oauthToken) { return (SearchForInstances) super.setOauthToken(oauthToken); } @Override public SearchForInstances setPrettyPrint(java.lang.Boolean prettyPrint) { return (SearchForInstances) super.setPrettyPrint(prettyPrint); } @Override public SearchForInstances setQuotaUser(java.lang.String quotaUser) { return (SearchForInstances) super.setQuotaUser(quotaUser); } @Override public SearchForInstances setUploadType(java.lang.String uploadType) { return (SearchForInstances) super.setUploadType(uploadType); } @Override public SearchForInstances setUploadProtocol(java.lang.String uploadProtocol) { return (SearchForInstances) super.setUploadProtocol(uploadProtocol); } /** * The name of the DICOM store that is being accessed. For example, `projects/{project * _id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_store_id}`. */ @com.google.api.client.util.Key private java.lang.String parent; /** The name of the DICOM store that is being accessed. For example, `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_store_id}`. */ public java.lang.String getParent() { return parent; } /** * The name of the DICOM store that is being accessed. For example, `projects/{project * _id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_store_id}`. */ public SearchForInstances setParent(java.lang.String parent) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), "Parameter parent must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dicomStores/[^/]+$"); } this.parent = parent; return this; } /** * The path of the SearchForInstancesRequest DICOMweb request. For example, * `instances`, `series/{series_uid}/instances`, or `studies/{study_uid}/instances`. */ @com.google.api.client.util.Key private java.lang.String dicomWebPath; /** The path of the SearchForInstancesRequest DICOMweb request. For example, `instances`, `series/{series_uid}/instances`, or `studies/{study_uid}/instances`. */ public java.lang.String getDicomWebPath() { return dicomWebPath; } /** * The path of the SearchForInstancesRequest DICOMweb request. For example, * `instances`, `series/{series_uid}/instances`, or `studies/{study_uid}/instances`. */ public SearchForInstances setDicomWebPath(java.lang.String dicomWebPath) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(DICOM_WEB_PATH_PATTERN.matcher(dicomWebPath).matches(), "Parameter dicomWebPath must conform to the pattern " + "^studies/[^/]+/instances$"); } this.dicomWebPath = dicomWebPath; return this; } @Override public SearchForInstances set(String parameterName, Object value) { return (SearchForInstances) super.set(parameterName, value); } } /** * SearchForSeries returns a list of matching series. See * http://dicom.nema.org/medical/dicom/current/output/html/part18.html#sect_10.6. * * Create a request for the method "studies.searchForSeries". * * This request holds the parameters needed by the healthcare server. After setting any optional * parameters, call the {@link SearchForSeries#execute()} method to invoke the remote operation. * * @param parent The name of the DICOM store that is being accessed. For example, * `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_st * ore_id}`. * @param dicomWebPath The path of the SearchForSeries DICOMweb request. For example, `series` or * `studies/{study_uid}/series`. * @return the request */ public SearchForSeries searchForSeries(java.lang.String parent, java.lang.String dicomWebPath) throws java.io.IOException { SearchForSeries result = new SearchForSeries(parent, dicomWebPath); initialize(result); return result; } public class SearchForSeries extends CloudHealthcareRequest<com.google.api.services.healthcare.v1beta1.model.HttpBody> { private static final String REST_PATH = "v1beta1/{+parent}/dicomWeb/{+dicomWebPath}"; private final java.util.regex.Pattern PARENT_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dicomStores/[^/]+$"); private final java.util.regex.Pattern DICOM_WEB_PATH_PATTERN = java.util.regex.Pattern.compile("^studies/[^/]+/series$"); /** * SearchForSeries returns a list of matching series. See * http://dicom.nema.org/medical/dicom/current/output/html/part18.html#sect_10.6. * * Create a request for the method "studies.searchForSeries". * * This request holds the parameters needed by the the healthcare server. After setting any * optional parameters, call the {@link SearchForSeries#execute()} method to invoke the remote * operation. <p> {@link SearchForSeries#initialize(com.google.api.client.googleapis.services.Abst * ractGoogleClientRequest)} must be called to initialize this instance immediately after invoking * the constructor. </p> * * @param parent The name of the DICOM store that is being accessed. For example, * `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_st * ore_id}`. * @param dicomWebPath The path of the SearchForSeries DICOMweb request. For example, `series` or * `studies/{study_uid}/series`. * @since 1.13 */ protected SearchForSeries(java.lang.String parent, java.lang.String dicomWebPath) { super(CloudHealthcare.this, "GET", REST_PATH, null, com.google.api.services.healthcare.v1beta1.model.HttpBody.class); this.parent = com.google.api.client.util.Preconditions.checkNotNull(parent, "Required parameter parent must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), "Parameter parent must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dicomStores/[^/]+$"); } this.dicomWebPath = com.google.api.client.util.Preconditions.checkNotNull(dicomWebPath, "Required parameter dicomWebPath must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(DICOM_WEB_PATH_PATTERN.matcher(dicomWebPath).matches(), "Parameter dicomWebPath must conform to the pattern " + "^studies/[^/]+/series$"); } } @Override public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException { return super.executeUsingHead(); } @Override public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException { return super.buildHttpRequestUsingHead(); } @Override public SearchForSeries set$Xgafv(java.lang.String $Xgafv) { return (SearchForSeries) super.set$Xgafv($Xgafv); } @Override public SearchForSeries setAccessToken(java.lang.String accessToken) { return (SearchForSeries) super.setAccessToken(accessToken); } @Override public SearchForSeries setAlt(java.lang.String alt) { return (SearchForSeries) super.setAlt(alt); } @Override public SearchForSeries setCallback(java.lang.String callback) { return (SearchForSeries) super.setCallback(callback); } @Override public SearchForSeries setFields(java.lang.String fields) { return (SearchForSeries) super.setFields(fields); } @Override public SearchForSeries setKey(java.lang.String key) { return (SearchForSeries) super.setKey(key); } @Override public SearchForSeries setOauthToken(java.lang.String oauthToken) { return (SearchForSeries) super.setOauthToken(oauthToken); } @Override public SearchForSeries setPrettyPrint(java.lang.Boolean prettyPrint) { return (SearchForSeries) super.setPrettyPrint(prettyPrint); } @Override public SearchForSeries setQuotaUser(java.lang.String quotaUser) { return (SearchForSeries) super.setQuotaUser(quotaUser); } @Override public SearchForSeries setUploadType(java.lang.String uploadType) { return (SearchForSeries) super.setUploadType(uploadType); } @Override public SearchForSeries setUploadProtocol(java.lang.String uploadProtocol) { return (SearchForSeries) super.setUploadProtocol(uploadProtocol); } /** * The name of the DICOM store that is being accessed. For example, `projects/{project * _id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_store_id}`. */ @com.google.api.client.util.Key private java.lang.String parent; /** The name of the DICOM store that is being accessed. For example, `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_store_id}`. */ public java.lang.String getParent() { return parent; } /** * The name of the DICOM store that is being accessed. For example, `projects/{project * _id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_store_id}`. */ public SearchForSeries setParent(java.lang.String parent) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), "Parameter parent must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dicomStores/[^/]+$"); } this.parent = parent; return this; } /** * The path of the SearchForSeries DICOMweb request. For example, `series` or * `studies/{study_uid}/series`. */ @com.google.api.client.util.Key private java.lang.String dicomWebPath; /** The path of the SearchForSeries DICOMweb request. For example, `series` or `studies/{study_uid}/series`. */ public java.lang.String getDicomWebPath() { return dicomWebPath; } /** * The path of the SearchForSeries DICOMweb request. For example, `series` or * `studies/{study_uid}/series`. */ public SearchForSeries setDicomWebPath(java.lang.String dicomWebPath) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(DICOM_WEB_PATH_PATTERN.matcher(dicomWebPath).matches(), "Parameter dicomWebPath must conform to the pattern " + "^studies/[^/]+/series$"); } this.dicomWebPath = dicomWebPath; return this; } @Override public SearchForSeries set(String parameterName, Object value) { return (SearchForSeries) super.set(parameterName, value); } } /** * StoreInstances stores DICOM instances associated with study instance unique identifiers (SUID). * See http://dicom.nema.org/medical/dicom/current/output/html/part18.html#sect_10.5. * * Create a request for the method "studies.storeInstances". * * This request holds the parameters needed by the healthcare server. After setting any optional * parameters, call the {@link StoreInstances#execute()} method to invoke the remote operation. * * @param parent The name of the DICOM store that is being accessed. For example, * `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_st * ore_id}`. * @param dicomWebPath The path of the StoreInstances DICOMweb request. For example, `studies/[{study_uid}]`. Note that the * `study_uid` is optional. * @param content the {@link com.google.api.services.healthcare.v1beta1.model.HttpBody} * @return the request */ public StoreInstances storeInstances(java.lang.String parent, java.lang.String dicomWebPath, com.google.api.services.healthcare.v1beta1.model.HttpBody content) throws java.io.IOException { StoreInstances result = new StoreInstances(parent, dicomWebPath, content); initialize(result); return result; } public class StoreInstances extends CloudHealthcareRequest<com.google.api.services.healthcare.v1beta1.model.HttpBody> { private static final String REST_PATH = "v1beta1/{+parent}/dicomWeb/{+dicomWebPath}"; private final java.util.regex.Pattern PARENT_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dicomStores/[^/]+$"); private final java.util.regex.Pattern DICOM_WEB_PATH_PATTERN = java.util.regex.Pattern.compile("^studies/[^/]+$"); /** * StoreInstances stores DICOM instances associated with study instance unique identifiers (SUID). * See http://dicom.nema.org/medical/dicom/current/output/html/part18.html#sect_10.5. * * Create a request for the method "studies.storeInstances". * * This request holds the parameters needed by the the healthcare server. After setting any * optional parameters, call the {@link StoreInstances#execute()} method to invoke the remote * operation. <p> {@link StoreInstances#initialize(com.google.api.client.googleapis.services.Abstr * actGoogleClientRequest)} must be called to initialize this instance immediately after invoking * the constructor. </p> * * @param parent The name of the DICOM store that is being accessed. For example, * `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_st * ore_id}`. * @param dicomWebPath The path of the StoreInstances DICOMweb request. For example, `studies/[{study_uid}]`. Note that the * `study_uid` is optional. * @param content the {@link com.google.api.services.healthcare.v1beta1.model.HttpBody} * @since 1.13 */ protected StoreInstances(java.lang.String parent, java.lang.String dicomWebPath, com.google.api.services.healthcare.v1beta1.model.HttpBody content) { super(CloudHealthcare.this, "POST", REST_PATH, content, com.google.api.services.healthcare.v1beta1.model.HttpBody.class); this.parent = com.google.api.client.util.Preconditions.checkNotNull(parent, "Required parameter parent must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), "Parameter parent must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dicomStores/[^/]+$"); } this.dicomWebPath = com.google.api.client.util.Preconditions.checkNotNull(dicomWebPath, "Required parameter dicomWebPath must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(DICOM_WEB_PATH_PATTERN.matcher(dicomWebPath).matches(), "Parameter dicomWebPath must conform to the pattern " + "^studies/[^/]+$"); } } @Override public StoreInstances set$Xgafv(java.lang.String $Xgafv) { return (StoreInstances) super.set$Xgafv($Xgafv); } @Override public StoreInstances setAccessToken(java.lang.String accessToken) { return (StoreInstances) super.setAccessToken(accessToken); } @Override public StoreInstances setAlt(java.lang.String alt) { return (StoreInstances) super.setAlt(alt); } @Override public StoreInstances setCallback(java.lang.String callback) { return (StoreInstances) super.setCallback(callback); } @Override public StoreInstances setFields(java.lang.String fields) { return (StoreInstances) super.setFields(fields); } @Override public StoreInstances setKey(java.lang.String key) { return (StoreInstances) super.setKey(key); } @Override public StoreInstances setOauthToken(java.lang.String oauthToken) { return (StoreInstances) super.setOauthToken(oauthToken); } @Override public StoreInstances setPrettyPrint(java.lang.Boolean prettyPrint) { return (StoreInstances) super.setPrettyPrint(prettyPrint); } @Override public StoreInstances setQuotaUser(java.lang.String quotaUser) { return (StoreInstances) super.setQuotaUser(quotaUser); } @Override public StoreInstances setUploadType(java.lang.String uploadType) { return (StoreInstances) super.setUploadType(uploadType); } @Override public StoreInstances setUploadProtocol(java.lang.String uploadProtocol) { return (StoreInstances) super.setUploadProtocol(uploadProtocol); } /** * The name of the DICOM store that is being accessed. For example, `projects/{project * _id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_store_id}`. */ @com.google.api.client.util.Key private java.lang.String parent; /** The name of the DICOM store that is being accessed. For example, `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_store_id}`. */ public java.lang.String getParent() { return parent; } /** * The name of the DICOM store that is being accessed. For example, `projects/{project * _id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_store_id}`. */ public StoreInstances setParent(java.lang.String parent) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), "Parameter parent must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dicomStores/[^/]+$"); } this.parent = parent; return this; } /** * The path of the StoreInstances DICOMweb request. For example, * `studies/[{study_uid}]`. Note that the `study_uid` is optional. */ @com.google.api.client.util.Key private java.lang.String dicomWebPath; /** The path of the StoreInstances DICOMweb request. For example, `studies/[{study_uid}]`. Note that the `study_uid` is optional. */ public java.lang.String getDicomWebPath() { return dicomWebPath; } /** * The path of the StoreInstances DICOMweb request. For example, * `studies/[{study_uid}]`. Note that the `study_uid` is optional. */ public StoreInstances setDicomWebPath(java.lang.String dicomWebPath) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(DICOM_WEB_PATH_PATTERN.matcher(dicomWebPath).matches(), "Parameter dicomWebPath must conform to the pattern " + "^studies/[^/]+$"); } this.dicomWebPath = dicomWebPath; return this; } @Override public StoreInstances set(String parameterName, Object value) { return (StoreInstances) super.set(parameterName, value); } } /** * An accessor for creating requests from the Series collection. * * <p>The typical use is:</p> * <pre> * {@code CloudHealthcare healthcare = new CloudHealthcare(...);} * {@code CloudHealthcare.Series.List request = healthcare.series().list(parameters ...)} * </pre> * * @return the resource collection */ public Series series() { return new Series(); } /** * The "series" collection of methods. */ public class Series { /** * DeleteSeries deletes all instances within the given study and series. Delete requests are * equivalent to the GET requests specified in the WADO-RS standard. * * Create a request for the method "series.delete". * * This request holds the parameters needed by the healthcare server. After setting any optional * parameters, call the {@link Delete#execute()} method to invoke the remote operation. * * @param parent The name of the DICOM store that is being accessed. For example, * `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_st * ore_id}`. * @param dicomWebPath The path of the DeleteSeries request. For example, `studies/{study_uid}/series/{series_uid}`. * @return the request */ public Delete delete(java.lang.String parent, java.lang.String dicomWebPath) throws java.io.IOException { Delete result = new Delete(parent, dicomWebPath); initialize(result); return result; } public class Delete extends CloudHealthcareRequest<com.google.api.services.healthcare.v1beta1.model.Empty> { private static final String REST_PATH = "v1beta1/{+parent}/dicomWeb/{+dicomWebPath}"; private final java.util.regex.Pattern PARENT_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dicomStores/[^/]+$"); private final java.util.regex.Pattern DICOM_WEB_PATH_PATTERN = java.util.regex.Pattern.compile("^studies/[^/]+/series/[^/]+$"); /** * DeleteSeries deletes all instances within the given study and series. Delete requests are * equivalent to the GET requests specified in the WADO-RS standard. * * Create a request for the method "series.delete". * * This request holds the parameters needed by the the healthcare server. After setting any * optional parameters, call the {@link Delete#execute()} method to invoke the remote operation. * <p> {@link * Delete#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} must * be called to initialize this instance immediately after invoking the constructor. </p> * * @param parent The name of the DICOM store that is being accessed. For example, * `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_st * ore_id}`. * @param dicomWebPath The path of the DeleteSeries request. For example, `studies/{study_uid}/series/{series_uid}`. * @since 1.13 */ protected Delete(java.lang.String parent, java.lang.String dicomWebPath) { super(CloudHealthcare.this, "DELETE", REST_PATH, null, com.google.api.services.healthcare.v1beta1.model.Empty.class); this.parent = com.google.api.client.util.Preconditions.checkNotNull(parent, "Required parameter parent must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), "Parameter parent must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dicomStores/[^/]+$"); } this.dicomWebPath = com.google.api.client.util.Preconditions.checkNotNull(dicomWebPath, "Required parameter dicomWebPath must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(DICOM_WEB_PATH_PATTERN.matcher(dicomWebPath).matches(), "Parameter dicomWebPath must conform to the pattern " + "^studies/[^/]+/series/[^/]+$"); } } @Override public Delete set$Xgafv(java.lang.String $Xgafv) { return (Delete) super.set$Xgafv($Xgafv); } @Override public Delete setAccessToken(java.lang.String accessToken) { return (Delete) super.setAccessToken(accessToken); } @Override public Delete setAlt(java.lang.String alt) { return (Delete) super.setAlt(alt); } @Override public Delete setCallback(java.lang.String callback) { return (Delete) super.setCallback(callback); } @Override public Delete setFields(java.lang.String fields) { return (Delete) super.setFields(fields); } @Override public Delete setKey(java.lang.String key) { return (Delete) super.setKey(key); } @Override public Delete setOauthToken(java.lang.String oauthToken) { return (Delete) super.setOauthToken(oauthToken); } @Override public Delete setPrettyPrint(java.lang.Boolean prettyPrint) { return (Delete) super.setPrettyPrint(prettyPrint); } @Override public Delete setQuotaUser(java.lang.String quotaUser) { return (Delete) super.setQuotaUser(quotaUser); } @Override public Delete setUploadType(java.lang.String uploadType) { return (Delete) super.setUploadType(uploadType); } @Override public Delete setUploadProtocol(java.lang.String uploadProtocol) { return (Delete) super.setUploadProtocol(uploadProtocol); } /** * The name of the DICOM store that is being accessed. For example, `projects/{proje * ct_id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_store_id} * `. */ @com.google.api.client.util.Key private java.lang.String parent; /** The name of the DICOM store that is being accessed. For example, `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_store_id}`. */ public java.lang.String getParent() { return parent; } /** * The name of the DICOM store that is being accessed. For example, `projects/{proje * ct_id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_store_id} * `. */ public Delete setParent(java.lang.String parent) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), "Parameter parent must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dicomStores/[^/]+$"); } this.parent = parent; return this; } /** * The path of the DeleteSeries request. For example, * `studies/{study_uid}/series/{series_uid}`. */ @com.google.api.client.util.Key private java.lang.String dicomWebPath; /** The path of the DeleteSeries request. For example, `studies/{study_uid}/series/{series_uid}`. */ public java.lang.String getDicomWebPath() { return dicomWebPath; } /** * The path of the DeleteSeries request. For example, * `studies/{study_uid}/series/{series_uid}`. */ public Delete setDicomWebPath(java.lang.String dicomWebPath) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(DICOM_WEB_PATH_PATTERN.matcher(dicomWebPath).matches(), "Parameter dicomWebPath must conform to the pattern " + "^studies/[^/]+/series/[^/]+$"); } this.dicomWebPath = dicomWebPath; return this; } @Override public Delete set(String parameterName, Object value) { return (Delete) super.set(parameterName, value); } } /** * RetrieveSeriesMetadata returns instance associated with the given study and series, presented as * metadata with the bulk data removed. See * http://dicom.nema.org/medical/dicom/current/output/html/part18.html#sect_10.4. * * Create a request for the method "series.retrieveMetadata". * * This request holds the parameters needed by the healthcare server. After setting any optional * parameters, call the {@link RetrieveMetadata#execute()} method to invoke the remote operation. * * @param parent The name of the DICOM store that is being accessed. For example, * `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_st * ore_id}`. * @param dicomWebPath The path of the RetrieveSeriesMetadata DICOMweb request. For example, * `studies/{study_uid}/series/{series_uid}/metadata`. * @return the request */ public RetrieveMetadata retrieveMetadata(java.lang.String parent, java.lang.String dicomWebPath) throws java.io.IOException { RetrieveMetadata result = new RetrieveMetadata(parent, dicomWebPath); initialize(result); return result; } public class RetrieveMetadata extends CloudHealthcareRequest<com.google.api.services.healthcare.v1beta1.model.HttpBody> { private static final String REST_PATH = "v1beta1/{+parent}/dicomWeb/{+dicomWebPath}"; private final java.util.regex.Pattern PARENT_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dicomStores/[^/]+$"); private final java.util.regex.Pattern DICOM_WEB_PATH_PATTERN = java.util.regex.Pattern.compile("^studies/[^/]+/series/[^/]+/metadata$"); /** * RetrieveSeriesMetadata returns instance associated with the given study and series, presented * as metadata with the bulk data removed. See * http://dicom.nema.org/medical/dicom/current/output/html/part18.html#sect_10.4. * * Create a request for the method "series.retrieveMetadata". * * This request holds the parameters needed by the the healthcare server. After setting any * optional parameters, call the {@link RetrieveMetadata#execute()} method to invoke the remote * operation. <p> {@link RetrieveMetadata#initialize(com.google.api.client.googleapis.services.Abs * tractGoogleClientRequest)} must be called to initialize this instance immediately after * invoking the constructor. </p> * * @param parent The name of the DICOM store that is being accessed. For example, * `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_st * ore_id}`. * @param dicomWebPath The path of the RetrieveSeriesMetadata DICOMweb request. For example, * `studies/{study_uid}/series/{series_uid}/metadata`. * @since 1.13 */ protected RetrieveMetadata(java.lang.String parent, java.lang.String dicomWebPath) { super(CloudHealthcare.this, "GET", REST_PATH, null, com.google.api.services.healthcare.v1beta1.model.HttpBody.class); this.parent = com.google.api.client.util.Preconditions.checkNotNull(parent, "Required parameter parent must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), "Parameter parent must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dicomStores/[^/]+$"); } this.dicomWebPath = com.google.api.client.util.Preconditions.checkNotNull(dicomWebPath, "Required parameter dicomWebPath must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(DICOM_WEB_PATH_PATTERN.matcher(dicomWebPath).matches(), "Parameter dicomWebPath must conform to the pattern " + "^studies/[^/]+/series/[^/]+/metadata$"); } } @Override public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException { return super.executeUsingHead(); } @Override public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException { return super.buildHttpRequestUsingHead(); } @Override public RetrieveMetadata set$Xgafv(java.lang.String $Xgafv) { return (RetrieveMetadata) super.set$Xgafv($Xgafv); } @Override public RetrieveMetadata setAccessToken(java.lang.String accessToken) { return (RetrieveMetadata) super.setAccessToken(accessToken); } @Override public RetrieveMetadata setAlt(java.lang.String alt) { return (RetrieveMetadata) super.setAlt(alt); } @Override public RetrieveMetadata setCallback(java.lang.String callback) { return (RetrieveMetadata) super.setCallback(callback); } @Override public RetrieveMetadata setFields(java.lang.String fields) { return (RetrieveMetadata) super.setFields(fields); } @Override public RetrieveMetadata setKey(java.lang.String key) { return (RetrieveMetadata) super.setKey(key); } @Override public RetrieveMetadata setOauthToken(java.lang.String oauthToken) { return (RetrieveMetadata) super.setOauthToken(oauthToken); } @Override public RetrieveMetadata setPrettyPrint(java.lang.Boolean prettyPrint) { return (RetrieveMetadata) super.setPrettyPrint(prettyPrint); } @Override public RetrieveMetadata setQuotaUser(java.lang.String quotaUser) { return (RetrieveMetadata) super.setQuotaUser(quotaUser); } @Override public RetrieveMetadata setUploadType(java.lang.String uploadType) { return (RetrieveMetadata) super.setUploadType(uploadType); } @Override public RetrieveMetadata setUploadProtocol(java.lang.String uploadProtocol) { return (RetrieveMetadata) super.setUploadProtocol(uploadProtocol); } /** * The name of the DICOM store that is being accessed. For example, `projects/{proje * ct_id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_store_id} * `. */ @com.google.api.client.util.Key private java.lang.String parent; /** The name of the DICOM store that is being accessed. For example, `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_store_id}`. */ public java.lang.String getParent() { return parent; } /** * The name of the DICOM store that is being accessed. For example, `projects/{proje * ct_id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_store_id} * `. */ public RetrieveMetadata setParent(java.lang.String parent) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), "Parameter parent must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dicomStores/[^/]+$"); } this.parent = parent; return this; } /** * The path of the RetrieveSeriesMetadata DICOMweb request. For example, * `studies/{study_uid}/series/{series_uid}/metadata`. */ @com.google.api.client.util.Key private java.lang.String dicomWebPath; /** The path of the RetrieveSeriesMetadata DICOMweb request. For example, `studies/{study_uid}/series/{series_uid}/metadata`. */ public java.lang.String getDicomWebPath() { return dicomWebPath; } /** * The path of the RetrieveSeriesMetadata DICOMweb request. For example, * `studies/{study_uid}/series/{series_uid}/metadata`. */ public RetrieveMetadata setDicomWebPath(java.lang.String dicomWebPath) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(DICOM_WEB_PATH_PATTERN.matcher(dicomWebPath).matches(), "Parameter dicomWebPath must conform to the pattern " + "^studies/[^/]+/series/[^/]+/metadata$"); } this.dicomWebPath = dicomWebPath; return this; } @Override public RetrieveMetadata set(String parameterName, Object value) { return (RetrieveMetadata) super.set(parameterName, value); } } /** * RetrieveSeries returns all instances within the given study and series. See * http://dicom.nema.org/medical/dicom/current/output/html/part18.html#sect_10.4. * * Create a request for the method "series.retrieveSeries". * * This request holds the parameters needed by the healthcare server. After setting any optional * parameters, call the {@link RetrieveSeries#execute()} method to invoke the remote operation. * * @param parent The name of the DICOM store that is being accessed. For example, * `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_st * ore_id}`. * @param dicomWebPath The path of the RetrieveSeries DICOMweb request. For example, * `studies/{study_uid}/series/{series_uid}`. * @return the request */ public RetrieveSeries retrieveSeries(java.lang.String parent, java.lang.String dicomWebPath) throws java.io.IOException { RetrieveSeries result = new RetrieveSeries(parent, dicomWebPath); initialize(result); return result; } public class RetrieveSeries extends CloudHealthcareRequest<com.google.api.services.healthcare.v1beta1.model.HttpBody> { private static final String REST_PATH = "v1beta1/{+parent}/dicomWeb/{+dicomWebPath}"; private final java.util.regex.Pattern PARENT_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dicomStores/[^/]+$"); private final java.util.regex.Pattern DICOM_WEB_PATH_PATTERN = java.util.regex.Pattern.compile("^studies/[^/]+/series/[^/]+$"); /** * RetrieveSeries returns all instances within the given study and series. See * http://dicom.nema.org/medical/dicom/current/output/html/part18.html#sect_10.4. * * Create a request for the method "series.retrieveSeries". * * This request holds the parameters needed by the the healthcare server. After setting any * optional parameters, call the {@link RetrieveSeries#execute()} method to invoke the remote * operation. <p> {@link RetrieveSeries#initialize(com.google.api.client.googleapis.services.Abstr * actGoogleClientRequest)} must be called to initialize this instance immediately after invoking * the constructor. </p> * * @param parent The name of the DICOM store that is being accessed. For example, * `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_st * ore_id}`. * @param dicomWebPath The path of the RetrieveSeries DICOMweb request. For example, * `studies/{study_uid}/series/{series_uid}`. * @since 1.13 */ protected RetrieveSeries(java.lang.String parent, java.lang.String dicomWebPath) { super(CloudHealthcare.this, "GET", REST_PATH, null, com.google.api.services.healthcare.v1beta1.model.HttpBody.class); this.parent = com.google.api.client.util.Preconditions.checkNotNull(parent, "Required parameter parent must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), "Parameter parent must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dicomStores/[^/]+$"); } this.dicomWebPath = com.google.api.client.util.Preconditions.checkNotNull(dicomWebPath, "Required parameter dicomWebPath must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(DICOM_WEB_PATH_PATTERN.matcher(dicomWebPath).matches(), "Parameter dicomWebPath must conform to the pattern " + "^studies/[^/]+/series/[^/]+$"); } } @Override public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException { return super.executeUsingHead(); } @Override public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException { return super.buildHttpRequestUsingHead(); } @Override public RetrieveSeries set$Xgafv(java.lang.String $Xgafv) { return (RetrieveSeries) super.set$Xgafv($Xgafv); } @Override public RetrieveSeries setAccessToken(java.lang.String accessToken) { return (RetrieveSeries) super.setAccessToken(accessToken); } @Override public RetrieveSeries setAlt(java.lang.String alt) { return (RetrieveSeries) super.setAlt(alt); } @Override public RetrieveSeries setCallback(java.lang.String callback) { return (RetrieveSeries) super.setCallback(callback); } @Override public RetrieveSeries setFields(java.lang.String fields) { return (RetrieveSeries) super.setFields(fields); } @Override public RetrieveSeries setKey(java.lang.String key) { return (RetrieveSeries) super.setKey(key); } @Override public RetrieveSeries setOauthToken(java.lang.String oauthToken) { return (RetrieveSeries) super.setOauthToken(oauthToken); } @Override public RetrieveSeries setPrettyPrint(java.lang.Boolean prettyPrint) { return (RetrieveSeries) super.setPrettyPrint(prettyPrint); } @Override public RetrieveSeries setQuotaUser(java.lang.String quotaUser) { return (RetrieveSeries) super.setQuotaUser(quotaUser); } @Override public RetrieveSeries setUploadType(java.lang.String uploadType) { return (RetrieveSeries) super.setUploadType(uploadType); } @Override public RetrieveSeries setUploadProtocol(java.lang.String uploadProtocol) { return (RetrieveSeries) super.setUploadProtocol(uploadProtocol); } /** * The name of the DICOM store that is being accessed. For example, `projects/{proje * ct_id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_store_id} * `. */ @com.google.api.client.util.Key private java.lang.String parent; /** The name of the DICOM store that is being accessed. For example, `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_store_id}`. */ public java.lang.String getParent() { return parent; } /** * The name of the DICOM store that is being accessed. For example, `projects/{proje * ct_id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_store_id} * `. */ public RetrieveSeries setParent(java.lang.String parent) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), "Parameter parent must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dicomStores/[^/]+$"); } this.parent = parent; return this; } /** * The path of the RetrieveSeries DICOMweb request. For example, * `studies/{study_uid}/series/{series_uid}`. */ @com.google.api.client.util.Key private java.lang.String dicomWebPath; /** The path of the RetrieveSeries DICOMweb request. For example, `studies/{study_uid}/series/{series_uid}`. */ public java.lang.String getDicomWebPath() { return dicomWebPath; } /** * The path of the RetrieveSeries DICOMweb request. For example, * `studies/{study_uid}/series/{series_uid}`. */ public RetrieveSeries setDicomWebPath(java.lang.String dicomWebPath) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(DICOM_WEB_PATH_PATTERN.matcher(dicomWebPath).matches(), "Parameter dicomWebPath must conform to the pattern " + "^studies/[^/]+/series/[^/]+$"); } this.dicomWebPath = dicomWebPath; return this; } @Override public RetrieveSeries set(String parameterName, Object value) { return (RetrieveSeries) super.set(parameterName, value); } } /** * SearchForInstances returns a list of matching instances. See * http://dicom.nema.org/medical/dicom/current/output/html/part18.html#sect_10.6. * * Create a request for the method "series.searchForInstances". * * This request holds the parameters needed by the healthcare server. After setting any optional * parameters, call the {@link SearchForInstances#execute()} method to invoke the remote operation. * * @param parent The name of the DICOM store that is being accessed. For example, * `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_st * ore_id}`. * @param dicomWebPath The path of the SearchForInstancesRequest DICOMweb request. For example, `instances`, * `series/{series_uid}/instances`, or `studies/{study_uid}/instances`. * @return the request */ public SearchForInstances searchForInstances(java.lang.String parent, java.lang.String dicomWebPath) throws java.io.IOException { SearchForInstances result = new SearchForInstances(parent, dicomWebPath); initialize(result); return result; } public class SearchForInstances extends CloudHealthcareRequest<com.google.api.services.healthcare.v1beta1.model.HttpBody> { private static final String REST_PATH = "v1beta1/{+parent}/dicomWeb/{+dicomWebPath}"; private final java.util.regex.Pattern PARENT_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dicomStores/[^/]+$"); private final java.util.regex.Pattern DICOM_WEB_PATH_PATTERN = java.util.regex.Pattern.compile("^studies/[^/]+/series/[^/]+/instances$"); /** * SearchForInstances returns a list of matching instances. See * http://dicom.nema.org/medical/dicom/current/output/html/part18.html#sect_10.6. * * Create a request for the method "series.searchForInstances". * * This request holds the parameters needed by the the healthcare server. After setting any * optional parameters, call the {@link SearchForInstances#execute()} method to invoke the remote * operation. <p> {@link SearchForInstances#initialize(com.google.api.client.googleapis.services.A * bstractGoogleClientRequest)} must be called to initialize this instance immediately after * invoking the constructor. </p> * * @param parent The name of the DICOM store that is being accessed. For example, * `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_st * ore_id}`. * @param dicomWebPath The path of the SearchForInstancesRequest DICOMweb request. For example, `instances`, * `series/{series_uid}/instances`, or `studies/{study_uid}/instances`. * @since 1.13 */ protected SearchForInstances(java.lang.String parent, java.lang.String dicomWebPath) { super(CloudHealthcare.this, "GET", REST_PATH, null, com.google.api.services.healthcare.v1beta1.model.HttpBody.class); this.parent = com.google.api.client.util.Preconditions.checkNotNull(parent, "Required parameter parent must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), "Parameter parent must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dicomStores/[^/]+$"); } this.dicomWebPath = com.google.api.client.util.Preconditions.checkNotNull(dicomWebPath, "Required parameter dicomWebPath must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(DICOM_WEB_PATH_PATTERN.matcher(dicomWebPath).matches(), "Parameter dicomWebPath must conform to the pattern " + "^studies/[^/]+/series/[^/]+/instances$"); } } @Override public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException { return super.executeUsingHead(); } @Override public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException { return super.buildHttpRequestUsingHead(); } @Override public SearchForInstances set$Xgafv(java.lang.String $Xgafv) { return (SearchForInstances) super.set$Xgafv($Xgafv); } @Override public SearchForInstances setAccessToken(java.lang.String accessToken) { return (SearchForInstances) super.setAccessToken(accessToken); } @Override public SearchForInstances setAlt(java.lang.String alt) { return (SearchForInstances) super.setAlt(alt); } @Override public SearchForInstances setCallback(java.lang.String callback) { return (SearchForInstances) super.setCallback(callback); } @Override public SearchForInstances setFields(java.lang.String fields) { return (SearchForInstances) super.setFields(fields); } @Override public SearchForInstances setKey(java.lang.String key) { return (SearchForInstances) super.setKey(key); } @Override public SearchForInstances setOauthToken(java.lang.String oauthToken) { return (SearchForInstances) super.setOauthToken(oauthToken); } @Override public SearchForInstances setPrettyPrint(java.lang.Boolean prettyPrint) { return (SearchForInstances) super.setPrettyPrint(prettyPrint); } @Override public SearchForInstances setQuotaUser(java.lang.String quotaUser) { return (SearchForInstances) super.setQuotaUser(quotaUser); } @Override public SearchForInstances setUploadType(java.lang.String uploadType) { return (SearchForInstances) super.setUploadType(uploadType); } @Override public SearchForInstances setUploadProtocol(java.lang.String uploadProtocol) { return (SearchForInstances) super.setUploadProtocol(uploadProtocol); } /** * The name of the DICOM store that is being accessed. For example, `projects/{proje * ct_id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_store_id} * `. */ @com.google.api.client.util.Key private java.lang.String parent; /** The name of the DICOM store that is being accessed. For example, `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_store_id}`. */ public java.lang.String getParent() { return parent; } /** * The name of the DICOM store that is being accessed. For example, `projects/{proje * ct_id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_store_id} * `. */ public SearchForInstances setParent(java.lang.String parent) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), "Parameter parent must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dicomStores/[^/]+$"); } this.parent = parent; return this; } /** * The path of the SearchForInstancesRequest DICOMweb request. For example, * `instances`, `series/{series_uid}/instances`, or `studies/{study_uid}/instances`. */ @com.google.api.client.util.Key private java.lang.String dicomWebPath; /** The path of the SearchForInstancesRequest DICOMweb request. For example, `instances`, `series/{series_uid}/instances`, or `studies/{study_uid}/instances`. */ public java.lang.String getDicomWebPath() { return dicomWebPath; } /** * The path of the SearchForInstancesRequest DICOMweb request. For example, * `instances`, `series/{series_uid}/instances`, or `studies/{study_uid}/instances`. */ public SearchForInstances setDicomWebPath(java.lang.String dicomWebPath) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(DICOM_WEB_PATH_PATTERN.matcher(dicomWebPath).matches(), "Parameter dicomWebPath must conform to the pattern " + "^studies/[^/]+/series/[^/]+/instances$"); } this.dicomWebPath = dicomWebPath; return this; } @Override public SearchForInstances set(String parameterName, Object value) { return (SearchForInstances) super.set(parameterName, value); } } /** * An accessor for creating requests from the Instances collection. * * <p>The typical use is:</p> * <pre> * {@code CloudHealthcare healthcare = new CloudHealthcare(...);} * {@code CloudHealthcare.Instances.List request = healthcare.instances().list(parameters ...)} * </pre> * * @return the resource collection */ public Instances instances() { return new Instances(); } /** * The "instances" collection of methods. */ public class Instances { /** * DeleteInstance deletes an instance associated with the given study, series, and SOP Instance UID. * Delete requests are equivalent to the GET requests specified in the WADO-RS standard. * * Create a request for the method "instances.delete". * * This request holds the parameters needed by the healthcare server. After setting any optional * parameters, call the {@link Delete#execute()} method to invoke the remote operation. * * @param parent The name of the DICOM store that is being accessed. For example, * `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_st * ore_id}`. * @param dicomWebPath The path of the DeleteInstance request. For example, * `studies/{study_uid}/series/{series_uid}/instances/{instance_uid}`. * @return the request */ public Delete delete(java.lang.String parent, java.lang.String dicomWebPath) throws java.io.IOException { Delete result = new Delete(parent, dicomWebPath); initialize(result); return result; } public class Delete extends CloudHealthcareRequest<com.google.api.services.healthcare.v1beta1.model.Empty> { private static final String REST_PATH = "v1beta1/{+parent}/dicomWeb/{+dicomWebPath}"; private final java.util.regex.Pattern PARENT_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dicomStores/[^/]+$"); private final java.util.regex.Pattern DICOM_WEB_PATH_PATTERN = java.util.regex.Pattern.compile("^studies/[^/]+/series/[^/]+/instances/[^/]+$"); /** * DeleteInstance deletes an instance associated with the given study, series, and SOP Instance * UID. Delete requests are equivalent to the GET requests specified in the WADO-RS standard. * * Create a request for the method "instances.delete". * * This request holds the parameters needed by the the healthcare server. After setting any * optional parameters, call the {@link Delete#execute()} method to invoke the remote operation. * <p> {@link * Delete#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} must * be called to initialize this instance immediately after invoking the constructor. </p> * * @param parent The name of the DICOM store that is being accessed. For example, * `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_st * ore_id}`. * @param dicomWebPath The path of the DeleteInstance request. For example, * `studies/{study_uid}/series/{series_uid}/instances/{instance_uid}`. * @since 1.13 */ protected Delete(java.lang.String parent, java.lang.String dicomWebPath) { super(CloudHealthcare.this, "DELETE", REST_PATH, null, com.google.api.services.healthcare.v1beta1.model.Empty.class); this.parent = com.google.api.client.util.Preconditions.checkNotNull(parent, "Required parameter parent must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), "Parameter parent must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dicomStores/[^/]+$"); } this.dicomWebPath = com.google.api.client.util.Preconditions.checkNotNull(dicomWebPath, "Required parameter dicomWebPath must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(DICOM_WEB_PATH_PATTERN.matcher(dicomWebPath).matches(), "Parameter dicomWebPath must conform to the pattern " + "^studies/[^/]+/series/[^/]+/instances/[^/]+$"); } } @Override public Delete set$Xgafv(java.lang.String $Xgafv) { return (Delete) super.set$Xgafv($Xgafv); } @Override public Delete setAccessToken(java.lang.String accessToken) { return (Delete) super.setAccessToken(accessToken); } @Override public Delete setAlt(java.lang.String alt) { return (Delete) super.setAlt(alt); } @Override public Delete setCallback(java.lang.String callback) { return (Delete) super.setCallback(callback); } @Override public Delete setFields(java.lang.String fields) { return (Delete) super.setFields(fields); } @Override public Delete setKey(java.lang.String key) { return (Delete) super.setKey(key); } @Override public Delete setOauthToken(java.lang.String oauthToken) { return (Delete) super.setOauthToken(oauthToken); } @Override public Delete setPrettyPrint(java.lang.Boolean prettyPrint) { return (Delete) super.setPrettyPrint(prettyPrint); } @Override public Delete setQuotaUser(java.lang.String quotaUser) { return (Delete) super.setQuotaUser(quotaUser); } @Override public Delete setUploadType(java.lang.String uploadType) { return (Delete) super.setUploadType(uploadType); } @Override public Delete setUploadProtocol(java.lang.String uploadProtocol) { return (Delete) super.setUploadProtocol(uploadProtocol); } /** * The name of the DICOM store that is being accessed. For example, `projects/{pro * ject_id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_store * _id}`. */ @com.google.api.client.util.Key private java.lang.String parent; /** The name of the DICOM store that is being accessed. For example, `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_store_id}`. */ public java.lang.String getParent() { return parent; } /** * The name of the DICOM store that is being accessed. For example, `projects/{pro * ject_id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_store * _id}`. */ public Delete setParent(java.lang.String parent) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), "Parameter parent must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dicomStores/[^/]+$"); } this.parent = parent; return this; } /** * The path of the DeleteInstance request. For example, * `studies/{study_uid}/series/{series_uid}/instances/{instance_uid}`. */ @com.google.api.client.util.Key private java.lang.String dicomWebPath; /** The path of the DeleteInstance request. For example, `studies/{study_uid}/series/{series_uid}/instances/{instance_uid}`. */ public java.lang.String getDicomWebPath() { return dicomWebPath; } /** * The path of the DeleteInstance request. For example, * `studies/{study_uid}/series/{series_uid}/instances/{instance_uid}`. */ public Delete setDicomWebPath(java.lang.String dicomWebPath) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(DICOM_WEB_PATH_PATTERN.matcher(dicomWebPath).matches(), "Parameter dicomWebPath must conform to the pattern " + "^studies/[^/]+/series/[^/]+/instances/[^/]+$"); } this.dicomWebPath = dicomWebPath; return this; } @Override public Delete set(String parameterName, Object value) { return (Delete) super.set(parameterName, value); } } /** * RetrieveInstance returns instance associated with the given study, series, and SOP Instance UID. * See http://dicom.nema.org/medical/dicom/current/output/html/part18.html#sect_10.4. * * Create a request for the method "instances.retrieveInstance". * * This request holds the parameters needed by the healthcare server. After setting any optional * parameters, call the {@link RetrieveInstance#execute()} method to invoke the remote operation. * * @param parent The name of the DICOM store that is being accessed. For example, * `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_st * ore_id}`. * @param dicomWebPath The path of the RetrieveInstance DICOMweb request. For example, * `studies/{study_uid}/series/{series_uid}/instances/{instance_uid}`. * @return the request */ public RetrieveInstance retrieveInstance(java.lang.String parent, java.lang.String dicomWebPath) throws java.io.IOException { RetrieveInstance result = new RetrieveInstance(parent, dicomWebPath); initialize(result); return result; } public class RetrieveInstance extends CloudHealthcareRequest<com.google.api.services.healthcare.v1beta1.model.HttpBody> { private static final String REST_PATH = "v1beta1/{+parent}/dicomWeb/{+dicomWebPath}"; private final java.util.regex.Pattern PARENT_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dicomStores/[^/]+$"); private final java.util.regex.Pattern DICOM_WEB_PATH_PATTERN = java.util.regex.Pattern.compile("^studies/[^/]+/series/[^/]+/instances/[^/]+$"); /** * RetrieveInstance returns instance associated with the given study, series, and SOP Instance * UID. See http://dicom.nema.org/medical/dicom/current/output/html/part18.html#sect_10.4. * * Create a request for the method "instances.retrieveInstance". * * This request holds the parameters needed by the the healthcare server. After setting any * optional parameters, call the {@link RetrieveInstance#execute()} method to invoke the remote * operation. <p> {@link RetrieveInstance#initialize(com.google.api.client.googleapis.services.Abs * tractGoogleClientRequest)} must be called to initialize this instance immediately after * invoking the constructor. </p> * * @param parent The name of the DICOM store that is being accessed. For example, * `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_st * ore_id}`. * @param dicomWebPath The path of the RetrieveInstance DICOMweb request. For example, * `studies/{study_uid}/series/{series_uid}/instances/{instance_uid}`. * @since 1.13 */ protected RetrieveInstance(java.lang.String parent, java.lang.String dicomWebPath) { super(CloudHealthcare.this, "GET", REST_PATH, null, com.google.api.services.healthcare.v1beta1.model.HttpBody.class); this.parent = com.google.api.client.util.Preconditions.checkNotNull(parent, "Required parameter parent must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), "Parameter parent must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dicomStores/[^/]+$"); } this.dicomWebPath = com.google.api.client.util.Preconditions.checkNotNull(dicomWebPath, "Required parameter dicomWebPath must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(DICOM_WEB_PATH_PATTERN.matcher(dicomWebPath).matches(), "Parameter dicomWebPath must conform to the pattern " + "^studies/[^/]+/series/[^/]+/instances/[^/]+$"); } } @Override public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException { return super.executeUsingHead(); } @Override public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException { return super.buildHttpRequestUsingHead(); } @Override public RetrieveInstance set$Xgafv(java.lang.String $Xgafv) { return (RetrieveInstance) super.set$Xgafv($Xgafv); } @Override public RetrieveInstance setAccessToken(java.lang.String accessToken) { return (RetrieveInstance) super.setAccessToken(accessToken); } @Override public RetrieveInstance setAlt(java.lang.String alt) { return (RetrieveInstance) super.setAlt(alt); } @Override public RetrieveInstance setCallback(java.lang.String callback) { return (RetrieveInstance) super.setCallback(callback); } @Override public RetrieveInstance setFields(java.lang.String fields) { return (RetrieveInstance) super.setFields(fields); } @Override public RetrieveInstance setKey(java.lang.String key) { return (RetrieveInstance) super.setKey(key); } @Override public RetrieveInstance setOauthToken(java.lang.String oauthToken) { return (RetrieveInstance) super.setOauthToken(oauthToken); } @Override public RetrieveInstance setPrettyPrint(java.lang.Boolean prettyPrint) { return (RetrieveInstance) super.setPrettyPrint(prettyPrint); } @Override public RetrieveInstance setQuotaUser(java.lang.String quotaUser) { return (RetrieveInstance) super.setQuotaUser(quotaUser); } @Override public RetrieveInstance setUploadType(java.lang.String uploadType) { return (RetrieveInstance) super.setUploadType(uploadType); } @Override public RetrieveInstance setUploadProtocol(java.lang.String uploadProtocol) { return (RetrieveInstance) super.setUploadProtocol(uploadProtocol); } /** * The name of the DICOM store that is being accessed. For example, `projects/{pro * ject_id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_store * _id}`. */ @com.google.api.client.util.Key private java.lang.String parent; /** The name of the DICOM store that is being accessed. For example, `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_store_id}`. */ public java.lang.String getParent() { return parent; } /** * The name of the DICOM store that is being accessed. For example, `projects/{pro * ject_id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_store * _id}`. */ public RetrieveInstance setParent(java.lang.String parent) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), "Parameter parent must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dicomStores/[^/]+$"); } this.parent = parent; return this; } /** * The path of the RetrieveInstance DICOMweb request. For example, * `studies/{study_uid}/series/{series_uid}/instances/{instance_uid}`. */ @com.google.api.client.util.Key private java.lang.String dicomWebPath; /** The path of the RetrieveInstance DICOMweb request. For example, `studies/{study_uid}/series/{series_uid}/instances/{instance_uid}`. */ public java.lang.String getDicomWebPath() { return dicomWebPath; } /** * The path of the RetrieveInstance DICOMweb request. For example, * `studies/{study_uid}/series/{series_uid}/instances/{instance_uid}`. */ public RetrieveInstance setDicomWebPath(java.lang.String dicomWebPath) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(DICOM_WEB_PATH_PATTERN.matcher(dicomWebPath).matches(), "Parameter dicomWebPath must conform to the pattern " + "^studies/[^/]+/series/[^/]+/instances/[^/]+$"); } this.dicomWebPath = dicomWebPath; return this; } @Override public RetrieveInstance set(String parameterName, Object value) { return (RetrieveInstance) super.set(parameterName, value); } } /** * RetrieveInstanceMetadata returns instance associated with the given study, series, and SOP * Instance UID presented as metadata with the bulk data removed. See * http://dicom.nema.org/medical/dicom/current/output/html/part18.html#sect_10.4. * * Create a request for the method "instances.retrieveMetadata". * * This request holds the parameters needed by the healthcare server. After setting any optional * parameters, call the {@link RetrieveMetadata#execute()} method to invoke the remote operation. * * @param parent The name of the DICOM store that is being accessed. For example, * `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_st * ore_id}`. * @param dicomWebPath The path of the RetrieveInstanceMetadata DICOMweb request. For example, * `studies/{study_uid}/series/{series_uid}/instances/{instance_uid}/metadata`. * @return the request */ public RetrieveMetadata retrieveMetadata(java.lang.String parent, java.lang.String dicomWebPath) throws java.io.IOException { RetrieveMetadata result = new RetrieveMetadata(parent, dicomWebPath); initialize(result); return result; } public class RetrieveMetadata extends CloudHealthcareRequest<com.google.api.services.healthcare.v1beta1.model.HttpBody> { private static final String REST_PATH = "v1beta1/{+parent}/dicomWeb/{+dicomWebPath}"; private final java.util.regex.Pattern PARENT_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dicomStores/[^/]+$"); private final java.util.regex.Pattern DICOM_WEB_PATH_PATTERN = java.util.regex.Pattern.compile("^studies/[^/]+/series/[^/]+/instances/[^/]+/metadata$"); /** * RetrieveInstanceMetadata returns instance associated with the given study, series, and SOP * Instance UID presented as metadata with the bulk data removed. See * http://dicom.nema.org/medical/dicom/current/output/html/part18.html#sect_10.4. * * Create a request for the method "instances.retrieveMetadata". * * This request holds the parameters needed by the the healthcare server. After setting any * optional parameters, call the {@link RetrieveMetadata#execute()} method to invoke the remote * operation. <p> {@link RetrieveMetadata#initialize(com.google.api.client.googleapis.services.Abs * tractGoogleClientRequest)} must be called to initialize this instance immediately after * invoking the constructor. </p> * * @param parent The name of the DICOM store that is being accessed. For example, * `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_st * ore_id}`. * @param dicomWebPath The path of the RetrieveInstanceMetadata DICOMweb request. For example, * `studies/{study_uid}/series/{series_uid}/instances/{instance_uid}/metadata`. * @since 1.13 */ protected RetrieveMetadata(java.lang.String parent, java.lang.String dicomWebPath) { super(CloudHealthcare.this, "GET", REST_PATH, null, com.google.api.services.healthcare.v1beta1.model.HttpBody.class); this.parent = com.google.api.client.util.Preconditions.checkNotNull(parent, "Required parameter parent must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), "Parameter parent must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dicomStores/[^/]+$"); } this.dicomWebPath = com.google.api.client.util.Preconditions.checkNotNull(dicomWebPath, "Required parameter dicomWebPath must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(DICOM_WEB_PATH_PATTERN.matcher(dicomWebPath).matches(), "Parameter dicomWebPath must conform to the pattern " + "^studies/[^/]+/series/[^/]+/instances/[^/]+/metadata$"); } } @Override public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException { return super.executeUsingHead(); } @Override public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException { return super.buildHttpRequestUsingHead(); } @Override public RetrieveMetadata set$Xgafv(java.lang.String $Xgafv) { return (RetrieveMetadata) super.set$Xgafv($Xgafv); } @Override public RetrieveMetadata setAccessToken(java.lang.String accessToken) { return (RetrieveMetadata) super.setAccessToken(accessToken); } @Override public RetrieveMetadata setAlt(java.lang.String alt) { return (RetrieveMetadata) super.setAlt(alt); } @Override public RetrieveMetadata setCallback(java.lang.String callback) { return (RetrieveMetadata) super.setCallback(callback); } @Override public RetrieveMetadata setFields(java.lang.String fields) { return (RetrieveMetadata) super.setFields(fields); } @Override public RetrieveMetadata setKey(java.lang.String key) { return (RetrieveMetadata) super.setKey(key); } @Override public RetrieveMetadata setOauthToken(java.lang.String oauthToken) { return (RetrieveMetadata) super.setOauthToken(oauthToken); } @Override public RetrieveMetadata setPrettyPrint(java.lang.Boolean prettyPrint) { return (RetrieveMetadata) super.setPrettyPrint(prettyPrint); } @Override public RetrieveMetadata setQuotaUser(java.lang.String quotaUser) { return (RetrieveMetadata) super.setQuotaUser(quotaUser); } @Override public RetrieveMetadata setUploadType(java.lang.String uploadType) { return (RetrieveMetadata) super.setUploadType(uploadType); } @Override public RetrieveMetadata setUploadProtocol(java.lang.String uploadProtocol) { return (RetrieveMetadata) super.setUploadProtocol(uploadProtocol); } /** * The name of the DICOM store that is being accessed. For example, `projects/{pro * ject_id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_store * _id}`. */ @com.google.api.client.util.Key private java.lang.String parent; /** The name of the DICOM store that is being accessed. For example, `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_store_id}`. */ public java.lang.String getParent() { return parent; } /** * The name of the DICOM store that is being accessed. For example, `projects/{pro * ject_id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_store * _id}`. */ public RetrieveMetadata setParent(java.lang.String parent) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), "Parameter parent must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dicomStores/[^/]+$"); } this.parent = parent; return this; } /** * The path of the RetrieveInstanceMetadata DICOMweb request. For example, * `studies/{study_uid}/series/{series_uid}/instances/{instance_uid}/metadata`. */ @com.google.api.client.util.Key private java.lang.String dicomWebPath; /** The path of the RetrieveInstanceMetadata DICOMweb request. For example, `studies/{study_uid}/series/{series_uid}/instances/{instance_uid}/metadata`. */ public java.lang.String getDicomWebPath() { return dicomWebPath; } /** * The path of the RetrieveInstanceMetadata DICOMweb request. For example, * `studies/{study_uid}/series/{series_uid}/instances/{instance_uid}/metadata`. */ public RetrieveMetadata setDicomWebPath(java.lang.String dicomWebPath) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(DICOM_WEB_PATH_PATTERN.matcher(dicomWebPath).matches(), "Parameter dicomWebPath must conform to the pattern " + "^studies/[^/]+/series/[^/]+/instances/[^/]+/metadata$"); } this.dicomWebPath = dicomWebPath; return this; } @Override public RetrieveMetadata set(String parameterName, Object value) { return (RetrieveMetadata) super.set(parameterName, value); } } /** * RetrieveRenderedInstance returns instance associated with the given study, series, and SOP * Instance UID in an acceptable Rendered Media Type. See * http://dicom.nema.org/medical/dicom/current/output/html/part18.html#sect_10.4. * * Create a request for the method "instances.retrieveRendered". * * This request holds the parameters needed by the healthcare server. After setting any optional * parameters, call the {@link RetrieveRendered#execute()} method to invoke the remote operation. * * @param parent The name of the DICOM store that is being accessed. For example, * `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_st * ore_id}`. * @param dicomWebPath The path of the RetrieveRenderedInstance DICOMweb request. For example, * `studies/{study_uid}/series/{series_uid}/instances/{instance_uid}/rendered`. * @return the request */ public RetrieveRendered retrieveRendered(java.lang.String parent, java.lang.String dicomWebPath) throws java.io.IOException { RetrieveRendered result = new RetrieveRendered(parent, dicomWebPath); initialize(result); return result; } public class RetrieveRendered extends CloudHealthcareRequest<com.google.api.services.healthcare.v1beta1.model.HttpBody> { private static final String REST_PATH = "v1beta1/{+parent}/dicomWeb/{+dicomWebPath}"; private final java.util.regex.Pattern PARENT_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dicomStores/[^/]+$"); private final java.util.regex.Pattern DICOM_WEB_PATH_PATTERN = java.util.regex.Pattern.compile("^studies/[^/]+/series/[^/]+/instances/[^/]+/rendered$"); /** * RetrieveRenderedInstance returns instance associated with the given study, series, and SOP * Instance UID in an acceptable Rendered Media Type. See * http://dicom.nema.org/medical/dicom/current/output/html/part18.html#sect_10.4. * * Create a request for the method "instances.retrieveRendered". * * This request holds the parameters needed by the the healthcare server. After setting any * optional parameters, call the {@link RetrieveRendered#execute()} method to invoke the remote * operation. <p> {@link RetrieveRendered#initialize(com.google.api.client.googleapis.services.Abs * tractGoogleClientRequest)} must be called to initialize this instance immediately after * invoking the constructor. </p> * * @param parent The name of the DICOM store that is being accessed. For example, * `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_st * ore_id}`. * @param dicomWebPath The path of the RetrieveRenderedInstance DICOMweb request. For example, * `studies/{study_uid}/series/{series_uid}/instances/{instance_uid}/rendered`. * @since 1.13 */ protected RetrieveRendered(java.lang.String parent, java.lang.String dicomWebPath) { super(CloudHealthcare.this, "GET", REST_PATH, null, com.google.api.services.healthcare.v1beta1.model.HttpBody.class); this.parent = com.google.api.client.util.Preconditions.checkNotNull(parent, "Required parameter parent must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), "Parameter parent must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dicomStores/[^/]+$"); } this.dicomWebPath = com.google.api.client.util.Preconditions.checkNotNull(dicomWebPath, "Required parameter dicomWebPath must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(DICOM_WEB_PATH_PATTERN.matcher(dicomWebPath).matches(), "Parameter dicomWebPath must conform to the pattern " + "^studies/[^/]+/series/[^/]+/instances/[^/]+/rendered$"); } } @Override public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException { return super.executeUsingHead(); } @Override public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException { return super.buildHttpRequestUsingHead(); } @Override public RetrieveRendered set$Xgafv(java.lang.String $Xgafv) { return (RetrieveRendered) super.set$Xgafv($Xgafv); } @Override public RetrieveRendered setAccessToken(java.lang.String accessToken) { return (RetrieveRendered) super.setAccessToken(accessToken); } @Override public RetrieveRendered setAlt(java.lang.String alt) { return (RetrieveRendered) super.setAlt(alt); } @Override public RetrieveRendered setCallback(java.lang.String callback) { return (RetrieveRendered) super.setCallback(callback); } @Override public RetrieveRendered setFields(java.lang.String fields) { return (RetrieveRendered) super.setFields(fields); } @Override public RetrieveRendered setKey(java.lang.String key) { return (RetrieveRendered) super.setKey(key); } @Override public RetrieveRendered setOauthToken(java.lang.String oauthToken) { return (RetrieveRendered) super.setOauthToken(oauthToken); } @Override public RetrieveRendered setPrettyPrint(java.lang.Boolean prettyPrint) { return (RetrieveRendered) super.setPrettyPrint(prettyPrint); } @Override public RetrieveRendered setQuotaUser(java.lang.String quotaUser) { return (RetrieveRendered) super.setQuotaUser(quotaUser); } @Override public RetrieveRendered setUploadType(java.lang.String uploadType) { return (RetrieveRendered) super.setUploadType(uploadType); } @Override public RetrieveRendered setUploadProtocol(java.lang.String uploadProtocol) { return (RetrieveRendered) super.setUploadProtocol(uploadProtocol); } /** * The name of the DICOM store that is being accessed. For example, `projects/{pro * ject_id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_store * _id}`. */ @com.google.api.client.util.Key private java.lang.String parent; /** The name of the DICOM store that is being accessed. For example, `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_store_id}`. */ public java.lang.String getParent() { return parent; } /** * The name of the DICOM store that is being accessed. For example, `projects/{pro * ject_id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_store * _id}`. */ public RetrieveRendered setParent(java.lang.String parent) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), "Parameter parent must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dicomStores/[^/]+$"); } this.parent = parent; return this; } /** * The path of the RetrieveRenderedInstance DICOMweb request. For example, * `studies/{study_uid}/series/{series_uid}/instances/{instance_uid}/rendered`. */ @com.google.api.client.util.Key private java.lang.String dicomWebPath; /** The path of the RetrieveRenderedInstance DICOMweb request. For example, `studies/{study_uid}/series/{series_uid}/instances/{instance_uid}/rendered`. */ public java.lang.String getDicomWebPath() { return dicomWebPath; } /** * The path of the RetrieveRenderedInstance DICOMweb request. For example, * `studies/{study_uid}/series/{series_uid}/instances/{instance_uid}/rendered`. */ public RetrieveRendered setDicomWebPath(java.lang.String dicomWebPath) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(DICOM_WEB_PATH_PATTERN.matcher(dicomWebPath).matches(), "Parameter dicomWebPath must conform to the pattern " + "^studies/[^/]+/series/[^/]+/instances/[^/]+/rendered$"); } this.dicomWebPath = dicomWebPath; return this; } @Override public RetrieveRendered set(String parameterName, Object value) { return (RetrieveRendered) super.set(parameterName, value); } } /** * An accessor for creating requests from the Frames collection. * * <p>The typical use is:</p> * <pre> * {@code CloudHealthcare healthcare = new CloudHealthcare(...);} * {@code CloudHealthcare.Frames.List request = healthcare.frames().list(parameters ...)} * </pre> * * @return the resource collection */ public Frames frames() { return new Frames(); } /** * The "frames" collection of methods. */ public class Frames { /** * RetrieveFrames returns instances associated with the given study, series, SOP Instance UID and * frame numbers. See http://dicom.nema.org/medical/dicom/current/output/html/part18.html#sect_10.4. * * Create a request for the method "frames.retrieveFrames". * * This request holds the parameters needed by the healthcare server. After setting any optional * parameters, call the {@link RetrieveFrames#execute()} method to invoke the remote operation. * * @param parent The name of the DICOM store that is being accessed. For example, * `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_st * ore_id}`. * @param dicomWebPath The path of the RetrieveFrames DICOMweb request. For example, * `studies/{study_uid}/series/{series_uid}/instances/{instance_uid}/frames/{frame_list}`. * @return the request */ public RetrieveFrames retrieveFrames(java.lang.String parent, java.lang.String dicomWebPath) throws java.io.IOException { RetrieveFrames result = new RetrieveFrames(parent, dicomWebPath); initialize(result); return result; } public class RetrieveFrames extends CloudHealthcareRequest<com.google.api.services.healthcare.v1beta1.model.HttpBody> { private static final String REST_PATH = "v1beta1/{+parent}/dicomWeb/{+dicomWebPath}"; private final java.util.regex.Pattern PARENT_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dicomStores/[^/]+$"); private final java.util.regex.Pattern DICOM_WEB_PATH_PATTERN = java.util.regex.Pattern.compile("^studies/[^/]+/series/[^/]+/instances/[^/]+/frames/[^/]+$"); /** * RetrieveFrames returns instances associated with the given study, series, SOP Instance UID and * frame numbers. See * http://dicom.nema.org/medical/dicom/current/output/html/part18.html#sect_10.4. * * Create a request for the method "frames.retrieveFrames". * * This request holds the parameters needed by the the healthcare server. After setting any * optional parameters, call the {@link RetrieveFrames#execute()} method to invoke the remote * operation. <p> {@link RetrieveFrames#initialize(com.google.api.client.googleapis.services.Abstr * actGoogleClientRequest)} must be called to initialize this instance immediately after invoking * the constructor. </p> * * @param parent The name of the DICOM store that is being accessed. For example, * `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_st * ore_id}`. * @param dicomWebPath The path of the RetrieveFrames DICOMweb request. For example, * `studies/{study_uid}/series/{series_uid}/instances/{instance_uid}/frames/{frame_list}`. * @since 1.13 */ protected RetrieveFrames(java.lang.String parent, java.lang.String dicomWebPath) { super(CloudHealthcare.this, "GET", REST_PATH, null, com.google.api.services.healthcare.v1beta1.model.HttpBody.class); this.parent = com.google.api.client.util.Preconditions.checkNotNull(parent, "Required parameter parent must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), "Parameter parent must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dicomStores/[^/]+$"); } this.dicomWebPath = com.google.api.client.util.Preconditions.checkNotNull(dicomWebPath, "Required parameter dicomWebPath must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(DICOM_WEB_PATH_PATTERN.matcher(dicomWebPath).matches(), "Parameter dicomWebPath must conform to the pattern " + "^studies/[^/]+/series/[^/]+/instances/[^/]+/frames/[^/]+$"); } } @Override public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException { return super.executeUsingHead(); } @Override public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException { return super.buildHttpRequestUsingHead(); } @Override public RetrieveFrames set$Xgafv(java.lang.String $Xgafv) { return (RetrieveFrames) super.set$Xgafv($Xgafv); } @Override public RetrieveFrames setAccessToken(java.lang.String accessToken) { return (RetrieveFrames) super.setAccessToken(accessToken); } @Override public RetrieveFrames setAlt(java.lang.String alt) { return (RetrieveFrames) super.setAlt(alt); } @Override public RetrieveFrames setCallback(java.lang.String callback) { return (RetrieveFrames) super.setCallback(callback); } @Override public RetrieveFrames setFields(java.lang.String fields) { return (RetrieveFrames) super.setFields(fields); } @Override public RetrieveFrames setKey(java.lang.String key) { return (RetrieveFrames) super.setKey(key); } @Override public RetrieveFrames setOauthToken(java.lang.String oauthToken) { return (RetrieveFrames) super.setOauthToken(oauthToken); } @Override public RetrieveFrames setPrettyPrint(java.lang.Boolean prettyPrint) { return (RetrieveFrames) super.setPrettyPrint(prettyPrint); } @Override public RetrieveFrames setQuotaUser(java.lang.String quotaUser) { return (RetrieveFrames) super.setQuotaUser(quotaUser); } @Override public RetrieveFrames setUploadType(java.lang.String uploadType) { return (RetrieveFrames) super.setUploadType(uploadType); } @Override public RetrieveFrames setUploadProtocol(java.lang.String uploadProtocol) { return (RetrieveFrames) super.setUploadProtocol(uploadProtocol); } /** * The name of the DICOM store that is being accessed. For example, `projects/{p * roject_id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_s * tore_id}`. */ @com.google.api.client.util.Key private java.lang.String parent; /** The name of the DICOM store that is being accessed. For example, `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_store_id}`. */ public java.lang.String getParent() { return parent; } /** * The name of the DICOM store that is being accessed. For example, `projects/{p * roject_id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_s * tore_id}`. */ public RetrieveFrames setParent(java.lang.String parent) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), "Parameter parent must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dicomStores/[^/]+$"); } this.parent = parent; return this; } /** * The path of the RetrieveFrames DICOMweb request. For example, `studies/{study * _uid}/series/{series_uid}/instances/{instance_uid}/frames/{frame_list}`. */ @com.google.api.client.util.Key private java.lang.String dicomWebPath; /** The path of the RetrieveFrames DICOMweb request. For example, `studies/{study_uid}/series/{series_uid}/instances/{instance_uid}/frames/{frame_list}`. */ public java.lang.String getDicomWebPath() { return dicomWebPath; } /** * The path of the RetrieveFrames DICOMweb request. For example, `studies/{study * _uid}/series/{series_uid}/instances/{instance_uid}/frames/{frame_list}`. */ public RetrieveFrames setDicomWebPath(java.lang.String dicomWebPath) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(DICOM_WEB_PATH_PATTERN.matcher(dicomWebPath).matches(), "Parameter dicomWebPath must conform to the pattern " + "^studies/[^/]+/series/[^/]+/instances/[^/]+/frames/[^/]+$"); } this.dicomWebPath = dicomWebPath; return this; } @Override public RetrieveFrames set(String parameterName, Object value) { return (RetrieveFrames) super.set(parameterName, value); } } /** * RetrieveRenderedFrames returns instances associated with the given study, series, SOP Instance * UID and frame numbers in an acceptable Rendered Media Type. See * http://dicom.nema.org/medical/dicom/current/output/html/part18.html#sect_10.4. * * Create a request for the method "frames.retrieveRendered". * * This request holds the parameters needed by the healthcare server. After setting any optional * parameters, call the {@link RetrieveRendered#execute()} method to invoke the remote operation. * * @param parent The name of the DICOM store that is being accessed. For example, * `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_st * ore_id}`. * @param dicomWebPath The path of the RetrieveRenderedFrames DICOMweb request. For example, * `studies/{study_uid}/series/{series_uid}/instances/{instance_uid}/frames/{frame_list}/rend * ered`. * @return the request */ public RetrieveRendered retrieveRendered(java.lang.String parent, java.lang.String dicomWebPath) throws java.io.IOException { RetrieveRendered result = new RetrieveRendered(parent, dicomWebPath); initialize(result); return result; } public class RetrieveRendered extends CloudHealthcareRequest<com.google.api.services.healthcare.v1beta1.model.HttpBody> { private static final String REST_PATH = "v1beta1/{+parent}/dicomWeb/{+dicomWebPath}"; private final java.util.regex.Pattern PARENT_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dicomStores/[^/]+$"); private final java.util.regex.Pattern DICOM_WEB_PATH_PATTERN = java.util.regex.Pattern.compile("^studies/[^/]+/series/[^/]+/instances/[^/]+/frames/[^/]+/rendered$"); /** * RetrieveRenderedFrames returns instances associated with the given study, series, SOP Instance * UID and frame numbers in an acceptable Rendered Media Type. See * http://dicom.nema.org/medical/dicom/current/output/html/part18.html#sect_10.4. * * Create a request for the method "frames.retrieveRendered". * * This request holds the parameters needed by the the healthcare server. After setting any * optional parameters, call the {@link RetrieveRendered#execute()} method to invoke the remote * operation. <p> {@link RetrieveRendered#initialize(com.google.api.client.googleapis.services.Abs * tractGoogleClientRequest)} must be called to initialize this instance immediately after * invoking the constructor. </p> * * @param parent The name of the DICOM store that is being accessed. For example, * `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_st * ore_id}`. * @param dicomWebPath The path of the RetrieveRenderedFrames DICOMweb request. For example, * `studies/{study_uid}/series/{series_uid}/instances/{instance_uid}/frames/{frame_list}/rend * ered`. * @since 1.13 */ protected RetrieveRendered(java.lang.String parent, java.lang.String dicomWebPath) { super(CloudHealthcare.this, "GET", REST_PATH, null, com.google.api.services.healthcare.v1beta1.model.HttpBody.class); this.parent = com.google.api.client.util.Preconditions.checkNotNull(parent, "Required parameter parent must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), "Parameter parent must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dicomStores/[^/]+$"); } this.dicomWebPath = com.google.api.client.util.Preconditions.checkNotNull(dicomWebPath, "Required parameter dicomWebPath must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(DICOM_WEB_PATH_PATTERN.matcher(dicomWebPath).matches(), "Parameter dicomWebPath must conform to the pattern " + "^studies/[^/]+/series/[^/]+/instances/[^/]+/frames/[^/]+/rendered$"); } } @Override public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException { return super.executeUsingHead(); } @Override public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException { return super.buildHttpRequestUsingHead(); } @Override public RetrieveRendered set$Xgafv(java.lang.String $Xgafv) { return (RetrieveRendered) super.set$Xgafv($Xgafv); } @Override public RetrieveRendered setAccessToken(java.lang.String accessToken) { return (RetrieveRendered) super.setAccessToken(accessToken); } @Override public RetrieveRendered setAlt(java.lang.String alt) { return (RetrieveRendered) super.setAlt(alt); } @Override public RetrieveRendered setCallback(java.lang.String callback) { return (RetrieveRendered) super.setCallback(callback); } @Override public RetrieveRendered setFields(java.lang.String fields) { return (RetrieveRendered) super.setFields(fields); } @Override public RetrieveRendered setKey(java.lang.String key) { return (RetrieveRendered) super.setKey(key); } @Override public RetrieveRendered setOauthToken(java.lang.String oauthToken) { return (RetrieveRendered) super.setOauthToken(oauthToken); } @Override public RetrieveRendered setPrettyPrint(java.lang.Boolean prettyPrint) { return (RetrieveRendered) super.setPrettyPrint(prettyPrint); } @Override public RetrieveRendered setQuotaUser(java.lang.String quotaUser) { return (RetrieveRendered) super.setQuotaUser(quotaUser); } @Override public RetrieveRendered setUploadType(java.lang.String uploadType) { return (RetrieveRendered) super.setUploadType(uploadType); } @Override public RetrieveRendered setUploadProtocol(java.lang.String uploadProtocol) { return (RetrieveRendered) super.setUploadProtocol(uploadProtocol); } /** * The name of the DICOM store that is being accessed. For example, `projects/{p * roject_id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_s * tore_id}`. */ @com.google.api.client.util.Key private java.lang.String parent; /** The name of the DICOM store that is being accessed. For example, `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_store_id}`. */ public java.lang.String getParent() { return parent; } /** * The name of the DICOM store that is being accessed. For example, `projects/{p * roject_id}/locations/{location_id}/datasets/{dataset_id}/dicomStores/{dicom_s * tore_id}`. */ public RetrieveRendered setParent(java.lang.String parent) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), "Parameter parent must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dicomStores/[^/]+$"); } this.parent = parent; return this; } /** * The path of the RetrieveRenderedFrames DICOMweb request. For example, `studie * s/{study_uid}/series/{series_uid}/instances/{instance_uid}/frames/{frame_list * }/rendered`. */ @com.google.api.client.util.Key private java.lang.String dicomWebPath; /** The path of the RetrieveRenderedFrames DICOMweb request. For example, `studies/{study_uid}/series/{series_uid}/instances/{instance_uid}/frames/{frame_list}/rendered`. */ public java.lang.String getDicomWebPath() { return dicomWebPath; } /** * The path of the RetrieveRenderedFrames DICOMweb request. For example, `studie * s/{study_uid}/series/{series_uid}/instances/{instance_uid}/frames/{frame_list * }/rendered`. */ public RetrieveRendered setDicomWebPath(java.lang.String dicomWebPath) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(DICOM_WEB_PATH_PATTERN.matcher(dicomWebPath).matches(), "Parameter dicomWebPath must conform to the pattern " + "^studies/[^/]+/series/[^/]+/instances/[^/]+/frames/[^/]+/rendered$"); } this.dicomWebPath = dicomWebPath; return this; } @Override public RetrieveRendered set(String parameterName, Object value) { return (RetrieveRendered) super.set(parameterName, value); } } } } } } } /** * An accessor for creating requests from the FhirStores collection. * * <p>The typical use is:</p> * <pre> * {@code CloudHealthcare healthcare = new CloudHealthcare(...);} * {@code CloudHealthcare.FhirStores.List request = healthcare.fhirStores().list(parameters ...)} * </pre> * * @return the resource collection */ public FhirStores fhirStores() { return new FhirStores(); } /** * The "fhirStores" collection of methods. */ public class FhirStores { /** * Creates a new FHIR store within the parent dataset. * * Create a request for the method "fhirStores.create". * * This request holds the parameters needed by the healthcare server. After setting any optional * parameters, call the {@link Create#execute()} method to invoke the remote operation. * * @param parent The name of the dataset this FHIR store belongs to. * @param content the {@link com.google.api.services.healthcare.v1beta1.model.FhirStore} * @return the request */ public Create create(java.lang.String parent, com.google.api.services.healthcare.v1beta1.model.FhirStore content) throws java.io.IOException { Create result = new Create(parent, content); initialize(result); return result; } public class Create extends CloudHealthcareRequest<com.google.api.services.healthcare.v1beta1.model.FhirStore> { private static final String REST_PATH = "v1beta1/{+parent}/fhirStores"; private final java.util.regex.Pattern PARENT_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/datasets/[^/]+$"); /** * Creates a new FHIR store within the parent dataset. * * Create a request for the method "fhirStores.create". * * This request holds the parameters needed by the the healthcare server. After setting any * optional parameters, call the {@link Create#execute()} method to invoke the remote operation. * <p> {@link * Create#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} must * be called to initialize this instance immediately after invoking the constructor. </p> * * @param parent The name of the dataset this FHIR store belongs to. * @param content the {@link com.google.api.services.healthcare.v1beta1.model.FhirStore} * @since 1.13 */ protected Create(java.lang.String parent, com.google.api.services.healthcare.v1beta1.model.FhirStore content) { super(CloudHealthcare.this, "POST", REST_PATH, content, com.google.api.services.healthcare.v1beta1.model.FhirStore.class); this.parent = com.google.api.client.util.Preconditions.checkNotNull(parent, "Required parameter parent must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), "Parameter parent must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+$"); } } @Override public Create set$Xgafv(java.lang.String $Xgafv) { return (Create) super.set$Xgafv($Xgafv); } @Override public Create setAccessToken(java.lang.String accessToken) { return (Create) super.setAccessToken(accessToken); } @Override public Create setAlt(java.lang.String alt) { return (Create) super.setAlt(alt); } @Override public Create setCallback(java.lang.String callback) { return (Create) super.setCallback(callback); } @Override public Create setFields(java.lang.String fields) { return (Create) super.setFields(fields); } @Override public Create setKey(java.lang.String key) { return (Create) super.setKey(key); } @Override public Create setOauthToken(java.lang.String oauthToken) { return (Create) super.setOauthToken(oauthToken); } @Override public Create setPrettyPrint(java.lang.Boolean prettyPrint) { return (Create) super.setPrettyPrint(prettyPrint); } @Override public Create setQuotaUser(java.lang.String quotaUser) { return (Create) super.setQuotaUser(quotaUser); } @Override public Create setUploadType(java.lang.String uploadType) { return (Create) super.setUploadType(uploadType); } @Override public Create setUploadProtocol(java.lang.String uploadProtocol) { return (Create) super.setUploadProtocol(uploadProtocol); } /** The name of the dataset this FHIR store belongs to. */ @com.google.api.client.util.Key private java.lang.String parent; /** The name of the dataset this FHIR store belongs to. */ public java.lang.String getParent() { return parent; } /** The name of the dataset this FHIR store belongs to. */ public Create setParent(java.lang.String parent) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), "Parameter parent must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+$"); } this.parent = parent; return this; } /** * The ID of the FHIR store that is being created. The string must match the following * regex: `[\p{L}\p{N}_\-\.]{1,256}`. */ @com.google.api.client.util.Key private java.lang.String fhirStoreId; /** The ID of the FHIR store that is being created. The string must match the following regex: `[\p{L}\p{N}_\-\.]{1,256}`. */ public java.lang.String getFhirStoreId() { return fhirStoreId; } /** * The ID of the FHIR store that is being created. The string must match the following * regex: `[\p{L}\p{N}_\-\.]{1,256}`. */ public Create setFhirStoreId(java.lang.String fhirStoreId) { this.fhirStoreId = fhirStoreId; return this; } @Override public Create set(String parameterName, Object value) { return (Create) super.set(parameterName, value); } } /** * Creates a new FHIR store containing de-identified data from the source store. The metadata field * type is OperationMetadata. If the request is successful, the response field type is * DeidentifyFhirStoreSummary. If errors occur, error details field type is DeidentifyErrorDetails. * Errors are also logged to Stackdriver (see [Viewing logs](/healthcare/docs/how-tos/stackdriver- * logging)). * * Create a request for the method "fhirStores.deidentify". * * This request holds the parameters needed by the healthcare server. After setting any optional * parameters, call the {@link Deidentify#execute()} method to invoke the remote operation. * * @param sourceStore Source FHIR store resource name. For example, * `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}/fhirStores/{fhir_stor * e_id}`. * @param content the {@link com.google.api.services.healthcare.v1beta1.model.DeidentifyFhirStoreRequest} * @return the request */ public Deidentify deidentify(java.lang.String sourceStore, com.google.api.services.healthcare.v1beta1.model.DeidentifyFhirStoreRequest content) throws java.io.IOException { Deidentify result = new Deidentify(sourceStore, content); initialize(result); return result; } public class Deidentify extends CloudHealthcareRequest<com.google.api.services.healthcare.v1beta1.model.Operation> { private static final String REST_PATH = "v1beta1/{+sourceStore}:deidentify"; private final java.util.regex.Pattern SOURCE_STORE_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/datasets/[^/]+/fhirStores/[^/]+$"); /** * Creates a new FHIR store containing de-identified data from the source store. The metadata * field type is OperationMetadata. If the request is successful, the response field type is * DeidentifyFhirStoreSummary. If errors occur, error details field type is * DeidentifyErrorDetails. Errors are also logged to Stackdriver (see [Viewing * logs](/healthcare/docs/how-tos/stackdriver-logging)). * * Create a request for the method "fhirStores.deidentify". * * This request holds the parameters needed by the the healthcare server. After setting any * optional parameters, call the {@link Deidentify#execute()} method to invoke the remote * operation. <p> {@link * Deidentify#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} * must be called to initialize this instance immediately after invoking the constructor. </p> * * @param sourceStore Source FHIR store resource name. For example, * `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}/fhirStores/{fhir_stor * e_id}`. * @param content the {@link com.google.api.services.healthcare.v1beta1.model.DeidentifyFhirStoreRequest} * @since 1.13 */ protected Deidentify(java.lang.String sourceStore, com.google.api.services.healthcare.v1beta1.model.DeidentifyFhirStoreRequest content) { super(CloudHealthcare.this, "POST", REST_PATH, content, com.google.api.services.healthcare.v1beta1.model.Operation.class); this.sourceStore = com.google.api.client.util.Preconditions.checkNotNull(sourceStore, "Required parameter sourceStore must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(SOURCE_STORE_PATTERN.matcher(sourceStore).matches(), "Parameter sourceStore must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/fhirStores/[^/]+$"); } } @Override public Deidentify set$Xgafv(java.lang.String $Xgafv) { return (Deidentify) super.set$Xgafv($Xgafv); } @Override public Deidentify setAccessToken(java.lang.String accessToken) { return (Deidentify) super.setAccessToken(accessToken); } @Override public Deidentify setAlt(java.lang.String alt) { return (Deidentify) super.setAlt(alt); } @Override public Deidentify setCallback(java.lang.String callback) { return (Deidentify) super.setCallback(callback); } @Override public Deidentify setFields(java.lang.String fields) { return (Deidentify) super.setFields(fields); } @Override public Deidentify setKey(java.lang.String key) { return (Deidentify) super.setKey(key); } @Override public Deidentify setOauthToken(java.lang.String oauthToken) { return (Deidentify) super.setOauthToken(oauthToken); } @Override public Deidentify setPrettyPrint(java.lang.Boolean prettyPrint) { return (Deidentify) super.setPrettyPrint(prettyPrint); } @Override public Deidentify setQuotaUser(java.lang.String quotaUser) { return (Deidentify) super.setQuotaUser(quotaUser); } @Override public Deidentify setUploadType(java.lang.String uploadType) { return (Deidentify) super.setUploadType(uploadType); } @Override public Deidentify setUploadProtocol(java.lang.String uploadProtocol) { return (Deidentify) super.setUploadProtocol(uploadProtocol); } /** * Source FHIR store resource name. For example, `projects/{project_id}/locations/{locat * ion_id}/datasets/{dataset_id}/fhirStores/{fhir_store_id}`. */ @com.google.api.client.util.Key private java.lang.String sourceStore; /** Source FHIR store resource name. For example, `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}/fhirStores/{fhir_store_id}`. */ public java.lang.String getSourceStore() { return sourceStore; } /** * Source FHIR store resource name. For example, `projects/{project_id}/locations/{locat * ion_id}/datasets/{dataset_id}/fhirStores/{fhir_store_id}`. */ public Deidentify setSourceStore(java.lang.String sourceStore) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(SOURCE_STORE_PATTERN.matcher(sourceStore).matches(), "Parameter sourceStore must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/fhirStores/[^/]+$"); } this.sourceStore = sourceStore; return this; } @Override public Deidentify set(String parameterName, Object value) { return (Deidentify) super.set(parameterName, value); } } /** * Deletes the specified FHIR store and removes all resources within it. * * Create a request for the method "fhirStores.delete". * * This request holds the parameters needed by the healthcare server. After setting any optional * parameters, call the {@link Delete#execute()} method to invoke the remote operation. * * @param name The resource name of the FHIR store to delete. * @return the request */ public Delete delete(java.lang.String name) throws java.io.IOException { Delete result = new Delete(name); initialize(result); return result; } public class Delete extends CloudHealthcareRequest<com.google.api.services.healthcare.v1beta1.model.Empty> { private static final String REST_PATH = "v1beta1/{+name}"; private final java.util.regex.Pattern NAME_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/datasets/[^/]+/fhirStores/[^/]+$"); /** * Deletes the specified FHIR store and removes all resources within it. * * Create a request for the method "fhirStores.delete". * * This request holds the parameters needed by the the healthcare server. After setting any * optional parameters, call the {@link Delete#execute()} method to invoke the remote operation. * <p> {@link * Delete#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} must * be called to initialize this instance immediately after invoking the constructor. </p> * * @param name The resource name of the FHIR store to delete. * @since 1.13 */ protected Delete(java.lang.String name) { super(CloudHealthcare.this, "DELETE", REST_PATH, null, com.google.api.services.healthcare.v1beta1.model.Empty.class); this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), "Parameter name must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/fhirStores/[^/]+$"); } } @Override public Delete set$Xgafv(java.lang.String $Xgafv) { return (Delete) super.set$Xgafv($Xgafv); } @Override public Delete setAccessToken(java.lang.String accessToken) { return (Delete) super.setAccessToken(accessToken); } @Override public Delete setAlt(java.lang.String alt) { return (Delete) super.setAlt(alt); } @Override public Delete setCallback(java.lang.String callback) { return (Delete) super.setCallback(callback); } @Override public Delete setFields(java.lang.String fields) { return (Delete) super.setFields(fields); } @Override public Delete setKey(java.lang.String key) { return (Delete) super.setKey(key); } @Override public Delete setOauthToken(java.lang.String oauthToken) { return (Delete) super.setOauthToken(oauthToken); } @Override public Delete setPrettyPrint(java.lang.Boolean prettyPrint) { return (Delete) super.setPrettyPrint(prettyPrint); } @Override public Delete setQuotaUser(java.lang.String quotaUser) { return (Delete) super.setQuotaUser(quotaUser); } @Override public Delete setUploadType(java.lang.String uploadType) { return (Delete) super.setUploadType(uploadType); } @Override public Delete setUploadProtocol(java.lang.String uploadProtocol) { return (Delete) super.setUploadProtocol(uploadProtocol); } /** The resource name of the FHIR store to delete. */ @com.google.api.client.util.Key private java.lang.String name; /** The resource name of the FHIR store to delete. */ public java.lang.String getName() { return name; } /** The resource name of the FHIR store to delete. */ public Delete setName(java.lang.String name) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), "Parameter name must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/fhirStores/[^/]+$"); } this.name = name; return this; } @Override public Delete set(String parameterName, Object value) { return (Delete) super.set(parameterName, value); } } /** * Export resources from the FHIR store to the specified destination. * * This method returns an Operation that can be used to track the status of the export by calling * GetOperation. * * Immediate fatal errors appear in the error field, errors are also logged to Stackdriver (see * [Viewing logs](/healthcare/docs/how-tos/stackdriver-logging)). Otherwise, when the operation * finishes, a detailed response of type ExportResourcesResponse is returned in the response field. * The metadata field type for this operation is OperationMetadata. * * Create a request for the method "fhirStores.export". * * This request holds the parameters needed by the healthcare server. After setting any optional * parameters, call the {@link Export#execute()} method to invoke the remote operation. * * @param name The name of the FHIR store to export resource from. The name should be in the format of * `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}/fhirStores/{fhir_stor * e_id}`. * @param content the {@link com.google.api.services.healthcare.v1beta1.model.ExportResourcesRequest} * @return the request */ public Export export(java.lang.String name, com.google.api.services.healthcare.v1beta1.model.ExportResourcesRequest content) throws java.io.IOException { Export result = new Export(name, content); initialize(result); return result; } public class Export extends CloudHealthcareRequest<com.google.api.services.healthcare.v1beta1.model.Operation> { private static final String REST_PATH = "v1beta1/{+name}:export"; private final java.util.regex.Pattern NAME_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/datasets/[^/]+/fhirStores/[^/]+$"); /** * Export resources from the FHIR store to the specified destination. * * This method returns an Operation that can be used to track the status of the export by calling * GetOperation. * * Immediate fatal errors appear in the error field, errors are also logged to Stackdriver (see * [Viewing logs](/healthcare/docs/how-tos/stackdriver-logging)). Otherwise, when the operation * finishes, a detailed response of type ExportResourcesResponse is returned in the response * field. The metadata field type for this operation is OperationMetadata. * * Create a request for the method "fhirStores.export". * * This request holds the parameters needed by the the healthcare server. After setting any * optional parameters, call the {@link Export#execute()} method to invoke the remote operation. * <p> {@link * Export#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} must * be called to initialize this instance immediately after invoking the constructor. </p> * * @param name The name of the FHIR store to export resource from. The name should be in the format of * `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}/fhirStores/{fhir_stor * e_id}`. * @param content the {@link com.google.api.services.healthcare.v1beta1.model.ExportResourcesRequest} * @since 1.13 */ protected Export(java.lang.String name, com.google.api.services.healthcare.v1beta1.model.ExportResourcesRequest content) { super(CloudHealthcare.this, "POST", REST_PATH, content, com.google.api.services.healthcare.v1beta1.model.Operation.class); this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), "Parameter name must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/fhirStores/[^/]+$"); } } @Override public Export set$Xgafv(java.lang.String $Xgafv) { return (Export) super.set$Xgafv($Xgafv); } @Override public Export setAccessToken(java.lang.String accessToken) { return (Export) super.setAccessToken(accessToken); } @Override public Export setAlt(java.lang.String alt) { return (Export) super.setAlt(alt); } @Override public Export setCallback(java.lang.String callback) { return (Export) super.setCallback(callback); } @Override public Export setFields(java.lang.String fields) { return (Export) super.setFields(fields); } @Override public Export setKey(java.lang.String key) { return (Export) super.setKey(key); } @Override public Export setOauthToken(java.lang.String oauthToken) { return (Export) super.setOauthToken(oauthToken); } @Override public Export setPrettyPrint(java.lang.Boolean prettyPrint) { return (Export) super.setPrettyPrint(prettyPrint); } @Override public Export setQuotaUser(java.lang.String quotaUser) { return (Export) super.setQuotaUser(quotaUser); } @Override public Export setUploadType(java.lang.String uploadType) { return (Export) super.setUploadType(uploadType); } @Override public Export setUploadProtocol(java.lang.String uploadProtocol) { return (Export) super.setUploadProtocol(uploadProtocol); } /** * The name of the FHIR store to export resource from. The name should be in the format * of `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}/fhirStores/{f * hir_store_id}`. */ @com.google.api.client.util.Key private java.lang.String name; /** The name of the FHIR store to export resource from. The name should be in the format of `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}/fhirStores/{fhir_store_id}`. */ public java.lang.String getName() { return name; } /** * The name of the FHIR store to export resource from. The name should be in the format * of `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}/fhirStores/{f * hir_store_id}`. */ public Export setName(java.lang.String name) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), "Parameter name must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/fhirStores/[^/]+$"); } this.name = name; return this; } @Override public Export set(String parameterName, Object value) { return (Export) super.set(parameterName, value); } } /** * Gets the configuration of the specified FHIR store. * * Create a request for the method "fhirStores.get". * * This request holds the parameters needed by the healthcare server. After setting any optional * parameters, call the {@link Get#execute()} method to invoke the remote operation. * * @param name The resource name of the FHIR store to get. * @return the request */ public Get get(java.lang.String name) throws java.io.IOException { Get result = new Get(name); initialize(result); return result; } public class Get extends CloudHealthcareRequest<com.google.api.services.healthcare.v1beta1.model.FhirStore> { private static final String REST_PATH = "v1beta1/{+name}"; private final java.util.regex.Pattern NAME_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/datasets/[^/]+/fhirStores/[^/]+$"); /** * Gets the configuration of the specified FHIR store. * * Create a request for the method "fhirStores.get". * * This request holds the parameters needed by the the healthcare server. After setting any * optional parameters, call the {@link Get#execute()} method to invoke the remote operation. <p> * {@link Get#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} * must be called to initialize this instance immediately after invoking the constructor. </p> * * @param name The resource name of the FHIR store to get. * @since 1.13 */ protected Get(java.lang.String name) { super(CloudHealthcare.this, "GET", REST_PATH, null, com.google.api.services.healthcare.v1beta1.model.FhirStore.class); this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), "Parameter name must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/fhirStores/[^/]+$"); } } @Override public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException { return super.executeUsingHead(); } @Override public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException { return super.buildHttpRequestUsingHead(); } @Override public Get set$Xgafv(java.lang.String $Xgafv) { return (Get) super.set$Xgafv($Xgafv); } @Override public Get setAccessToken(java.lang.String accessToken) { return (Get) super.setAccessToken(accessToken); } @Override public Get setAlt(java.lang.String alt) { return (Get) super.setAlt(alt); } @Override public Get setCallback(java.lang.String callback) { return (Get) super.setCallback(callback); } @Override public Get setFields(java.lang.String fields) { return (Get) super.setFields(fields); } @Override public Get setKey(java.lang.String key) { return (Get) super.setKey(key); } @Override public Get setOauthToken(java.lang.String oauthToken) { return (Get) super.setOauthToken(oauthToken); } @Override public Get setPrettyPrint(java.lang.Boolean prettyPrint) { return (Get) super.setPrettyPrint(prettyPrint); } @Override public Get setQuotaUser(java.lang.String quotaUser) { return (Get) super.setQuotaUser(quotaUser); } @Override public Get setUploadType(java.lang.String uploadType) { return (Get) super.setUploadType(uploadType); } @Override public Get setUploadProtocol(java.lang.String uploadProtocol) { return (Get) super.setUploadProtocol(uploadProtocol); } /** The resource name of the FHIR store to get. */ @com.google.api.client.util.Key private java.lang.String name; /** The resource name of the FHIR store to get. */ public java.lang.String getName() { return name; } /** The resource name of the FHIR store to get. */ public Get setName(java.lang.String name) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), "Parameter name must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/fhirStores/[^/]+$"); } this.name = name; return this; } @Override public Get set(String parameterName, Object value) { return (Get) super.set(parameterName, value); } } /** * Gets the access control policy for a resource. Returns an empty policy if the resource exists and * does not have a policy set. * * Create a request for the method "fhirStores.getIamPolicy". * * This request holds the parameters needed by the healthcare server. After setting any optional * parameters, call the {@link GetIamPolicy#execute()} method to invoke the remote operation. * * @param resource REQUIRED: The resource for which the policy is being requested. See the operation documentation for * the appropriate value for this field. * @return the request */ public GetIamPolicy getIamPolicy(java.lang.String resource) throws java.io.IOException { GetIamPolicy result = new GetIamPolicy(resource); initialize(result); return result; } public class GetIamPolicy extends CloudHealthcareRequest<com.google.api.services.healthcare.v1beta1.model.Policy> { private static final String REST_PATH = "v1beta1/{+resource}:getIamPolicy"; private final java.util.regex.Pattern RESOURCE_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/datasets/[^/]+/fhirStores/[^/]+$"); /** * Gets the access control policy for a resource. Returns an empty policy if the resource exists * and does not have a policy set. * * Create a request for the method "fhirStores.getIamPolicy". * * This request holds the parameters needed by the the healthcare server. After setting any * optional parameters, call the {@link GetIamPolicy#execute()} method to invoke the remote * operation. <p> {@link * GetIamPolicy#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} * must be called to initialize this instance immediately after invoking the constructor. </p> * * @param resource REQUIRED: The resource for which the policy is being requested. See the operation documentation for * the appropriate value for this field. * @since 1.13 */ protected GetIamPolicy(java.lang.String resource) { super(CloudHealthcare.this, "GET", REST_PATH, null, com.google.api.services.healthcare.v1beta1.model.Policy.class); this.resource = com.google.api.client.util.Preconditions.checkNotNull(resource, "Required parameter resource must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(RESOURCE_PATTERN.matcher(resource).matches(), "Parameter resource must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/fhirStores/[^/]+$"); } } @Override public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException { return super.executeUsingHead(); } @Override public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException { return super.buildHttpRequestUsingHead(); } @Override public GetIamPolicy set$Xgafv(java.lang.String $Xgafv) { return (GetIamPolicy) super.set$Xgafv($Xgafv); } @Override public GetIamPolicy setAccessToken(java.lang.String accessToken) { return (GetIamPolicy) super.setAccessToken(accessToken); } @Override public GetIamPolicy setAlt(java.lang.String alt) { return (GetIamPolicy) super.setAlt(alt); } @Override public GetIamPolicy setCallback(java.lang.String callback) { return (GetIamPolicy) super.setCallback(callback); } @Override public GetIamPolicy setFields(java.lang.String fields) { return (GetIamPolicy) super.setFields(fields); } @Override public GetIamPolicy setKey(java.lang.String key) { return (GetIamPolicy) super.setKey(key); } @Override public GetIamPolicy setOauthToken(java.lang.String oauthToken) { return (GetIamPolicy) super.setOauthToken(oauthToken); } @Override public GetIamPolicy setPrettyPrint(java.lang.Boolean prettyPrint) { return (GetIamPolicy) super.setPrettyPrint(prettyPrint); } @Override public GetIamPolicy setQuotaUser(java.lang.String quotaUser) { return (GetIamPolicy) super.setQuotaUser(quotaUser); } @Override public GetIamPolicy setUploadType(java.lang.String uploadType) { return (GetIamPolicy) super.setUploadType(uploadType); } @Override public GetIamPolicy setUploadProtocol(java.lang.String uploadProtocol) { return (GetIamPolicy) super.setUploadProtocol(uploadProtocol); } /** * REQUIRED: The resource for which the policy is being requested. See the operation * documentation for the appropriate value for this field. */ @com.google.api.client.util.Key private java.lang.String resource; /** REQUIRED: The resource for which the policy is being requested. See the operation documentation for the appropriate value for this field. */ public java.lang.String getResource() { return resource; } /** * REQUIRED: The resource for which the policy is being requested. See the operation * documentation for the appropriate value for this field. */ public GetIamPolicy setResource(java.lang.String resource) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(RESOURCE_PATTERN.matcher(resource).matches(), "Parameter resource must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/fhirStores/[^/]+$"); } this.resource = resource; return this; } /** * Optional. The policy format version to be returned. * * Valid values are 0, 1, and 3. Requests specifying an invalid value will be rejected. * * Requests for policies with any conditional bindings must specify version 3. Policies * without any conditional bindings may specify any valid value or leave the field * unset. */ @com.google.api.client.util.Key("options.requestedPolicyVersion") private java.lang.Integer optionsRequestedPolicyVersion; /** Optional. The policy format version to be returned. Valid values are 0, 1, and 3. Requests specifying an invalid value will be rejected. Requests for policies with any conditional bindings must specify version 3. Policies without any conditional bindings may specify any valid value or leave the field unset. */ public java.lang.Integer getOptionsRequestedPolicyVersion() { return optionsRequestedPolicyVersion; } /** * Optional. The policy format version to be returned. * * Valid values are 0, 1, and 3. Requests specifying an invalid value will be rejected. * * Requests for policies with any conditional bindings must specify version 3. Policies * without any conditional bindings may specify any valid value or leave the field * unset. */ public GetIamPolicy setOptionsRequestedPolicyVersion(java.lang.Integer optionsRequestedPolicyVersion) { this.optionsRequestedPolicyVersion = optionsRequestedPolicyVersion; return this; } @Override public GetIamPolicy set(String parameterName, Object value) { return (GetIamPolicy) super.set(parameterName, value); } } /** * Import resources to the FHIR store by loading data from the specified sources. This method is * optimized to load large quantities of data using import semantics that ignore some FHIR store * configuration options and are not suitable for all use cases. It is primarily intended to load * data into an empty FHIR store that is not being used by other clients. In cases where this method * is not appropriate, consider using ExecuteBundle to load data. * * Every resource in the input must contain a client-supplied ID, and will be stored using that ID * regardless of the enable_update_create setting on the FHIR store. * * The import process does not enforce referential integrity, regardless of the * disable_referential_integrity setting on the FHIR store. This allows the import of resources with * arbitrary interdependencies without considering grouping or ordering, but if the input data * contains invalid references or if some resources fail to be imported, the FHIR store might be * left in a state that violates referential integrity. * * If a resource with the specified ID already exists, the most recent version of the resource is * overwritten without creating a new historical version, regardless of the * disable_resource_versioning setting on the FHIR store. If transient failures occur during the * import, it is possible that successfully imported resources will be overwritten more than once. * * The import operation is idempotent unless the input data contains multiple valid resources with * the same ID but different contents. In that case, after the import completes, the store will * contain exactly one resource with that ID but there is no ordering guarantee on which version of * the contents it will have. The operation result counters do not count duplicate IDs as an error * and will count one success for each resource in the input, which might result in a success count * larger than the number of resources in the FHIR store. This often occurs when importing data * organized in bundles produced by Patient-everything where each bundle contains its own copy of a * resource such as Practitioner that might be referred to by many patients. * * If some resources fail to import, for example due to parsing errors, successfully imported * resources are not rolled back. * * The location and format of the input data is specified by the parameters below. Note that if no * format is specified, this method assumes the `BUNDLE` format. When using the `BUNDLE` format this * method ignores the `Bundle.type` field, except that `history` bundles are rejected, and does not * apply any of the bundle processing semantics for batch or transaction bundles. Unlike in * ExecuteBundle, transaction bundles are not executed as a single transaction and bundle-internal * references are not rewritten. The bundle is treated as a collection of resources to be written as * provided in `Bundle.entry.resource`, ignoring `Bundle.entry.request`. As an example, this allows * the import of `searchset` bundles produced by a FHIR search or Patient-everything operation. * * This method returns an Operation that can be used to track the status of the import by calling * GetOperation. * * Immediate fatal errors appear in the error field, errors are also logged to Stackdriver (see * [Viewing logs](/healthcare/docs/how-tos/stackdriver-logging)). Otherwise, when the operation * finishes, a detailed response of type ImportResourcesResponse is returned in the response field. * The metadata field type for this operation is OperationMetadata. * * Create a request for the method "fhirStores.import". * * This request holds the parameters needed by the healthcare server. After setting any optional * parameters, call the {@link CloudHealthcareImport#execute()} method to invoke the remote * operation. * * @param name The name of the FHIR store to import FHIR resources to. The name should be in the format of * `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}/fhirStores/{fhir_stor * e_id}`. * @param content the {@link com.google.api.services.healthcare.v1beta1.model.ImportResourcesRequest} * @return the request */ public CloudHealthcareImport healthcareImport(java.lang.String name, com.google.api.services.healthcare.v1beta1.model.ImportResourcesRequest content) throws java.io.IOException { CloudHealthcareImport result = new CloudHealthcareImport(name, content); initialize(result); return result; } public class CloudHealthcareImport extends CloudHealthcareRequest<com.google.api.services.healthcare.v1beta1.model.Operation> { private static final String REST_PATH = "v1beta1/{+name}:import"; private final java.util.regex.Pattern NAME_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/datasets/[^/]+/fhirStores/[^/]+$"); /** * Import resources to the FHIR store by loading data from the specified sources. This method is * optimized to load large quantities of data using import semantics that ignore some FHIR store * configuration options and are not suitable for all use cases. It is primarily intended to load * data into an empty FHIR store that is not being used by other clients. In cases where this * method is not appropriate, consider using ExecuteBundle to load data. * * Every resource in the input must contain a client-supplied ID, and will be stored using that ID * regardless of the enable_update_create setting on the FHIR store. * * The import process does not enforce referential integrity, regardless of the * disable_referential_integrity setting on the FHIR store. This allows the import of resources * with arbitrary interdependencies without considering grouping or ordering, but if the input * data contains invalid references or if some resources fail to be imported, the FHIR store might * be left in a state that violates referential integrity. * * If a resource with the specified ID already exists, the most recent version of the resource is * overwritten without creating a new historical version, regardless of the * disable_resource_versioning setting on the FHIR store. If transient failures occur during the * import, it is possible that successfully imported resources will be overwritten more than once. * * The import operation is idempotent unless the input data contains multiple valid resources with * the same ID but different contents. In that case, after the import completes, the store will * contain exactly one resource with that ID but there is no ordering guarantee on which version * of the contents it will have. The operation result counters do not count duplicate IDs as an * error and will count one success for each resource in the input, which might result in a * success count larger than the number of resources in the FHIR store. This often occurs when * importing data organized in bundles produced by Patient-everything where each bundle contains * its own copy of a resource such as Practitioner that might be referred to by many patients. * * If some resources fail to import, for example due to parsing errors, successfully imported * resources are not rolled back. * * The location and format of the input data is specified by the parameters below. Note that if no * format is specified, this method assumes the `BUNDLE` format. When using the `BUNDLE` format * this method ignores the `Bundle.type` field, except that `history` bundles are rejected, and * does not apply any of the bundle processing semantics for batch or transaction bundles. Unlike * in ExecuteBundle, transaction bundles are not executed as a single transaction and bundle- * internal references are not rewritten. The bundle is treated as a collection of resources to be * written as provided in `Bundle.entry.resource`, ignoring `Bundle.entry.request`. As an example, * this allows the import of `searchset` bundles produced by a FHIR search or Patient-everything * operation. * * This method returns an Operation that can be used to track the status of the import by calling * GetOperation. * * Immediate fatal errors appear in the error field, errors are also logged to Stackdriver (see * [Viewing logs](/healthcare/docs/how-tos/stackdriver-logging)). Otherwise, when the operation * finishes, a detailed response of type ImportResourcesResponse is returned in the response * field. The metadata field type for this operation is OperationMetadata. * * Create a request for the method "fhirStores.import". * * This request holds the parameters needed by the the healthcare server. After setting any * optional parameters, call the {@link CloudHealthcareImport#execute()} method to invoke the * remote operation. <p> {@link CloudHealthcareImport#initialize(com.google.api.client.googleapis. * services.AbstractGoogleClientRequest)} must be called to initialize this instance immediately * after invoking the constructor. </p> * * @param name The name of the FHIR store to import FHIR resources to. The name should be in the format of * `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}/fhirStores/{fhir_stor * e_id}`. * @param content the {@link com.google.api.services.healthcare.v1beta1.model.ImportResourcesRequest} * @since 1.13 */ protected CloudHealthcareImport(java.lang.String name, com.google.api.services.healthcare.v1beta1.model.ImportResourcesRequest content) { super(CloudHealthcare.this, "POST", REST_PATH, content, com.google.api.services.healthcare.v1beta1.model.Operation.class); this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), "Parameter name must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/fhirStores/[^/]+$"); } } @Override public CloudHealthcareImport set$Xgafv(java.lang.String $Xgafv) { return (CloudHealthcareImport) super.set$Xgafv($Xgafv); } @Override public CloudHealthcareImport setAccessToken(java.lang.String accessToken) { return (CloudHealthcareImport) super.setAccessToken(accessToken); } @Override public CloudHealthcareImport setAlt(java.lang.String alt) { return (CloudHealthcareImport) super.setAlt(alt); } @Override public CloudHealthcareImport setCallback(java.lang.String callback) { return (CloudHealthcareImport) super.setCallback(callback); } @Override public CloudHealthcareImport setFields(java.lang.String fields) { return (CloudHealthcareImport) super.setFields(fields); } @Override public CloudHealthcareImport setKey(java.lang.String key) { return (CloudHealthcareImport) super.setKey(key); } @Override public CloudHealthcareImport setOauthToken(java.lang.String oauthToken) { return (CloudHealthcareImport) super.setOauthToken(oauthToken); } @Override public CloudHealthcareImport setPrettyPrint(java.lang.Boolean prettyPrint) { return (CloudHealthcareImport) super.setPrettyPrint(prettyPrint); } @Override public CloudHealthcareImport setQuotaUser(java.lang.String quotaUser) { return (CloudHealthcareImport) super.setQuotaUser(quotaUser); } @Override public CloudHealthcareImport setUploadType(java.lang.String uploadType) { return (CloudHealthcareImport) super.setUploadType(uploadType); } @Override public CloudHealthcareImport setUploadProtocol(java.lang.String uploadProtocol) { return (CloudHealthcareImport) super.setUploadProtocol(uploadProtocol); } /** * The name of the FHIR store to import FHIR resources to. The name should be in the * format of `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}/fhirSt * ores/{fhir_store_id}`. */ @com.google.api.client.util.Key private java.lang.String name; /** The name of the FHIR store to import FHIR resources to. The name should be in the format of `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}/fhirStores/{fhir_store_id}`. */ public java.lang.String getName() { return name; } /** * The name of the FHIR store to import FHIR resources to. The name should be in the * format of `projects/{project_id}/locations/{location_id}/datasets/{dataset_id}/fhirSt * ores/{fhir_store_id}`. */ public CloudHealthcareImport setName(java.lang.String name) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), "Parameter name must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/fhirStores/[^/]+$"); } this.name = name; return this; } @Override public CloudHealthcareImport set(String parameterName, Object value) { return (CloudHealthcareImport) super.set(parameterName, value); } } /** * Lists the FHIR stores in the given dataset. * * Create a request for the method "fhirStores.list". * * This request holds the parameters needed by the healthcare server. After setting any optional * parameters, call the {@link List#execute()} method to invoke the remote operation. * * @param parent Name of the dataset. * @return the request */ public List list(java.lang.String parent) throws java.io.IOException { List result = new List(parent); initialize(result); return result; } public class List extends CloudHealthcareRequest<com.google.api.services.healthcare.v1beta1.model.ListFhirStoresResponse> { private static final String REST_PATH = "v1beta1/{+parent}/fhirStores"; private final java.util.regex.Pattern PARENT_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/datasets/[^/]+$"); /** * Lists the FHIR stores in the given dataset. * * Create a request for the method "fhirStores.list". * * This request holds the parameters needed by the the healthcare server. After setting any * optional parameters, call the {@link List#execute()} method to invoke the remote operation. <p> * {@link List#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} * must be called to initialize this instance immediately after invoking the constructor. </p> * * @param parent Name of the dataset. * @since 1.13 */ protected List(java.lang.String parent) { super(CloudHealthcare.this, "GET", REST_PATH, null, com.google.api.services.healthcare.v1beta1.model.ListFhirStoresResponse.class); this.parent = com.google.api.client.util.Preconditions.checkNotNull(parent, "Required parameter parent must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), "Parameter parent must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+$"); } } @Override public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException { return super.executeUsingHead(); } @Override public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException { return super.buildHttpRequestUsingHead(); } @Override public List set$Xgafv(java.lang.String $Xgafv) { return (List) super.set$Xgafv($Xgafv); } @Override public List setAccessToken(java.lang.String accessToken) { return (List) super.setAccessToken(accessToken); } @Override public List setAlt(java.lang.String alt) { return (List) super.setAlt(alt); } @Override public List setCallback(java.lang.String callback) { return (List) super.setCallback(callback); } @Override public List setFields(java.lang.String fields) { return (List) super.setFields(fields); } @Override public List setKey(java.lang.String key) { return (List) super.setKey(key); } @Override public List setOauthToken(java.lang.String oauthToken) { return (List) super.setOauthToken(oauthToken); } @Override public List setPrettyPrint(java.lang.Boolean prettyPrint) { return (List) super.setPrettyPrint(prettyPrint); } @Override public List setQuotaUser(java.lang.String quotaUser) { return (List) super.setQuotaUser(quotaUser); } @Override public List setUploadType(java.lang.String uploadType) { return (List) super.setUploadType(uploadType); } @Override public List setUploadProtocol(java.lang.String uploadProtocol) { return (List) super.setUploadProtocol(uploadProtocol); } /** Name of the dataset. */ @com.google.api.client.util.Key private java.lang.String parent; /** Name of the dataset. */ public java.lang.String getParent() { return parent; } /** Name of the dataset. */ public List setParent(java.lang.String parent) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), "Parameter parent must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+$"); } this.parent = parent; return this; } /** * Restricts stores returned to those matching a filter. Syntax: * https://cloud.google.com/appengine/docs/standard/python/search/query_strings Only * filtering on labels is supported, for example `labels.key=value`. */ @com.google.api.client.util.Key private java.lang.String filter; /** Restricts stores returned to those matching a filter. Syntax: https://cloud.google.com/appengine/docs/standard/python/search/query_strings Only filtering on labels is supported, for example `labels.key=value`. */ public java.lang.String getFilter() { return filter; } /** * Restricts stores returned to those matching a filter. Syntax: * https://cloud.google.com/appengine/docs/standard/python/search/query_strings Only * filtering on labels is supported, for example `labels.key=value`. */ public List setFilter(java.lang.String filter) { this.filter = filter; return this; } /** * Limit on the number of FHIR stores to return in a single response. If zero the * default page size of 100 is used. */ @com.google.api.client.util.Key private java.lang.Integer pageSize; /** Limit on the number of FHIR stores to return in a single response. If zero the default page size of 100 is used. */ public java.lang.Integer getPageSize() { return pageSize; } /** * Limit on the number of FHIR stores to return in a single response. If zero the * default page size of 100 is used. */ public List setPageSize(java.lang.Integer pageSize) { this.pageSize = pageSize; return this; } /** The next_page_token value returned from the previous List request, if any. */ @com.google.api.client.util.Key private java.lang.String pageToken; /** The next_page_token value returned from the previous List request, if any. */ public java.lang.String getPageToken() { return pageToken; } /** The next_page_token value returned from the previous List request, if any. */ public List setPageToken(java.lang.String pageToken) { this.pageToken = pageToken; return this; } @Override public List set(String parameterName, Object value) { return (List) super.set(parameterName, value); } } /** * Updates the configuration of the specified FHIR store. * * Create a request for the method "fhirStores.patch". * * This request holds the parameters needed by the healthcare server. After setting any optional * parameters, call the {@link Patch#execute()} method to invoke the remote operation. * * @param name Output only. Resource name of the FHIR store, of the form * `projects/{project_id}/datasets/{dataset_id}/fhirStores/{fhir_store_id}`. * @param content the {@link com.google.api.services.healthcare.v1beta1.model.FhirStore} * @return the request */ public Patch patch(java.lang.String name, com.google.api.services.healthcare.v1beta1.model.FhirStore content) throws java.io.IOException { Patch result = new Patch(name, content); initialize(result); return result; } public class Patch extends CloudHealthcareRequest<com.google.api.services.healthcare.v1beta1.model.FhirStore> { private static final String REST_PATH = "v1beta1/{+name}"; private final java.util.regex.Pattern NAME_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/datasets/[^/]+/fhirStores/[^/]+$"); /** * Updates the configuration of the specified FHIR store. * * Create a request for the method "fhirStores.patch". * * This request holds the parameters needed by the the healthcare server. After setting any * optional parameters, call the {@link Patch#execute()} method to invoke the remote operation. * <p> {@link * Patch#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} must * be called to initialize this instance immediately after invoking the constructor. </p> * * @param name Output only. Resource name of the FHIR store, of the form * `projects/{project_id}/datasets/{dataset_id}/fhirStores/{fhir_store_id}`. * @param content the {@link com.google.api.services.healthcare.v1beta1.model.FhirStore} * @since 1.13 */ protected Patch(java.lang.String name, com.google.api.services.healthcare.v1beta1.model.FhirStore content) { super(CloudHealthcare.this, "PATCH", REST_PATH, content, com.google.api.services.healthcare.v1beta1.model.FhirStore.class); this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), "Parameter name must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/fhirStores/[^/]+$"); } } @Override public Patch set$Xgafv(java.lang.String $Xgafv) { return (Patch) super.set$Xgafv($Xgafv); } @Override public Patch setAccessToken(java.lang.String accessToken) { return (Patch) super.setAccessToken(accessToken); } @Override public Patch setAlt(java.lang.String alt) { return (Patch) super.setAlt(alt); } @Override public Patch setCallback(java.lang.String callback) { return (Patch) super.setCallback(callback); } @Override public Patch setFields(java.lang.String fields) { return (Patch) super.setFields(fields); } @Override public Patch setKey(java.lang.String key) { return (Patch) super.setKey(key); } @Override public Patch setOauthToken(java.lang.String oauthToken) { return (Patch) super.setOauthToken(oauthToken); } @Override public Patch setPrettyPrint(java.lang.Boolean prettyPrint) { return (Patch) super.setPrettyPrint(prettyPrint); } @Override public Patch setQuotaUser(java.lang.String quotaUser) { return (Patch) super.setQuotaUser(quotaUser); } @Override public Patch setUploadType(java.lang.String uploadType) { return (Patch) super.setUploadType(uploadType); } @Override public Patch setUploadProtocol(java.lang.String uploadProtocol) { return (Patch) super.setUploadProtocol(uploadProtocol); } /** * Output only. Resource name of the FHIR store, of the form * `projects/{project_id}/datasets/{dataset_id}/fhirStores/{fhir_store_id}`. */ @com.google.api.client.util.Key private java.lang.String name; /** Output only. Resource name of the FHIR store, of the form `projects/{project_id}/datasets/{dataset_id}/fhirStores/{fhir_store_id}`. */ public java.lang.String getName() { return name; } /** * Output only. Resource name of the FHIR store, of the form * `projects/{project_id}/datasets/{dataset_id}/fhirStores/{fhir_store_id}`. */ public Patch setName(java.lang.String name) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), "Parameter name must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/fhirStores/[^/]+$"); } this.name = name; return this; } /** * The update mask applies to the resource. For the `FieldMask` definition, see * https://developers.google.com/protocol- * buffers/docs/reference/google.protobuf#fieldmask */ @com.google.api.client.util.Key private String updateMask; /** The update mask applies to the resource. For the `FieldMask` definition, see https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#fieldmask */ public String getUpdateMask() { return updateMask; } /** * The update mask applies to the resource. For the `FieldMask` definition, see * https://developers.google.com/protocol- * buffers/docs/reference/google.protobuf#fieldmask */ public Patch setUpdateMask(String updateMask) { this.updateMask = updateMask; return this; } @Override public Patch set(String parameterName, Object value) { return (Patch) super.set(parameterName, value); } } /** * Sets the access control policy on the specified resource. Replaces any existing policy. * * Can return Public Errors: NOT_FOUND, INVALID_ARGUMENT and PERMISSION_DENIED * * Create a request for the method "fhirStores.setIamPolicy". * * This request holds the parameters needed by the healthcare server. After setting any optional * parameters, call the {@link SetIamPolicy#execute()} method to invoke the remote operation. * * @param resource REQUIRED: The resource for which the policy is being specified. See the operation documentation for * the appropriate value for this field. * @param content the {@link com.google.api.services.healthcare.v1beta1.model.SetIamPolicyRequest} * @return the request */ public SetIamPolicy setIamPolicy(java.lang.String resource, com.google.api.services.healthcare.v1beta1.model.SetIamPolicyRequest content) throws java.io.IOException { SetIamPolicy result = new SetIamPolicy(resource, content); initialize(result); return result; } public class SetIamPolicy extends CloudHealthcareRequest<com.google.api.services.healthcare.v1beta1.model.Policy> { private static final String REST_PATH = "v1beta1/{+resource}:setIamPolicy"; private final java.util.regex.Pattern RESOURCE_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/datasets/[^/]+/fhirStores/[^/]+$"); /** * Sets the access control policy on the specified resource. Replaces any existing policy. * * Can return Public Errors: NOT_FOUND, INVALID_ARGUMENT and PERMISSION_DENIED * * Create a request for the method "fhirStores.setIamPolicy". * * This request holds the parameters needed by the the healthcare server. After setting any * optional parameters, call the {@link SetIamPolicy#execute()} method to invoke the remote * operation. <p> {@link * SetIamPolicy#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} * must be called to initialize this instance immediately after invoking the constructor. </p> * * @param resource REQUIRED: The resource for which the policy is being specified. See the operation documentation for * the appropriate value for this field. * @param content the {@link com.google.api.services.healthcare.v1beta1.model.SetIamPolicyRequest} * @since 1.13 */ protected SetIamPolicy(java.lang.String resource, com.google.api.services.healthcare.v1beta1.model.SetIamPolicyRequest content) { super(CloudHealthcare.this, "POST", REST_PATH, content, com.google.api.services.healthcare.v1beta1.model.Policy.class); this.resource = com.google.api.client.util.Preconditions.checkNotNull(resource, "Required parameter resource must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(RESOURCE_PATTERN.matcher(resource).matches(), "Parameter resource must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/fhirStores/[^/]+$"); } } @Override public SetIamPolicy set$Xgafv(java.lang.String $Xgafv) { return (SetIamPolicy) super.set$Xgafv($Xgafv); } @Override public SetIamPolicy setAccessToken(java.lang.String accessToken) { return (SetIamPolicy) super.setAccessToken(accessToken); } @Override public SetIamPolicy setAlt(java.lang.String alt) { return (SetIamPolicy) super.setAlt(alt); } @Override public SetIamPolicy setCallback(java.lang.String callback) { return (SetIamPolicy) super.setCallback(callback); } @Override public SetIamPolicy setFields(java.lang.String fields) { return (SetIamPolicy) super.setFields(fields); } @Override public SetIamPolicy setKey(java.lang.String key) { return (SetIamPolicy) super.setKey(key); } @Override public SetIamPolicy setOauthToken(java.lang.String oauthToken) { return (SetIamPolicy) super.setOauthToken(oauthToken); } @Override public SetIamPolicy setPrettyPrint(java.lang.Boolean prettyPrint) { return (SetIamPolicy) super.setPrettyPrint(prettyPrint); } @Override public SetIamPolicy setQuotaUser(java.lang.String quotaUser) { return (SetIamPolicy) super.setQuotaUser(quotaUser); } @Override public SetIamPolicy setUploadType(java.lang.String uploadType) { return (SetIamPolicy) super.setUploadType(uploadType); } @Override public SetIamPolicy setUploadProtocol(java.lang.String uploadProtocol) { return (SetIamPolicy) super.setUploadProtocol(uploadProtocol); } /** * REQUIRED: The resource for which the policy is being specified. See the operation * documentation for the appropriate value for this field. */ @com.google.api.client.util.Key private java.lang.String resource; /** REQUIRED: The resource for which the policy is being specified. See the operation documentation for the appropriate value for this field. */ public java.lang.String getResource() { return resource; } /** * REQUIRED: The resource for which the policy is being specified. See the operation * documentation for the appropriate value for this field. */ public SetIamPolicy setResource(java.lang.String resource) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(RESOURCE_PATTERN.matcher(resource).matches(), "Parameter resource must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/fhirStores/[^/]+$"); } this.resource = resource; return this; } @Override public SetIamPolicy set(String parameterName, Object value) { return (SetIamPolicy) super.set(parameterName, value); } } /** * Returns permissions that a caller has on the specified resource. If the resource does not exist, * this will return an empty set of permissions, not a NOT_FOUND error. * * Note: This operation is designed to be used for building permission-aware UIs and command-line * tools, not for authorization checking. This operation may "fail open" without warning. * * Create a request for the method "fhirStores.testIamPermissions". * * This request holds the parameters needed by the healthcare server. After setting any optional * parameters, call the {@link TestIamPermissions#execute()} method to invoke the remote operation. * * @param resource REQUIRED: The resource for which the policy detail is being requested. See the operation * documentation for the appropriate value for this field. * @param content the {@link com.google.api.services.healthcare.v1beta1.model.TestIamPermissionsRequest} * @return the request */ public TestIamPermissions testIamPermissions(java.lang.String resource, com.google.api.services.healthcare.v1beta1.model.TestIamPermissionsRequest content) throws java.io.IOException { TestIamPermissions result = new TestIamPermissions(resource, content); initialize(result); return result; } public class TestIamPermissions extends CloudHealthcareRequest<com.google.api.services.healthcare.v1beta1.model.TestIamPermissionsResponse> { private static final String REST_PATH = "v1beta1/{+resource}:testIamPermissions"; private final java.util.regex.Pattern RESOURCE_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/datasets/[^/]+/fhirStores/[^/]+$"); /** * Returns permissions that a caller has on the specified resource. If the resource does not * exist, this will return an empty set of permissions, not a NOT_FOUND error. * * Note: This operation is designed to be used for building permission-aware UIs and command-line * tools, not for authorization checking. This operation may "fail open" without warning. * * Create a request for the method "fhirStores.testIamPermissions". * * This request holds the parameters needed by the the healthcare server. After setting any * optional parameters, call the {@link TestIamPermissions#execute()} method to invoke the remote * operation. <p> {@link TestIamPermissions#initialize(com.google.api.client.googleapis.services.A * bstractGoogleClientRequest)} must be called to initialize this instance immediately after * invoking the constructor. </p> * * @param resource REQUIRED: The resource for which the policy detail is being requested. See the operation * documentation for the appropriate value for this field. * @param content the {@link com.google.api.services.healthcare.v1beta1.model.TestIamPermissionsRequest} * @since 1.13 */ protected TestIamPermissions(java.lang.String resource, com.google.api.services.healthcare.v1beta1.model.TestIamPermissionsRequest content) { super(CloudHealthcare.this, "POST", REST_PATH, content, com.google.api.services.healthcare.v1beta1.model.TestIamPermissionsResponse.class); this.resource = com.google.api.client.util.Preconditions.checkNotNull(resource, "Required parameter resource must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(RESOURCE_PATTERN.matcher(resource).matches(), "Parameter resource must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/fhirStores/[^/]+$"); } } @Override public TestIamPermissions set$Xgafv(java.lang.String $Xgafv) { return (TestIamPermissions) super.set$Xgafv($Xgafv); } @Override public TestIamPermissions setAccessToken(java.lang.String accessToken) { return (TestIamPermissions) super.setAccessToken(accessToken); } @Override public TestIamPermissions setAlt(java.lang.String alt) { return (TestIamPermissions) super.setAlt(alt); } @Override public TestIamPermissions setCallback(java.lang.String callback) { return (TestIamPermissions) super.setCallback(callback); } @Override public TestIamPermissions setFields(java.lang.String fields) { return (TestIamPermissions) super.setFields(fields); } @Override public TestIamPermissions setKey(java.lang.String key) { return (TestIamPermissions) super.setKey(key); } @Override public TestIamPermissions setOauthToken(java.lang.String oauthToken) { return (TestIamPermissions) super.setOauthToken(oauthToken); } @Override public TestIamPermissions setPrettyPrint(java.lang.Boolean prettyPrint) { return (TestIamPermissions) super.setPrettyPrint(prettyPrint); } @Override public TestIamPermissions setQuotaUser(java.lang.String quotaUser) { return (TestIamPermissions) super.setQuotaUser(quotaUser); } @Override public TestIamPermissions setUploadType(java.lang.String uploadType) { return (TestIamPermissions) super.setUploadType(uploadType); } @Override public TestIamPermissions setUploadProtocol(java.lang.String uploadProtocol) { return (TestIamPermissions) super.setUploadProtocol(uploadProtocol); } /** * REQUIRED: The resource for which the policy detail is being requested. See the * operation documentation for the appropriate value for this field. */ @com.google.api.client.util.Key private java.lang.String resource; /** REQUIRED: The resource for which the policy detail is being requested. See the operation documentation for the appropriate value for this field. */ public java.lang.String getResource() { return resource; } /** * REQUIRED: The resource for which the policy detail is being requested. See the * operation documentation for the appropriate value for this field. */ public TestIamPermissions setResource(java.lang.String resource) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(RESOURCE_PATTERN.matcher(resource).matches(), "Parameter resource must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/fhirStores/[^/]+$"); } this.resource = resource; return this; } @Override public TestIamPermissions set(String parameterName, Object value) { return (TestIamPermissions) super.set(parameterName, value); } } /** * An accessor for creating requests from the Fhir collection. * * <p>The typical use is:</p> * <pre> * {@code CloudHealthcare healthcare = new CloudHealthcare(...);} * {@code CloudHealthcare.Fhir.List request = healthcare.fhir().list(parameters ...)} * </pre> * * @return the resource collection */ public Fhir fhir() { return new Fhir(); } /** * The "fhir" collection of methods. */ public class Fhir { /** * Retrieves the N most recent `Observation` resources for a subject matching search criteria * specified as query parameters, grouped by `Observation.code`, sorted from most recent to oldest. * * Implements the FHIR extended operation [Observation- * lastn](http://hl7.org/implement/standards/fhir/STU3/observation-operations.html#lastn). * * Search terms are provided as query parameters following the same pattern as the search method. * The following search parameters must be provided: * * - `subject` or `patient` to specify a subject for the Observation. - `code`, `category` * or any of the composite parameters that include `code`. * * Any other valid Observation search parameters can also be provided. This operation accepts an * additional query parameter `max`, which specifies N, the maximum number of Observations to return * from each group, with a default of 1. * * Searches with over 1000 results are rejected. Results are counted before grouping and limiting * the results with `max`. To stay within the limit, constrain these searches using Observation * search parameters such as `_lastUpdated` or `date`. * * On success, the response body will contain a JSON-encoded representation of a `Bundle` resource * of type `searchset`, containing the results of the operation. Errors generated by the FHIR store * will contain a JSON-encoded `OperationOutcome` resource describing the reason for the error. If * the request cannot be mapped to a valid API method on a FHIR store, a generic GCP error might be * returned instead. * * Create a request for the method "fhir.Observation-lastn". * * This request holds the parameters needed by the healthcare server. After setting any optional * parameters, call the {@link ObservationLastn#execute()} method to invoke the remote operation. * * @param parent Name of the FHIR store to retrieve resources from. * @return the request */ public ObservationLastn observationLastn(java.lang.String parent) throws java.io.IOException { ObservationLastn result = new ObservationLastn(parent); initialize(result); return result; } public class ObservationLastn extends CloudHealthcareRequest<com.google.api.services.healthcare.v1beta1.model.HttpBody> { private static final String REST_PATH = "v1beta1/{+parent}/fhir/Observation/$lastn"; private final java.util.regex.Pattern PARENT_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/datasets/[^/]+/fhirStores/[^/]+$"); /** * Retrieves the N most recent `Observation` resources for a subject matching search criteria * specified as query parameters, grouped by `Observation.code`, sorted from most recent to * oldest. * * Implements the FHIR extended operation [Observation- * lastn](http://hl7.org/implement/standards/fhir/STU3/observation-operations.html#lastn). * * Search terms are provided as query parameters following the same pattern as the search method. * The following search parameters must be provided: * * - `subject` or `patient` to specify a subject for the Observation. - `code`, `category` * or any of the composite parameters that include `code`. * * Any other valid Observation search parameters can also be provided. This operation accepts an * additional query parameter `max`, which specifies N, the maximum number of Observations to * return from each group, with a default of 1. * * Searches with over 1000 results are rejected. Results are counted before grouping and limiting * the results with `max`. To stay within the limit, constrain these searches using Observation * search parameters such as `_lastUpdated` or `date`. * * On success, the response body will contain a JSON-encoded representation of a `Bundle` resource * of type `searchset`, containing the results of the operation. Errors generated by the FHIR * store will contain a JSON-encoded `OperationOutcome` resource describing the reason for the * error. If the request cannot be mapped to a valid API method on a FHIR store, a generic GCP * error might be returned instead. * * Create a request for the method "fhir.Observation-lastn". * * This request holds the parameters needed by the the healthcare server. After setting any * optional parameters, call the {@link ObservationLastn#execute()} method to invoke the remote * operation. <p> {@link ObservationLastn#initialize(com.google.api.client.googleapis.services.Abs * tractGoogleClientRequest)} must be called to initialize this instance immediately after * invoking the constructor. </p> * * @param parent Name of the FHIR store to retrieve resources from. * @since 1.13 */ protected ObservationLastn(java.lang.String parent) { super(CloudHealthcare.this, "GET", REST_PATH, null, com.google.api.services.healthcare.v1beta1.model.HttpBody.class); this.parent = com.google.api.client.util.Preconditions.checkNotNull(parent, "Required parameter parent must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), "Parameter parent must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/fhirStores/[^/]+$"); } } @Override public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException { return super.executeUsingHead(); } @Override public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException { return super.buildHttpRequestUsingHead(); } @Override public ObservationLastn set$Xgafv(java.lang.String $Xgafv) { return (ObservationLastn) super.set$Xgafv($Xgafv); } @Override public ObservationLastn setAccessToken(java.lang.String accessToken) { return (ObservationLastn) super.setAccessToken(accessToken); } @Override public ObservationLastn setAlt(java.lang.String alt) { return (ObservationLastn) super.setAlt(alt); } @Override public ObservationLastn setCallback(java.lang.String callback) { return (ObservationLastn) super.setCallback(callback); } @Override public ObservationLastn setFields(java.lang.String fields) { return (ObservationLastn) super.setFields(fields); } @Override public ObservationLastn setKey(java.lang.String key) { return (ObservationLastn) super.setKey(key); } @Override public ObservationLastn setOauthToken(java.lang.String oauthToken) { return (ObservationLastn) super.setOauthToken(oauthToken); } @Override public ObservationLastn setPrettyPrint(java.lang.Boolean prettyPrint) { return (ObservationLastn) super.setPrettyPrint(prettyPrint); } @Override public ObservationLastn setQuotaUser(java.lang.String quotaUser) { return (ObservationLastn) super.setQuotaUser(quotaUser); } @Override public ObservationLastn setUploadType(java.lang.String uploadType) { return (ObservationLastn) super.setUploadType(uploadType); } @Override public ObservationLastn setUploadProtocol(java.lang.String uploadProtocol) { return (ObservationLastn) super.setUploadProtocol(uploadProtocol); } /** Name of the FHIR store to retrieve resources from. */ @com.google.api.client.util.Key private java.lang.String parent; /** Name of the FHIR store to retrieve resources from. */ public java.lang.String getParent() { return parent; } /** Name of the FHIR store to retrieve resources from. */ public ObservationLastn setParent(java.lang.String parent) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), "Parameter parent must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/fhirStores/[^/]+$"); } this.parent = parent; return this; } @Override public ObservationLastn set(String parameterName, Object value) { return (ObservationLastn) super.set(parameterName, value); } } /** * On success, the response body will contain a JSON-encoded representation of a `Bundle` resource * of type `searchset`, containing the results of the operation. Errors generated by the FHIR store * will contain a JSON-encoded `OperationOutcome` resource describing the reason for the error. If * the request cannot be mapped to a valid API method on a FHIR store, a generic GCP error might be * returned instead. * * Create a request for the method "fhir.Patient-everything". * * This request holds the parameters needed by the healthcare server. After setting any optional * parameters, call the {@link PatientEverything#execute()} method to invoke the remote operation. * * @param name Name of the `Patient` resource for which the information is required. * @return the request */ public PatientEverything patientEverything(java.lang.String name) throws java.io.IOException { PatientEverything result = new PatientEverything(name); initialize(result); return result; } public class PatientEverything extends CloudHealthcareRequest<com.google.api.services.healthcare.v1beta1.model.HttpBody> { private static final String REST_PATH = "v1beta1/{+name}/$everything"; private final java.util.regex.Pattern NAME_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/datasets/[^/]+/fhirStores/[^/]+/fhir/Patient/[^/]+$"); /** * On success, the response body will contain a JSON-encoded representation of a `Bundle` resource * of type `searchset`, containing the results of the operation. Errors generated by the FHIR * store will contain a JSON-encoded `OperationOutcome` resource describing the reason for the * error. If the request cannot be mapped to a valid API method on a FHIR store, a generic GCP * error might be returned instead. * * Create a request for the method "fhir.Patient-everything". * * This request holds the parameters needed by the the healthcare server. After setting any * optional parameters, call the {@link PatientEverything#execute()} method to invoke the remote * operation. <p> {@link PatientEverything#initialize(com.google.api.client.googleapis.services.Ab * stractGoogleClientRequest)} must be called to initialize this instance immediately after * invoking the constructor. </p> * * @param name Name of the `Patient` resource for which the information is required. * @since 1.13 */ protected PatientEverything(java.lang.String name) { super(CloudHealthcare.this, "GET", REST_PATH, null, com.google.api.services.healthcare.v1beta1.model.HttpBody.class); this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), "Parameter name must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/fhirStores/[^/]+/fhir/Patient/[^/]+$"); } } @Override public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException { return super.executeUsingHead(); } @Override public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException { return super.buildHttpRequestUsingHead(); } @Override public PatientEverything set$Xgafv(java.lang.String $Xgafv) { return (PatientEverything) super.set$Xgafv($Xgafv); } @Override public PatientEverything setAccessToken(java.lang.String accessToken) { return (PatientEverything) super.setAccessToken(accessToken); } @Override public PatientEverything setAlt(java.lang.String alt) { return (PatientEverything) super.setAlt(alt); } @Override public PatientEverything setCallback(java.lang.String callback) { return (PatientEverything) super.setCallback(callback); } @Override public PatientEverything setFields(java.lang.String fields) { return (PatientEverything) super.setFields(fields); } @Override public PatientEverything setKey(java.lang.String key) { return (PatientEverything) super.setKey(key); } @Override public PatientEverything setOauthToken(java.lang.String oauthToken) { return (PatientEverything) super.setOauthToken(oauthToken); } @Override public PatientEverything setPrettyPrint(java.lang.Boolean prettyPrint) { return (PatientEverything) super.setPrettyPrint(prettyPrint); } @Override public PatientEverything setQuotaUser(java.lang.String quotaUser) { return (PatientEverything) super.setQuotaUser(quotaUser); } @Override public PatientEverything setUploadType(java.lang.String uploadType) { return (PatientEverything) super.setUploadType(uploadType); } @Override public PatientEverything setUploadProtocol(java.lang.String uploadProtocol) { return (PatientEverything) super.setUploadProtocol(uploadProtocol); } /** Name of the `Patient` resource for which the information is required. */ @com.google.api.client.util.Key private java.lang.String name; /** Name of the `Patient` resource for which the information is required. */ public java.lang.String getName() { return name; } /** Name of the `Patient` resource for which the information is required. */ public PatientEverything setName(java.lang.String name) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), "Parameter name must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/fhirStores/[^/]+/fhir/Patient/[^/]+$"); } this.name = name; return this; } /** Maximum number of resources in a page. Defaults to 100. */ @com.google.api.client.util.Key("_count") private java.lang.Integer count; /** Maximum number of resources in a page. Defaults to 100. */ public java.lang.Integer getCount() { return count; } /** Maximum number of resources in a page. Defaults to 100. */ public PatientEverything setCount(java.lang.Integer count) { this.count = count; return this; } /** * Used to retrieve the next or previous page of results when using pagination. Value * should be set to the value of page_token set in next or previous page links' urls. * Next and previous page are returned in the response bundle's links field, where * `link.relation` is "previous" or "next". * * Omit `page_token` if no previous request has been made. */ @com.google.api.client.util.Key("_page_token") private java.lang.String pageToken; /** Used to retrieve the next or previous page of results when using pagination. Value should be set to the value of page_token set in next or previous page links' urls. Next and previous page are returned in the response bundle's links field, where `link.relation` is "previous" or "next". Omit `page_token` if no previous request has been made. */ public java.lang.String getPageToken() { return pageToken; } /** * Used to retrieve the next or previous page of results when using pagination. Value * should be set to the value of page_token set in next or previous page links' urls. * Next and previous page are returned in the response bundle's links field, where * `link.relation` is "previous" or "next". * * Omit `page_token` if no previous request has been made. */ public PatientEverything setPageToken(java.lang.String pageToken) { this.pageToken = pageToken; return this; } /** * The response includes records prior to the end date. If no end date is provided, * all records subsequent to the start date are in scope. */ @com.google.api.client.util.Key private java.lang.String end; /** The response includes records prior to the end date. If no end date is provided, all records subsequent to the start date are in scope. */ public java.lang.String getEnd() { return end; } /** * The response includes records prior to the end date. If no end date is provided, * all records subsequent to the start date are in scope. */ public PatientEverything setEnd(java.lang.String end) { this.end = end; return this; } /** * The response includes records subsequent to the start date. If no start date is * provided, all records prior to the end date are in scope. */ @com.google.api.client.util.Key private java.lang.String start; /** The response includes records subsequent to the start date. If no start date is provided, all records prior to the end date are in scope. */ public java.lang.String getStart() { return start; } /** * The response includes records subsequent to the start date. If no start date is * provided, all records prior to the end date are in scope. */ public PatientEverything setStart(java.lang.String start) { this.start = start; return this; } @Override public PatientEverything set(String parameterName, Object value) { return (PatientEverything) super.set(parameterName, value); } } /** * Deletes all the historical versions of a resource (excluding the current version) from the FHIR * store. To remove all versions of a resource, first delete the current version and then call this * method. * * This is not a FHIR standard operation. * * Create a request for the method "fhir.Resource-purge". * * This request holds the parameters needed by the healthcare server. After setting any optional * parameters, call the {@link ResourcePurge#execute()} method to invoke the remote operation. * * @param name The name of the resource to purge. * @return the request */ public ResourcePurge resourcePurge(java.lang.String name) throws java.io.IOException { ResourcePurge result = new ResourcePurge(name); initialize(result); return result; } public class ResourcePurge extends CloudHealthcareRequest<com.google.api.services.healthcare.v1beta1.model.Empty> { private static final String REST_PATH = "v1beta1/{+name}/$purge"; private final java.util.regex.Pattern NAME_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/datasets/[^/]+/fhirStores/[^/]+/fhir/[^/]+/[^/]+$"); /** * Deletes all the historical versions of a resource (excluding the current version) from the FHIR * store. To remove all versions of a resource, first delete the current version and then call * this method. * * This is not a FHIR standard operation. * * Create a request for the method "fhir.Resource-purge". * * This request holds the parameters needed by the the healthcare server. After setting any * optional parameters, call the {@link ResourcePurge#execute()} method to invoke the remote * operation. <p> {@link ResourcePurge#initialize(com.google.api.client.googleapis.services.Abstra * ctGoogleClientRequest)} must be called to initialize this instance immediately after invoking * the constructor. </p> * * @param name The name of the resource to purge. * @since 1.13 */ protected ResourcePurge(java.lang.String name) { super(CloudHealthcare.this, "DELETE", REST_PATH, null, com.google.api.services.healthcare.v1beta1.model.Empty.class); this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), "Parameter name must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/fhirStores/[^/]+/fhir/[^/]+/[^/]+$"); } } @Override public ResourcePurge set$Xgafv(java.lang.String $Xgafv) { return (ResourcePurge) super.set$Xgafv($Xgafv); } @Override public ResourcePurge setAccessToken(java.lang.String accessToken) { return (ResourcePurge) super.setAccessToken(accessToken); } @Override public ResourcePurge setAlt(java.lang.String alt) { return (ResourcePurge) super.setAlt(alt); } @Override public ResourcePurge setCallback(java.lang.String callback) { return (ResourcePurge) super.setCallback(callback); } @Override public ResourcePurge setFields(java.lang.String fields) { return (ResourcePurge) super.setFields(fields); } @Override public ResourcePurge setKey(java.lang.String key) { return (ResourcePurge) super.setKey(key); } @Override public ResourcePurge setOauthToken(java.lang.String oauthToken) { return (ResourcePurge) super.setOauthToken(oauthToken); } @Override public ResourcePurge setPrettyPrint(java.lang.Boolean prettyPrint) { return (ResourcePurge) super.setPrettyPrint(prettyPrint); } @Override public ResourcePurge setQuotaUser(java.lang.String quotaUser) { return (ResourcePurge) super.setQuotaUser(quotaUser); } @Override public ResourcePurge setUploadType(java.lang.String uploadType) { return (ResourcePurge) super.setUploadType(uploadType); } @Override public ResourcePurge setUploadProtocol(java.lang.String uploadProtocol) { return (ResourcePurge) super.setUploadProtocol(uploadProtocol); } /** The name of the resource to purge. */ @com.google.api.client.util.Key private java.lang.String name; /** The name of the resource to purge. */ public java.lang.String getName() { return name; } /** The name of the resource to purge. */ public ResourcePurge setName(java.lang.String name) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), "Parameter name must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/fhirStores/[^/]+/fhir/[^/]+/[^/]+$"); } this.name = name; return this; } @Override public ResourcePurge set(String parameterName, Object value) { return (ResourcePurge) super.set(parameterName, value); } } /** * Gets the FHIR [capability * statement](http://hl7.org/implement/standards/fhir/STU3/capabilitystatement.html) for the store, * which contains a description of functionality supported by the server. * * Implements the FHIR standard [capabilities * interaction](http://hl7.org/implement/standards/fhir/STU3/http.html#capabilities). * * On success, the response body will contain a JSON-encoded representation of a * `CapabilityStatement` resource. * * Create a request for the method "fhir.capabilities". * * This request holds the parameters needed by the healthcare server. After setting any optional * parameters, call the {@link Capabilities#execute()} method to invoke the remote operation. * * @param name Name of the FHIR store to retrieve the capabilities for. * @return the request */ public Capabilities capabilities(java.lang.String name) throws java.io.IOException { Capabilities result = new Capabilities(name); initialize(result); return result; } public class Capabilities extends CloudHealthcareRequest<com.google.api.services.healthcare.v1beta1.model.HttpBody> { private static final String REST_PATH = "v1beta1/{+name}/fhir/metadata"; private final java.util.regex.Pattern NAME_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/datasets/[^/]+/fhirStores/[^/]+$"); /** * Gets the FHIR [capability * statement](http://hl7.org/implement/standards/fhir/STU3/capabilitystatement.html) for the * store, which contains a description of functionality supported by the server. * * Implements the FHIR standard [capabilities * interaction](http://hl7.org/implement/standards/fhir/STU3/http.html#capabilities). * * On success, the response body will contain a JSON-encoded representation of a * `CapabilityStatement` resource. * * Create a request for the method "fhir.capabilities". * * This request holds the parameters needed by the the healthcare server. After setting any * optional parameters, call the {@link Capabilities#execute()} method to invoke the remote * operation. <p> {@link * Capabilities#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} * must be called to initialize this instance immediately after invoking the constructor. </p> * * @param name Name of the FHIR store to retrieve the capabilities for. * @since 1.13 */ protected Capabilities(java.lang.String name) { super(CloudHealthcare.this, "GET", REST_PATH, null, com.google.api.services.healthcare.v1beta1.model.HttpBody.class); this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), "Parameter name must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/fhirStores/[^/]+$"); } } @Override public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException { return super.executeUsingHead(); } @Override public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException { return super.buildHttpRequestUsingHead(); } @Override public Capabilities set$Xgafv(java.lang.String $Xgafv) { return (Capabilities) super.set$Xgafv($Xgafv); } @Override public Capabilities setAccessToken(java.lang.String accessToken) { return (Capabilities) super.setAccessToken(accessToken); } @Override public Capabilities setAlt(java.lang.String alt) { return (Capabilities) super.setAlt(alt); } @Override public Capabilities setCallback(java.lang.String callback) { return (Capabilities) super.setCallback(callback); } @Override public Capabilities setFields(java.lang.String fields) { return (Capabilities) super.setFields(fields); } @Override public Capabilities setKey(java.lang.String key) { return (Capabilities) super.setKey(key); } @Override public Capabilities setOauthToken(java.lang.String oauthToken) { return (Capabilities) super.setOauthToken(oauthToken); } @Override public Capabilities setPrettyPrint(java.lang.Boolean prettyPrint) { return (Capabilities) super.setPrettyPrint(prettyPrint); } @Override public Capabilities setQuotaUser(java.lang.String quotaUser) { return (Capabilities) super.setQuotaUser(quotaUser); } @Override public Capabilities setUploadType(java.lang.String uploadType) { return (Capabilities) super.setUploadType(uploadType); } @Override public Capabilities setUploadProtocol(java.lang.String uploadProtocol) { return (Capabilities) super.setUploadProtocol(uploadProtocol); } /** Name of the FHIR store to retrieve the capabilities for. */ @com.google.api.client.util.Key private java.lang.String name; /** Name of the FHIR store to retrieve the capabilities for. */ public java.lang.String getName() { return name; } /** Name of the FHIR store to retrieve the capabilities for. */ public Capabilities setName(java.lang.String name) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), "Parameter name must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/fhirStores/[^/]+$"); } this.name = name; return this; } @Override public Capabilities set(String parameterName, Object value) { return (Capabilities) super.set(parameterName, value); } } /** * Deletes FHIR resources that match a search query. * * Implements the FHIR standard [conditional delete * interaction](http://hl7.org/implement/standards/fhir/STU3/http.html#2.21.0.13.1). If multiple * resources match, all of them will be deleted. * * Search terms are provided as query parameters following the same pattern as the search method. * * Note: Unless resource versioning is disabled by setting the disable_resource_versioning flag on * the FHIR store, the deleted resources will be moved to a history repository that can still be * retrieved through vread and related methods, unless they are removed by the purge method. * * Create a request for the method "fhir.conditionalDelete". * * This request holds the parameters needed by the healthcare server. After setting any optional * parameters, call the {@link ConditionalDelete#execute()} method to invoke the remote operation. * * @param parent The name of the FHIR store this resource belongs to. * @param type The FHIR resource type to delete, such as Patient or Observation. For a complete list, see the [FHIR * Resource Index](http://hl7.org/implement/standards/fhir/STU3/resourcelist.html). * @return the request */ public ConditionalDelete conditionalDelete(java.lang.String parent, java.lang.String type) throws java.io.IOException { ConditionalDelete result = new ConditionalDelete(parent, type); initialize(result); return result; } public class ConditionalDelete extends CloudHealthcareRequest<com.google.api.services.healthcare.v1beta1.model.Empty> { private static final String REST_PATH = "v1beta1/{+parent}/fhir/{+type}"; private final java.util.regex.Pattern PARENT_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/datasets/[^/]+/fhirStores/[^/]+$"); private final java.util.regex.Pattern TYPE_PATTERN = java.util.regex.Pattern.compile("^[^/]+$"); /** * Deletes FHIR resources that match a search query. * * Implements the FHIR standard [conditional delete * interaction](http://hl7.org/implement/standards/fhir/STU3/http.html#2.21.0.13.1). If multiple * resources match, all of them will be deleted. * * Search terms are provided as query parameters following the same pattern as the search method. * * Note: Unless resource versioning is disabled by setting the disable_resource_versioning flag on * the FHIR store, the deleted resources will be moved to a history repository that can still be * retrieved through vread and related methods, unless they are removed by the purge method. * * Create a request for the method "fhir.conditionalDelete". * * This request holds the parameters needed by the the healthcare server. After setting any * optional parameters, call the {@link ConditionalDelete#execute()} method to invoke the remote * operation. <p> {@link ConditionalDelete#initialize(com.google.api.client.googleapis.services.Ab * stractGoogleClientRequest)} must be called to initialize this instance immediately after * invoking the constructor. </p> * * @param parent The name of the FHIR store this resource belongs to. * @param type The FHIR resource type to delete, such as Patient or Observation. For a complete list, see the [FHIR * Resource Index](http://hl7.org/implement/standards/fhir/STU3/resourcelist.html). * @since 1.13 */ protected ConditionalDelete(java.lang.String parent, java.lang.String type) { super(CloudHealthcare.this, "DELETE", REST_PATH, null, com.google.api.services.healthcare.v1beta1.model.Empty.class); this.parent = com.google.api.client.util.Preconditions.checkNotNull(parent, "Required parameter parent must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), "Parameter parent must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/fhirStores/[^/]+$"); } this.type = com.google.api.client.util.Preconditions.checkNotNull(type, "Required parameter type must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(TYPE_PATTERN.matcher(type).matches(), "Parameter type must conform to the pattern " + "^[^/]+$"); } } @Override public ConditionalDelete set$Xgafv(java.lang.String $Xgafv) { return (ConditionalDelete) super.set$Xgafv($Xgafv); } @Override public ConditionalDelete setAccessToken(java.lang.String accessToken) { return (ConditionalDelete) super.setAccessToken(accessToken); } @Override public ConditionalDelete setAlt(java.lang.String alt) { return (ConditionalDelete) super.setAlt(alt); } @Override public ConditionalDelete setCallback(java.lang.String callback) { return (ConditionalDelete) super.setCallback(callback); } @Override public ConditionalDelete setFields(java.lang.String fields) { return (ConditionalDelete) super.setFields(fields); } @Override public ConditionalDelete setKey(java.lang.String key) { return (ConditionalDelete) super.setKey(key); } @Override public ConditionalDelete setOauthToken(java.lang.String oauthToken) { return (ConditionalDelete) super.setOauthToken(oauthToken); } @Override public ConditionalDelete setPrettyPrint(java.lang.Boolean prettyPrint) { return (ConditionalDelete) super.setPrettyPrint(prettyPrint); } @Override public ConditionalDelete setQuotaUser(java.lang.String quotaUser) { return (ConditionalDelete) super.setQuotaUser(quotaUser); } @Override public ConditionalDelete setUploadType(java.lang.String uploadType) { return (ConditionalDelete) super.setUploadType(uploadType); } @Override public ConditionalDelete setUploadProtocol(java.lang.String uploadProtocol) { return (ConditionalDelete) super.setUploadProtocol(uploadProtocol); } /** The name of the FHIR store this resource belongs to. */ @com.google.api.client.util.Key private java.lang.String parent; /** The name of the FHIR store this resource belongs to. */ public java.lang.String getParent() { return parent; } /** The name of the FHIR store this resource belongs to. */ public ConditionalDelete setParent(java.lang.String parent) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), "Parameter parent must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/fhirStores/[^/]+$"); } this.parent = parent; return this; } /** * The FHIR resource type to delete, such as Patient or Observation. For a complete * list, see the [FHIR Resource * Index](http://hl7.org/implement/standards/fhir/STU3/resourcelist.html). */ @com.google.api.client.util.Key private java.lang.String type; /** The FHIR resource type to delete, such as Patient or Observation. For a complete list, see the [FHIR Resource Index](http://hl7.org/implement/standards/fhir/STU3/resourcelist.html). */ public java.lang.String getType() { return type; } /** * The FHIR resource type to delete, such as Patient or Observation. For a complete * list, see the [FHIR Resource * Index](http://hl7.org/implement/standards/fhir/STU3/resourcelist.html). */ public ConditionalDelete setType(java.lang.String type) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(TYPE_PATTERN.matcher(type).matches(), "Parameter type must conform to the pattern " + "^[^/]+$"); } this.type = type; return this; } @Override public ConditionalDelete set(String parameterName, Object value) { return (ConditionalDelete) super.set(parameterName, value); } } /** * If a resource is found based on the search criteria specified in the query parameters, updates * part of that resource by applying the operations specified in a [JSON * Patch](http://jsonpatch.com/) document. * * Implements the FHIR standard [conditional patch * interaction](http://hl7.org/implement/standards/fhir/STU3/http.html#patch). * * Search terms are provided as query parameters following the same pattern as the search method. * * If the search criteria identify more than one match, the request will return a `412 Precondition * Failed` error. * * The request body must contain a JSON Patch document, and the request headers must contain * `Content-Type: application/json-patch+json`. * * On success, the response body will contain a JSON-encoded representation of the updated resource, * including the server-assigned version ID. Errors generated by the FHIR store will contain a JSON- * encoded `OperationOutcome` resource describing the reason for the error. If the request cannot be * mapped to a valid API method on a FHIR store, a generic GCP error might be returned instead. * * Create a request for the method "fhir.conditionalPatch". * * This request holds the parameters needed by the healthcare server. After setting any optional * parameters, call the {@link ConditionalPatch#execute()} method to invoke the remote operation. * * @param parent The name of the FHIR store this resource belongs to. * @param type The FHIR resource type to update, such as Patient or Observation. For a complete list, see the [FHIR * Resource Index](http://hl7.org/implement/standards/fhir/STU3/resourcelist.html). * @param content the {@link com.google.api.services.healthcare.v1beta1.model.HttpBody} * @return the request */ public ConditionalPatch conditionalPatch(java.lang.String parent, java.lang.String type, com.google.api.services.healthcare.v1beta1.model.HttpBody content) throws java.io.IOException { ConditionalPatch result = new ConditionalPatch(parent, type, content); initialize(result); return result; } public class ConditionalPatch extends CloudHealthcareRequest<com.google.api.services.healthcare.v1beta1.model.HttpBody> { private static final String REST_PATH = "v1beta1/{+parent}/fhir/{+type}"; private final java.util.regex.Pattern PARENT_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/datasets/[^/]+/fhirStores/[^/]+$"); private final java.util.regex.Pattern TYPE_PATTERN = java.util.regex.Pattern.compile("^[^/]+$"); /** * If a resource is found based on the search criteria specified in the query parameters, updates * part of that resource by applying the operations specified in a [JSON * Patch](http://jsonpatch.com/) document. * * Implements the FHIR standard [conditional patch * interaction](http://hl7.org/implement/standards/fhir/STU3/http.html#patch). * * Search terms are provided as query parameters following the same pattern as the search method. * * If the search criteria identify more than one match, the request will return a `412 * Precondition Failed` error. * * The request body must contain a JSON Patch document, and the request headers must contain * `Content-Type: application/json-patch+json`. * * On success, the response body will contain a JSON-encoded representation of the updated * resource, including the server-assigned version ID. Errors generated by the FHIR store will * contain a JSON-encoded `OperationOutcome` resource describing the reason for the error. If the * request cannot be mapped to a valid API method on a FHIR store, a generic GCP error might be * returned instead. * * Create a request for the method "fhir.conditionalPatch". * * This request holds the parameters needed by the the healthcare server. After setting any * optional parameters, call the {@link ConditionalPatch#execute()} method to invoke the remote * operation. <p> {@link ConditionalPatch#initialize(com.google.api.client.googleapis.services.Abs * tractGoogleClientRequest)} must be called to initialize this instance immediately after * invoking the constructor. </p> * * @param parent The name of the FHIR store this resource belongs to. * @param type The FHIR resource type to update, such as Patient or Observation. For a complete list, see the [FHIR * Resource Index](http://hl7.org/implement/standards/fhir/STU3/resourcelist.html). * @param content the {@link com.google.api.services.healthcare.v1beta1.model.HttpBody} * @since 1.13 */ protected ConditionalPatch(java.lang.String parent, java.lang.String type, com.google.api.services.healthcare.v1beta1.model.HttpBody content) { super(CloudHealthcare.this, "PATCH", REST_PATH, content, com.google.api.services.healthcare.v1beta1.model.HttpBody.class); this.parent = com.google.api.client.util.Preconditions.checkNotNull(parent, "Required parameter parent must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), "Parameter parent must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/fhirStores/[^/]+$"); } this.type = com.google.api.client.util.Preconditions.checkNotNull(type, "Required parameter type must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(TYPE_PATTERN.matcher(type).matches(), "Parameter type must conform to the pattern " + "^[^/]+$"); } } @Override public ConditionalPatch set$Xgafv(java.lang.String $Xgafv) { return (ConditionalPatch) super.set$Xgafv($Xgafv); } @Override public ConditionalPatch setAccessToken(java.lang.String accessToken) { return (ConditionalPatch) super.setAccessToken(accessToken); } @Override public ConditionalPatch setAlt(java.lang.String alt) { return (ConditionalPatch) super.setAlt(alt); } @Override public ConditionalPatch setCallback(java.lang.String callback) { return (ConditionalPatch) super.setCallback(callback); } @Override public ConditionalPatch setFields(java.lang.String fields) { return (ConditionalPatch) super.setFields(fields); } @Override public ConditionalPatch setKey(java.lang.String key) { return (ConditionalPatch) super.setKey(key); } @Override public ConditionalPatch setOauthToken(java.lang.String oauthToken) { return (ConditionalPatch) super.setOauthToken(oauthToken); } @Override public ConditionalPatch setPrettyPrint(java.lang.Boolean prettyPrint) { return (ConditionalPatch) super.setPrettyPrint(prettyPrint); } @Override public ConditionalPatch setQuotaUser(java.lang.String quotaUser) { return (ConditionalPatch) super.setQuotaUser(quotaUser); } @Override public ConditionalPatch setUploadType(java.lang.String uploadType) { return (ConditionalPatch) super.setUploadType(uploadType); } @Override public ConditionalPatch setUploadProtocol(java.lang.String uploadProtocol) { return (ConditionalPatch) super.setUploadProtocol(uploadProtocol); } /** The name of the FHIR store this resource belongs to. */ @com.google.api.client.util.Key private java.lang.String parent; /** The name of the FHIR store this resource belongs to. */ public java.lang.String getParent() { return parent; } /** The name of the FHIR store this resource belongs to. */ public ConditionalPatch setParent(java.lang.String parent) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), "Parameter parent must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/fhirStores/[^/]+$"); } this.parent = parent; return this; } /** * The FHIR resource type to update, such as Patient or Observation. For a complete * list, see the [FHIR Resource * Index](http://hl7.org/implement/standards/fhir/STU3/resourcelist.html). */ @com.google.api.client.util.Key private java.lang.String type; /** The FHIR resource type to update, such as Patient or Observation. For a complete list, see the [FHIR Resource Index](http://hl7.org/implement/standards/fhir/STU3/resourcelist.html). */ public java.lang.String getType() { return type; } /** * The FHIR resource type to update, such as Patient or Observation. For a complete * list, see the [FHIR Resource * Index](http://hl7.org/implement/standards/fhir/STU3/resourcelist.html). */ public ConditionalPatch setType(java.lang.String type) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(TYPE_PATTERN.matcher(type).matches(), "Parameter type must conform to the pattern " + "^[^/]+$"); } this.type = type; return this; } @Override public ConditionalPatch set(String parameterName, Object value) { return (ConditionalPatch) super.set(parameterName, value); } } /** * If a resource is found based on the search criteria specified in the query parameters, updates * the entire contents of that resource. * * Implements the FHIR standard [conditional update * interaction](http://hl7.org/implement/standards/fhir/STU3/http.html#cond-update). * * Search terms are provided as query parameters following the same pattern as the search method. * * If the search criteria identify more than one match, the request will return a `412 Precondition * Failed` error. If the search criteria identify zero matches, and the supplied resource body * contains an `id`, and the FHIR store has enable_update_create set, creates the resource with the * client-specified ID. If the search criteria identify zero matches, and the supplied resource body * does not contain an `id`, the resource will be created with a server-assigned ID as per the * create method. * * The request body must contain a JSON-encoded FHIR resource, and the request headers must contain * `Content-Type: application/fhir+json`. * * On success, the response body will contain a JSON-encoded representation of the updated resource, * including the server-assigned version ID. Errors generated by the FHIR store will contain a JSON- * encoded `OperationOutcome` resource describing the reason for the error. If the request cannot be * mapped to a valid API method on a FHIR store, a generic GCP error might be returned instead. * * Create a request for the method "fhir.conditionalUpdate". * * This request holds the parameters needed by the healthcare server. After setting any optional * parameters, call the {@link ConditionalUpdate#execute()} method to invoke the remote operation. * * @param parent The name of the FHIR store this resource belongs to. * @param type The FHIR resource type to update, such as Patient or Observation. For a complete list, see the [FHIR * Resource Index](http://hl7.org/implement/standards/fhir/STU3/resourcelist.html). Must * match the resource type in the provided content. * @param content the {@link com.google.api.services.healthcare.v1beta1.model.HttpBody} * @return the request */ public ConditionalUpdate conditionalUpdate(java.lang.String parent, java.lang.String type, com.google.api.services.healthcare.v1beta1.model.HttpBody content) throws java.io.IOException { ConditionalUpdate result = new ConditionalUpdate(parent, type, content); initialize(result); return result; } public class ConditionalUpdate extends CloudHealthcareRequest<com.google.api.services.healthcare.v1beta1.model.HttpBody> { private static final String REST_PATH = "v1beta1/{+parent}/fhir/{+type}"; private final java.util.regex.Pattern PARENT_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/datasets/[^/]+/fhirStores/[^/]+$"); private final java.util.regex.Pattern TYPE_PATTERN = java.util.regex.Pattern.compile("^[^/]+$"); /** * If a resource is found based on the search criteria specified in the query parameters, updates * the entire contents of that resource. * * Implements the FHIR standard [conditional update * interaction](http://hl7.org/implement/standards/fhir/STU3/http.html#cond-update). * * Search terms are provided as query parameters following the same pattern as the search method. * * If the search criteria identify more than one match, the request will return a `412 * Precondition Failed` error. If the search criteria identify zero matches, and the supplied * resource body contains an `id`, and the FHIR store has enable_update_create set, creates the * resource with the client-specified ID. If the search criteria identify zero matches, and the * supplied resource body does not contain an `id`, the resource will be created with a server- * assigned ID as per the create method. * * The request body must contain a JSON-encoded FHIR resource, and the request headers must * contain `Content-Type: application/fhir+json`. * * On success, the response body will contain a JSON-encoded representation of the updated * resource, including the server-assigned version ID. Errors generated by the FHIR store will * contain a JSON-encoded `OperationOutcome` resource describing the reason for the error. If the * request cannot be mapped to a valid API method on a FHIR store, a generic GCP error might be * returned instead. * * Create a request for the method "fhir.conditionalUpdate". * * This request holds the parameters needed by the the healthcare server. After setting any * optional parameters, call the {@link ConditionalUpdate#execute()} method to invoke the remote * operation. <p> {@link ConditionalUpdate#initialize(com.google.api.client.googleapis.services.Ab * stractGoogleClientRequest)} must be called to initialize this instance immediately after * invoking the constructor. </p> * * @param parent The name of the FHIR store this resource belongs to. * @param type The FHIR resource type to update, such as Patient or Observation. For a complete list, see the [FHIR * Resource Index](http://hl7.org/implement/standards/fhir/STU3/resourcelist.html). Must * match the resource type in the provided content. * @param content the {@link com.google.api.services.healthcare.v1beta1.model.HttpBody} * @since 1.13 */ protected ConditionalUpdate(java.lang.String parent, java.lang.String type, com.google.api.services.healthcare.v1beta1.model.HttpBody content) { super(CloudHealthcare.this, "PUT", REST_PATH, content, com.google.api.services.healthcare.v1beta1.model.HttpBody.class); this.parent = com.google.api.client.util.Preconditions.checkNotNull(parent, "Required parameter parent must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), "Parameter parent must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/fhirStores/[^/]+$"); } this.type = com.google.api.client.util.Preconditions.checkNotNull(type, "Required parameter type must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(TYPE_PATTERN.matcher(type).matches(), "Parameter type must conform to the pattern " + "^[^/]+$"); } } @Override public ConditionalUpdate set$Xgafv(java.lang.String $Xgafv) { return (ConditionalUpdate) super.set$Xgafv($Xgafv); } @Override public ConditionalUpdate setAccessToken(java.lang.String accessToken) { return (ConditionalUpdate) super.setAccessToken(accessToken); } @Override public ConditionalUpdate setAlt(java.lang.String alt) { return (ConditionalUpdate) super.setAlt(alt); } @Override public ConditionalUpdate setCallback(java.lang.String callback) { return (ConditionalUpdate) super.setCallback(callback); } @Override public ConditionalUpdate setFields(java.lang.String fields) { return (ConditionalUpdate) super.setFields(fields); } @Override public ConditionalUpdate setKey(java.lang.String key) { return (ConditionalUpdate) super.setKey(key); } @Override public ConditionalUpdate setOauthToken(java.lang.String oauthToken) { return (ConditionalUpdate) super.setOauthToken(oauthToken); } @Override public ConditionalUpdate setPrettyPrint(java.lang.Boolean prettyPrint) { return (ConditionalUpdate) super.setPrettyPrint(prettyPrint); } @Override public ConditionalUpdate setQuotaUser(java.lang.String quotaUser) { return (ConditionalUpdate) super.setQuotaUser(quotaUser); } @Override public ConditionalUpdate setUploadType(java.lang.String uploadType) { return (ConditionalUpdate) super.setUploadType(uploadType); } @Override public ConditionalUpdate setUploadProtocol(java.lang.String uploadProtocol) { return (ConditionalUpdate) super.setUploadProtocol(uploadProtocol); } /** The name of the FHIR store this resource belongs to. */ @com.google.api.client.util.Key private java.lang.String parent; /** The name of the FHIR store this resource belongs to. */ public java.lang.String getParent() { return parent; } /** The name of the FHIR store this resource belongs to. */ public ConditionalUpdate setParent(java.lang.String parent) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), "Parameter parent must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/fhirStores/[^/]+$"); } this.parent = parent; return this; } /** * The FHIR resource type to update, such as Patient or Observation. For a complete * list, see the [FHIR Resource * Index](http://hl7.org/implement/standards/fhir/STU3/resourcelist.html). Must match * the resource type in the provided content. */ @com.google.api.client.util.Key private java.lang.String type; /** The FHIR resource type to update, such as Patient or Observation. For a complete list, see the [FHIR Resource Index](http://hl7.org/implement/standards/fhir/STU3/resourcelist.html). Must match the resource type in the provided content. */ public java.lang.String getType() { return type; } /** * The FHIR resource type to update, such as Patient or Observation. For a complete * list, see the [FHIR Resource * Index](http://hl7.org/implement/standards/fhir/STU3/resourcelist.html). Must match * the resource type in the provided content. */ public ConditionalUpdate setType(java.lang.String type) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(TYPE_PATTERN.matcher(type).matches(), "Parameter type must conform to the pattern " + "^[^/]+$"); } this.type = type; return this; } @Override public ConditionalUpdate set(String parameterName, Object value) { return (ConditionalUpdate) super.set(parameterName, value); } } /** * Creates a FHIR resource. * * Implements the FHIR standard [create * interaction](http://hl7.org/implement/standards/fhir/STU3/http.html#create), which creates a new * resource with a server-assigned resource ID. * * Also supports the FHIR standard [conditional create * interaction](http://hl7.org/implement/standards/fhir/STU3/http.html#ccreate), specified by * supplying an `If-None-Exist` header containing a FHIR search query. If no resources match this * search query, the server processes the create operation as normal. * * The request body must contain a JSON-encoded FHIR resource, and the request headers must contain * `Content-Type: application/fhir+json`. * * On success, the response body will contain a JSON-encoded representation of the resource as it * was created on the server, including the server-assigned resource ID and version ID. Errors * generated by the FHIR store will contain a JSON-encoded `OperationOutcome` resource describing * the reason for the error. If the request cannot be mapped to a valid API method on a FHIR store, * a generic GCP error might be returned instead. * * Create a request for the method "fhir.create". * * This request holds the parameters needed by the healthcare server. After setting any optional * parameters, call the {@link Create#execute()} method to invoke the remote operation. * * @param parent The name of the FHIR store this resource belongs to. * @param type The FHIR resource type to create, such as Patient or Observation. For a complete list, see the [FHIR * Resource Index](http://hl7.org/implement/standards/fhir/STU3/resourcelist.html). Must * match the resource type in the provided content. * @param content the {@link com.google.api.services.healthcare.v1beta1.model.HttpBody} * @return the request */ public Create create(java.lang.String parent, java.lang.String type, com.google.api.services.healthcare.v1beta1.model.HttpBody content) throws java.io.IOException { Create result = new Create(parent, type, content); initialize(result); return result; } public class Create extends CloudHealthcareRequest<com.google.api.services.healthcare.v1beta1.model.HttpBody> { private static final String REST_PATH = "v1beta1/{+parent}/fhir/{+type}"; private final java.util.regex.Pattern PARENT_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/datasets/[^/]+/fhirStores/[^/]+$"); private final java.util.regex.Pattern TYPE_PATTERN = java.util.regex.Pattern.compile("^[^/]+$"); /** * Creates a FHIR resource. * * Implements the FHIR standard [create * interaction](http://hl7.org/implement/standards/fhir/STU3/http.html#create), which creates a * new resource with a server-assigned resource ID. * * Also supports the FHIR standard [conditional create * interaction](http://hl7.org/implement/standards/fhir/STU3/http.html#ccreate), specified by * supplying an `If-None-Exist` header containing a FHIR search query. If no resources match this * search query, the server processes the create operation as normal. * * The request body must contain a JSON-encoded FHIR resource, and the request headers must * contain `Content-Type: application/fhir+json`. * * On success, the response body will contain a JSON-encoded representation of the resource as it * was created on the server, including the server-assigned resource ID and version ID. Errors * generated by the FHIR store will contain a JSON-encoded `OperationOutcome` resource describing * the reason for the error. If the request cannot be mapped to a valid API method on a FHIR * store, a generic GCP error might be returned instead. * * Create a request for the method "fhir.create". * * This request holds the parameters needed by the the healthcare server. After setting any * optional parameters, call the {@link Create#execute()} method to invoke the remote operation. * <p> {@link * Create#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} must * be called to initialize this instance immediately after invoking the constructor. </p> * * @param parent The name of the FHIR store this resource belongs to. * @param type The FHIR resource type to create, such as Patient or Observation. For a complete list, see the [FHIR * Resource Index](http://hl7.org/implement/standards/fhir/STU3/resourcelist.html). Must * match the resource type in the provided content. * @param content the {@link com.google.api.services.healthcare.v1beta1.model.HttpBody} * @since 1.13 */ protected Create(java.lang.String parent, java.lang.String type, com.google.api.services.healthcare.v1beta1.model.HttpBody content) { super(CloudHealthcare.this, "POST", REST_PATH, content, com.google.api.services.healthcare.v1beta1.model.HttpBody.class); this.parent = com.google.api.client.util.Preconditions.checkNotNull(parent, "Required parameter parent must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), "Parameter parent must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/fhirStores/[^/]+$"); } this.type = com.google.api.client.util.Preconditions.checkNotNull(type, "Required parameter type must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(TYPE_PATTERN.matcher(type).matches(), "Parameter type must conform to the pattern " + "^[^/]+$"); } } @Override public Create set$Xgafv(java.lang.String $Xgafv) { return (Create) super.set$Xgafv($Xgafv); } @Override public Create setAccessToken(java.lang.String accessToken) { return (Create) super.setAccessToken(accessToken); } @Override public Create setAlt(java.lang.String alt) { return (Create) super.setAlt(alt); } @Override public Create setCallback(java.lang.String callback) { return (Create) super.setCallback(callback); } @Override public Create setFields(java.lang.String fields) { return (Create) super.setFields(fields); } @Override public Create setKey(java.lang.String key) { return (Create) super.setKey(key); } @Override public Create setOauthToken(java.lang.String oauthToken) { return (Create) super.setOauthToken(oauthToken); } @Override public Create setPrettyPrint(java.lang.Boolean prettyPrint) { return (Create) super.setPrettyPrint(prettyPrint); } @Override public Create setQuotaUser(java.lang.String quotaUser) { return (Create) super.setQuotaUser(quotaUser); } @Override public Create setUploadType(java.lang.String uploadType) { return (Create) super.setUploadType(uploadType); } @Override public Create setUploadProtocol(java.lang.String uploadProtocol) { return (Create) super.setUploadProtocol(uploadProtocol); } /** The name of the FHIR store this resource belongs to. */ @com.google.api.client.util.Key private java.lang.String parent; /** The name of the FHIR store this resource belongs to. */ public java.lang.String getParent() { return parent; } /** The name of the FHIR store this resource belongs to. */ public Create setParent(java.lang.String parent) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), "Parameter parent must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/fhirStores/[^/]+$"); } this.parent = parent; return this; } /** * The FHIR resource type to create, such as Patient or Observation. For a complete * list, see the [FHIR Resource * Index](http://hl7.org/implement/standards/fhir/STU3/resourcelist.html). Must match * the resource type in the provided content. */ @com.google.api.client.util.Key private java.lang.String type; /** The FHIR resource type to create, such as Patient or Observation. For a complete list, see the [FHIR Resource Index](http://hl7.org/implement/standards/fhir/STU3/resourcelist.html). Must match the resource type in the provided content. */ public java.lang.String getType() { return type; } /** * The FHIR resource type to create, such as Patient or Observation. For a complete * list, see the [FHIR Resource * Index](http://hl7.org/implement/standards/fhir/STU3/resourcelist.html). Must match * the resource type in the provided content. */ public Create setType(java.lang.String type) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(TYPE_PATTERN.matcher(type).matches(), "Parameter type must conform to the pattern " + "^[^/]+$"); } this.type = type; return this; } @Override public Create set(String parameterName, Object value) { return (Create) super.set(parameterName, value); } } /** * Deletes a FHIR resource. * * Implements the FHIR standard [delete * interaction](http://hl7.org/implement/standards/fhir/STU3/http.html#delete). * * Note: Unless resource versioning is disabled by setting the disable_resource_versioning flag on * the FHIR store, the deleted resources will be moved to a history repository that can still be * retrieved through vread and related methods, unless they are removed by the purge method. * * Create a request for the method "fhir.delete". * * This request holds the parameters needed by the healthcare server. After setting any optional * parameters, call the {@link Delete#execute()} method to invoke the remote operation. * * @param name The name of the resource to delete. * @return the request */ public Delete delete(java.lang.String name) throws java.io.IOException { Delete result = new Delete(name); initialize(result); return result; } public class Delete extends CloudHealthcareRequest<com.google.api.services.healthcare.v1beta1.model.HttpBody> { private static final String REST_PATH = "v1beta1/{+name}"; private final java.util.regex.Pattern NAME_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/datasets/[^/]+/fhirStores/[^/]+/fhir/[^/]+/[^/]+$"); /** * Deletes a FHIR resource. * * Implements the FHIR standard [delete * interaction](http://hl7.org/implement/standards/fhir/STU3/http.html#delete). * * Note: Unless resource versioning is disabled by setting the disable_resource_versioning flag on * the FHIR store, the deleted resources will be moved to a history repository that can still be * retrieved through vread and related methods, unless they are removed by the purge method. * * Create a request for the method "fhir.delete". * * This request holds the parameters needed by the the healthcare server. After setting any * optional parameters, call the {@link Delete#execute()} method to invoke the remote operation. * <p> {@link * Delete#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} must * be called to initialize this instance immediately after invoking the constructor. </p> * * @param name The name of the resource to delete. * @since 1.13 */ protected Delete(java.lang.String name) { super(CloudHealthcare.this, "DELETE", REST_PATH, null, com.google.api.services.healthcare.v1beta1.model.HttpBody.class); this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), "Parameter name must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/fhirStores/[^/]+/fhir/[^/]+/[^/]+$"); } } @Override public Delete set$Xgafv(java.lang.String $Xgafv) { return (Delete) super.set$Xgafv($Xgafv); } @Override public Delete setAccessToken(java.lang.String accessToken) { return (Delete) super.setAccessToken(accessToken); } @Override public Delete setAlt(java.lang.String alt) { return (Delete) super.setAlt(alt); } @Override public Delete setCallback(java.lang.String callback) { return (Delete) super.setCallback(callback); } @Override public Delete setFields(java.lang.String fields) { return (Delete) super.setFields(fields); } @Override public Delete setKey(java.lang.String key) { return (Delete) super.setKey(key); } @Override public Delete setOauthToken(java.lang.String oauthToken) { return (Delete) super.setOauthToken(oauthToken); } @Override public Delete setPrettyPrint(java.lang.Boolean prettyPrint) { return (Delete) super.setPrettyPrint(prettyPrint); } @Override public Delete setQuotaUser(java.lang.String quotaUser) { return (Delete) super.setQuotaUser(quotaUser); } @Override public Delete setUploadType(java.lang.String uploadType) { return (Delete) super.setUploadType(uploadType); } @Override public Delete setUploadProtocol(java.lang.String uploadProtocol) { return (Delete) super.setUploadProtocol(uploadProtocol); } /** The name of the resource to delete. */ @com.google.api.client.util.Key private java.lang.String name; /** The name of the resource to delete. */ public java.lang.String getName() { return name; } /** The name of the resource to delete. */ public Delete setName(java.lang.String name) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), "Parameter name must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/fhirStores/[^/]+/fhir/[^/]+/[^/]+$"); } this.name = name; return this; } @Override public Delete set(String parameterName, Object value) { return (Delete) super.set(parameterName, value); } } /** * Executes all the requests in the given Bundle. * * Implements the FHIR standard [batch/transaction * interaction](http://hl7.org/implement/standards/fhir/STU3/http.html#transaction). * * Supports all interactions within a bundle, except search. This method accepts Bundles of type * `batch` and `transaction`, processing them according to the [batch processing * rules](http://hl7.org/implement/standards/fhir/STU3/http.html#2.21.0.17.1) and [transaction * processing rules](http://hl7.org/implement/standards/fhir/STU3/http.html#2.21.0.17.2). * * The request body must contain a JSON-encoded FHIR `Bundle` resource, and the request headers must * contain `Content-Type: application/fhir+json`. * * For a batch bundle or a successful transaction the response body will contain a JSON-encoded * representation of a `Bundle` resource of type `batch-response` or `transaction-response` * containing one entry for each entry in the request, with the outcome of processing the entry. In * the case of an error for a transaction bundle, the response body will contain a JSON-encoded * `OperationOutcome` resource describing the reason for the error. If the request cannot be mapped * to a valid API method on a FHIR store, a generic GCP error might be returned instead. * * Create a request for the method "fhir.executeBundle". * * This request holds the parameters needed by the healthcare server. After setting any optional * parameters, call the {@link ExecuteBundle#execute()} method to invoke the remote operation. * * @param parent Name of the FHIR store in which this bundle will be executed. * @param content the {@link com.google.api.services.healthcare.v1beta1.model.HttpBody} * @return the request */ public ExecuteBundle executeBundle(java.lang.String parent, com.google.api.services.healthcare.v1beta1.model.HttpBody content) throws java.io.IOException { ExecuteBundle result = new ExecuteBundle(parent, content); initialize(result); return result; } public class ExecuteBundle extends CloudHealthcareRequest<com.google.api.services.healthcare.v1beta1.model.HttpBody> { private static final String REST_PATH = "v1beta1/{+parent}/fhir"; private final java.util.regex.Pattern PARENT_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/datasets/[^/]+/fhirStores/[^/]+$"); /** * Executes all the requests in the given Bundle. * * Implements the FHIR standard [batch/transaction * interaction](http://hl7.org/implement/standards/fhir/STU3/http.html#transaction). * * Supports all interactions within a bundle, except search. This method accepts Bundles of type * `batch` and `transaction`, processing them according to the [batch processing * rules](http://hl7.org/implement/standards/fhir/STU3/http.html#2.21.0.17.1) and [transaction * processing rules](http://hl7.org/implement/standards/fhir/STU3/http.html#2.21.0.17.2). * * The request body must contain a JSON-encoded FHIR `Bundle` resource, and the request headers * must contain `Content-Type: application/fhir+json`. * * For a batch bundle or a successful transaction the response body will contain a JSON-encoded * representation of a `Bundle` resource of type `batch-response` or `transaction-response` * containing one entry for each entry in the request, with the outcome of processing the entry. * In the case of an error for a transaction bundle, the response body will contain a JSON-encoded * `OperationOutcome` resource describing the reason for the error. If the request cannot be * mapped to a valid API method on a FHIR store, a generic GCP error might be returned instead. * * Create a request for the method "fhir.executeBundle". * * This request holds the parameters needed by the the healthcare server. After setting any * optional parameters, call the {@link ExecuteBundle#execute()} method to invoke the remote * operation. <p> {@link ExecuteBundle#initialize(com.google.api.client.googleapis.services.Abstra * ctGoogleClientRequest)} must be called to initialize this instance immediately after invoking * the constructor. </p> * * @param parent Name of the FHIR store in which this bundle will be executed. * @param content the {@link com.google.api.services.healthcare.v1beta1.model.HttpBody} * @since 1.13 */ protected ExecuteBundle(java.lang.String parent, com.google.api.services.healthcare.v1beta1.model.HttpBody content) { super(CloudHealthcare.this, "POST", REST_PATH, content, com.google.api.services.healthcare.v1beta1.model.HttpBody.class); this.parent = com.google.api.client.util.Preconditions.checkNotNull(parent, "Required parameter parent must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), "Parameter parent must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/fhirStores/[^/]+$"); } } @Override public ExecuteBundle set$Xgafv(java.lang.String $Xgafv) { return (ExecuteBundle) super.set$Xgafv($Xgafv); } @Override public ExecuteBundle setAccessToken(java.lang.String accessToken) { return (ExecuteBundle) super.setAccessToken(accessToken); } @Override public ExecuteBundle setAlt(java.lang.String alt) { return (ExecuteBundle) super.setAlt(alt); } @Override public ExecuteBundle setCallback(java.lang.String callback) { return (ExecuteBundle) super.setCallback(callback); } @Override public ExecuteBundle setFields(java.lang.String fields) { return (ExecuteBundle) super.setFields(fields); } @Override public ExecuteBundle setKey(java.lang.String key) { return (ExecuteBundle) super.setKey(key); } @Override public ExecuteBundle setOauthToken(java.lang.String oauthToken) { return (ExecuteBundle) super.setOauthToken(oauthToken); } @Override public ExecuteBundle setPrettyPrint(java.lang.Boolean prettyPrint) { return (ExecuteBundle) super.setPrettyPrint(prettyPrint); } @Override public ExecuteBundle setQuotaUser(java.lang.String quotaUser) { return (ExecuteBundle) super.setQuotaUser(quotaUser); } @Override public ExecuteBundle setUploadType(java.lang.String uploadType) { return (ExecuteBundle) super.setUploadType(uploadType); } @Override public ExecuteBundle setUploadProtocol(java.lang.String uploadProtocol) { return (ExecuteBundle) super.setUploadProtocol(uploadProtocol); } /** Name of the FHIR store in which this bundle will be executed. */ @com.google.api.client.util.Key private java.lang.String parent; /** Name of the FHIR store in which this bundle will be executed. */ public java.lang.String getParent() { return parent; } /** Name of the FHIR store in which this bundle will be executed. */ public ExecuteBundle setParent(java.lang.String parent) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), "Parameter parent must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/fhirStores/[^/]+$"); } this.parent = parent; return this; } @Override public ExecuteBundle set(String parameterName, Object value) { return (ExecuteBundle) super.set(parameterName, value); } } /** * Lists all the versions of a resource (including the current version and deleted versions) from * the FHIR store. * * Implements the per-resource form of the FHIR standard [history * interaction](http://hl7.org/implement/standards/fhir/STU3/http.html#history). * * On success, the response body will contain a JSON-encoded representation of a `Bundle` resource * of type `history`, containing the version history sorted from most recent to oldest versions. * Errors generated by the FHIR store will contain a JSON-encoded `OperationOutcome` resource * describing the reason for the error. If the request cannot be mapped to a valid API method on a * FHIR store, a generic GCP error might be returned instead. * * Create a request for the method "fhir.history". * * This request holds the parameters needed by the healthcare server. After setting any optional * parameters, call the {@link History#execute()} method to invoke the remote operation. * * @param name The name of the resource to retrieve. * @return the request */ public History history(java.lang.String name) throws java.io.IOException { History result = new History(name); initialize(result); return result; } public class History extends CloudHealthcareRequest<com.google.api.services.healthcare.v1beta1.model.HttpBody> { private static final String REST_PATH = "v1beta1/{+name}/_history"; private final java.util.regex.Pattern NAME_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/datasets/[^/]+/fhirStores/[^/]+/fhir/[^/]+/[^/]+$"); /** * Lists all the versions of a resource (including the current version and deleted versions) from * the FHIR store. * * Implements the per-resource form of the FHIR standard [history * interaction](http://hl7.org/implement/standards/fhir/STU3/http.html#history). * * On success, the response body will contain a JSON-encoded representation of a `Bundle` resource * of type `history`, containing the version history sorted from most recent to oldest versions. * Errors generated by the FHIR store will contain a JSON-encoded `OperationOutcome` resource * describing the reason for the error. If the request cannot be mapped to a valid API method on a * FHIR store, a generic GCP error might be returned instead. * * Create a request for the method "fhir.history". * * This request holds the parameters needed by the the healthcare server. After setting any * optional parameters, call the {@link History#execute()} method to invoke the remote operation. * <p> {@link * History#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} must * be called to initialize this instance immediately after invoking the constructor. </p> * * @param name The name of the resource to retrieve. * @since 1.13 */ protected History(java.lang.String name) { super(CloudHealthcare.this, "GET", REST_PATH, null, com.google.api.services.healthcare.v1beta1.model.HttpBody.class); this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), "Parameter name must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/fhirStores/[^/]+/fhir/[^/]+/[^/]+$"); } } @Override public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException { return super.executeUsingHead(); } @Override public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException { return super.buildHttpRequestUsingHead(); } @Override public History set$Xgafv(java.lang.String $Xgafv) { return (History) super.set$Xgafv($Xgafv); } @Override public History setAccessToken(java.lang.String accessToken) { return (History) super.setAccessToken(accessToken); } @Override public History setAlt(java.lang.String alt) { return (History) super.setAlt(alt); } @Override public History setCallback(java.lang.String callback) { return (History) super.setCallback(callback); } @Override public History setFields(java.lang.String fields) { return (History) super.setFields(fields); } @Override public History setKey(java.lang.String key) { return (History) super.setKey(key); } @Override public History setOauthToken(java.lang.String oauthToken) { return (History) super.setOauthToken(oauthToken); } @Override public History setPrettyPrint(java.lang.Boolean prettyPrint) { return (History) super.setPrettyPrint(prettyPrint); } @Override public History setQuotaUser(java.lang.String quotaUser) { return (History) super.setQuotaUser(quotaUser); } @Override public History setUploadType(java.lang.String uploadType) { return (History) super.setUploadType(uploadType); } @Override public History setUploadProtocol(java.lang.String uploadProtocol) { return (History) super.setUploadProtocol(uploadProtocol); } /** The name of the resource to retrieve. */ @com.google.api.client.util.Key private java.lang.String name; /** The name of the resource to retrieve. */ public java.lang.String getName() { return name; } /** The name of the resource to retrieve. */ public History setName(java.lang.String name) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), "Parameter name must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/fhirStores/[^/]+/fhir/[^/]+/[^/]+$"); } this.name = name; return this; } /** * Only include resource versions that were current at some point during the time * period specified in the date time value. The date parameter format is yyyy-mm- * ddThh:mm:ss[Z|(+|-)hh:mm] * * Clients may specify any of the following: * * * An entire year: `_at=2019` * An entire month: `_at=2019-01` * A specific day: * `_at=2019-01-20` * A specific second: `_at=2018-12-31T23:59:58Z` */ @com.google.api.client.util.Key("_at") private java.lang.String at; /** Only include resource versions that were current at some point during the time period specified in the date time value. The date parameter format is yyyy-mm-ddThh:mm:ss[Z|(+|-)hh:mm] Clients may specify any of the following: * An entire year: `_at=2019` * An entire month: `_at=2019-01` * A specific day: `_at=2019-01-20` * A specific second: `_at=2018-12-31T23:59:58Z` */ public java.lang.String getAt() { return at; } /** * Only include resource versions that were current at some point during the time * period specified in the date time value. The date parameter format is yyyy-mm- * ddThh:mm:ss[Z|(+|-)hh:mm] * * Clients may specify any of the following: * * * An entire year: `_at=2019` * An entire month: `_at=2019-01` * A specific day: * `_at=2019-01-20` * A specific second: `_at=2018-12-31T23:59:58Z` */ public History setAt(java.lang.String at) { this.at = at; return this; } /** The maximum number of search results on a page. Defaults to 1000. */ @com.google.api.client.util.Key("_count") private java.lang.Integer count; /** The maximum number of search results on a page. Defaults to 1000. */ public java.lang.Integer getCount() { return count; } /** The maximum number of search results on a page. Defaults to 1000. */ public History setCount(java.lang.Integer count) { this.count = count; return this; } /** * Used to retrieve the first, previous, next, or last page of resource versions when * using pagination. Value should be set to the value of `_page_token` set in next or * previous page links' URLs. Next and previous page are returned in the response * bundle's links field, where `link.relation` is "previous" or "next". * * Omit `_page_token` if no previous request has been made. */ @com.google.api.client.util.Key("_page_token") private java.lang.String pageToken; /** Used to retrieve the first, previous, next, or last page of resource versions when using pagination. Value should be set to the value of `_page_token` set in next or previous page links' URLs. Next and previous page are returned in the response bundle's links field, where `link.relation` is "previous" or "next". Omit `_page_token` if no previous request has been made. */ public java.lang.String getPageToken() { return pageToken; } /** * Used to retrieve the first, previous, next, or last page of resource versions when * using pagination. Value should be set to the value of `_page_token` set in next or * previous page links' URLs. Next and previous page are returned in the response * bundle's links field, where `link.relation` is "previous" or "next". * * Omit `_page_token` if no previous request has been made. */ public History setPageToken(java.lang.String pageToken) { this.pageToken = pageToken; return this; } /** * Only include resource versions that were created at or after the given instant in * time. The instant in time uses the format YYYY-MM-DDThh:mm:ss.sss+zz:zz (for * example 2015-02-07T13:28:17.239+02:00 or 2017-01-01T00:00:00Z). The time must be * specified to the second and include a time zone. */ @com.google.api.client.util.Key("_since") private java.lang.String since; /** Only include resource versions that were created at or after the given instant in time. The instant in time uses the format YYYY-MM-DDThh:mm:ss.sss+zz:zz (for example 2015-02-07T13:28:17.239+02:00 or 2017-01-01T00:00:00Z). The time must be specified to the second and include a time zone. */ public java.lang.String getSince() { return since; } /** * Only include resource versions that were created at or after the given instant in * time. The instant in time uses the format YYYY-MM-DDThh:mm:ss.sss+zz:zz (for * example 2015-02-07T13:28:17.239+02:00 or 2017-01-01T00:00:00Z). The time must be * specified to the second and include a time zone. */ public History setSince(java.lang.String since) { this.since = since; return this; } @Override public History set(String parameterName, Object value) { return (History) super.set(parameterName, value); } } /** * Updates part of an existing resource by applying the operations specified in a [JSON * Patch](http://jsonpatch.com/) document. * * Implements the FHIR standard [patch * interaction](http://hl7.org/implement/standards/fhir/STU3/http.html#patch). * * The request body must contain a JSON Patch document, and the request headers must contain * `Content-Type: application/json-patch+json`. * * On success, the response body will contain a JSON-encoded representation of the updated resource, * including the server-assigned version ID. Errors generated by the FHIR store will contain a JSON- * encoded `OperationOutcome` resource describing the reason for the error. If the request cannot be * mapped to a valid API method on a FHIR store, a generic GCP error might be returned instead. * * Create a request for the method "fhir.patch". * * This request holds the parameters needed by the healthcare server. After setting any optional * parameters, call the {@link Patch#execute()} method to invoke the remote operation. * * @param name The name of the resource to update. * @param content the {@link com.google.api.services.healthcare.v1beta1.model.HttpBody} * @return the request */ public Patch patch(java.lang.String name, com.google.api.services.healthcare.v1beta1.model.HttpBody content) throws java.io.IOException { Patch result = new Patch(name, content); initialize(result); return result; } public class Patch extends CloudHealthcareRequest<com.google.api.services.healthcare.v1beta1.model.HttpBody> { private static final String REST_PATH = "v1beta1/{+name}"; private final java.util.regex.Pattern NAME_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/datasets/[^/]+/fhirStores/[^/]+/fhir/[^/]+/[^/]+$"); /** * Updates part of an existing resource by applying the operations specified in a [JSON * Patch](http://jsonpatch.com/) document. * * Implements the FHIR standard [patch * interaction](http://hl7.org/implement/standards/fhir/STU3/http.html#patch). * * The request body must contain a JSON Patch document, and the request headers must contain * `Content-Type: application/json-patch+json`. * * On success, the response body will contain a JSON-encoded representation of the updated * resource, including the server-assigned version ID. Errors generated by the FHIR store will * contain a JSON-encoded `OperationOutcome` resource describing the reason for the error. If the * request cannot be mapped to a valid API method on a FHIR store, a generic GCP error might be * returned instead. * * Create a request for the method "fhir.patch". * * This request holds the parameters needed by the the healthcare server. After setting any * optional parameters, call the {@link Patch#execute()} method to invoke the remote operation. * <p> {@link * Patch#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} must * be called to initialize this instance immediately after invoking the constructor. </p> * * @param name The name of the resource to update. * @param content the {@link com.google.api.services.healthcare.v1beta1.model.HttpBody} * @since 1.13 */ protected Patch(java.lang.String name, com.google.api.services.healthcare.v1beta1.model.HttpBody content) { super(CloudHealthcare.this, "PATCH", REST_PATH, content, com.google.api.services.healthcare.v1beta1.model.HttpBody.class); this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), "Parameter name must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/fhirStores/[^/]+/fhir/[^/]+/[^/]+$"); } } @Override public Patch set$Xgafv(java.lang.String $Xgafv) { return (Patch) super.set$Xgafv($Xgafv); } @Override public Patch setAccessToken(java.lang.String accessToken) { return (Patch) super.setAccessToken(accessToken); } @Override public Patch setAlt(java.lang.String alt) { return (Patch) super.setAlt(alt); } @Override public Patch setCallback(java.lang.String callback) { return (Patch) super.setCallback(callback); } @Override public Patch setFields(java.lang.String fields) { return (Patch) super.setFields(fields); } @Override public Patch setKey(java.lang.String key) { return (Patch) super.setKey(key); } @Override public Patch setOauthToken(java.lang.String oauthToken) { return (Patch) super.setOauthToken(oauthToken); } @Override public Patch setPrettyPrint(java.lang.Boolean prettyPrint) { return (Patch) super.setPrettyPrint(prettyPrint); } @Override public Patch setQuotaUser(java.lang.String quotaUser) { return (Patch) super.setQuotaUser(quotaUser); } @Override public Patch setUploadType(java.lang.String uploadType) { return (Patch) super.setUploadType(uploadType); } @Override public Patch setUploadProtocol(java.lang.String uploadProtocol) { return (Patch) super.setUploadProtocol(uploadProtocol); } /** The name of the resource to update. */ @com.google.api.client.util.Key private java.lang.String name; /** The name of the resource to update. */ public java.lang.String getName() { return name; } /** The name of the resource to update. */ public Patch setName(java.lang.String name) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), "Parameter name must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/fhirStores/[^/]+/fhir/[^/]+/[^/]+$"); } this.name = name; return this; } @Override public Patch set(String parameterName, Object value) { return (Patch) super.set(parameterName, value); } } /** * Gets the contents of a FHIR resource. * * Implements the FHIR standard [read * interaction](http://hl7.org/implement/standards/fhir/STU3/http.html#read). * * Also supports the FHIR standard [conditional read * interaction](http://hl7.org/implement/standards/fhir/STU3/http.html#cread) specified by supplying * an `If-Modified-Since` header with a date/time value or an `If-None-Match` header with an ETag * value. * * On success, the response body will contain a JSON-encoded representation of the resource. Errors * generated by the FHIR store will contain a JSON-encoded `OperationOutcome` resource describing * the reason for the error. If the request cannot be mapped to a valid API method on a FHIR store, * a generic GCP error might be returned instead. * * Create a request for the method "fhir.read". * * This request holds the parameters needed by the healthcare server. After setting any optional * parameters, call the {@link Read#execute()} method to invoke the remote operation. * * @param name The name of the resource to retrieve. * @return the request */ public Read read(java.lang.String name) throws java.io.IOException { Read result = new Read(name); initialize(result); return result; } public class Read extends CloudHealthcareRequest<com.google.api.services.healthcare.v1beta1.model.HttpBody> { private static final String REST_PATH = "v1beta1/{+name}"; private final java.util.regex.Pattern NAME_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/datasets/[^/]+/fhirStores/[^/]+/fhir/[^/]+/[^/]+$"); /** * Gets the contents of a FHIR resource. * * Implements the FHIR standard [read * interaction](http://hl7.org/implement/standards/fhir/STU3/http.html#read). * * Also supports the FHIR standard [conditional read * interaction](http://hl7.org/implement/standards/fhir/STU3/http.html#cread) specified by * supplying an `If-Modified-Since` header with a date/time value or an `If-None-Match` header * with an ETag value. * * On success, the response body will contain a JSON-encoded representation of the resource. * Errors generated by the FHIR store will contain a JSON-encoded `OperationOutcome` resource * describing the reason for the error. If the request cannot be mapped to a valid API method on a * FHIR store, a generic GCP error might be returned instead. * * Create a request for the method "fhir.read". * * This request holds the parameters needed by the the healthcare server. After setting any * optional parameters, call the {@link Read#execute()} method to invoke the remote operation. <p> * {@link Read#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} * must be called to initialize this instance immediately after invoking the constructor. </p> * * @param name The name of the resource to retrieve. * @since 1.13 */ protected Read(java.lang.String name) { super(CloudHealthcare.this, "GET", REST_PATH, null, com.google.api.services.healthcare.v1beta1.model.HttpBody.class); this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), "Parameter name must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/fhirStores/[^/]+/fhir/[^/]+/[^/]+$"); } } @Override public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException { return super.executeUsingHead(); } @Override public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException { return super.buildHttpRequestUsingHead(); } @Override public Read set$Xgafv(java.lang.String $Xgafv) { return (Read) super.set$Xgafv($Xgafv); } @Override public Read setAccessToken(java.lang.String accessToken) { return (Read) super.setAccessToken(accessToken); } @Override public Read setAlt(java.lang.String alt) { return (Read) super.setAlt(alt); } @Override public Read setCallback(java.lang.String callback) { return (Read) super.setCallback(callback); } @Override public Read setFields(java.lang.String fields) { return (Read) super.setFields(fields); } @Override public Read setKey(java.lang.String key) { return (Read) super.setKey(key); } @Override public Read setOauthToken(java.lang.String oauthToken) { return (Read) super.setOauthToken(oauthToken); } @Override public Read setPrettyPrint(java.lang.Boolean prettyPrint) { return (Read) super.setPrettyPrint(prettyPrint); } @Override public Read setQuotaUser(java.lang.String quotaUser) { return (Read) super.setQuotaUser(quotaUser); } @Override public Read setUploadType(java.lang.String uploadType) { return (Read) super.setUploadType(uploadType); } @Override public Read setUploadProtocol(java.lang.String uploadProtocol) { return (Read) super.setUploadProtocol(uploadProtocol); } /** The name of the resource to retrieve. */ @com.google.api.client.util.Key private java.lang.String name; /** The name of the resource to retrieve. */ public java.lang.String getName() { return name; } /** The name of the resource to retrieve. */ public Read setName(java.lang.String name) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), "Parameter name must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/fhirStores/[^/]+/fhir/[^/]+/[^/]+$"); } this.name = name; return this; } @Override public Read set(String parameterName, Object value) { return (Read) super.set(parameterName, value); } } /** * Searches for resources in the given FHIR store according to criteria specified as query * parameters. * * Implements the FHIR standard [search * interaction](http://hl7.org/implement/standards/fhir/STU3/http.html#search) using the search * semantics described in the [FHIR Search * specification](http://hl7.org/implement/standards/fhir/STU3/search.html). * * Supports three methods of search defined by the specification: * * * `GET [base]?[parameters]` to search across all resources. * `GET [base]/[type]?[parameters]` * to search resources of a specified type. * `POST [base]/[type]/_search?[parameters]` as an * alternate form having the same semantics as the `GET` method. * * The `GET` methods do not support compartment searches. The `POST` method does not support * `application/x-www-form-urlencoded` search parameters. * * On success, the response body will contain a JSON-encoded representation of a `Bundle` resource * of type `searchset`, containing the results of the search. Errors generated by the FHIR store * will contain a JSON-encoded `OperationOutcome` resource describing the reason for the error. If * the request cannot be mapped to a valid API method on a FHIR store, a generic GCP error might be * returned instead. * * The server's capability statement, retrieved through capabilities, indicates the search * parameters that are supported on each FHIR resource. For the list of search parameters for STU3, * see the [STU3 FHIR Search Parameter Registry](http://hl7.org/implement/standards/fhir/STU3 * /searchparameter-registry.html). * * Supported search modifiers: `:missing`, `:exact`, `:contains`, `:text`, `:in`, `:not-in`, * `:above`, `:below`, `:[type]`, `:not`, and `:recurse`. * * Supported search result parameters: `_sort`, `_count`, `_include`, `_revinclude`, * `_summary=text`, `_summary=data`, and `_elements`. * * The maximum number of search results returned defaults to 100, which can be overridden by the * `_count` parameter up to a maximum limit of 1000. If there are additional results, the returned * `Bundle` will contain pagination links. * * Resources with a total size larger than 5MB or a field count larger than 50,000 might not be * fully searchable as the server might trim its generated search index in those cases. * * Note: FHIR resources are indexed asynchronously, so there might be a slight delay between the * time a resource is created or changes and when the change is reflected in search results. * * Create a request for the method "fhir.search". * * This request holds the parameters needed by the healthcare server. After setting any optional * parameters, call the {@link Search#execute()} method to invoke the remote operation. * * @param parent Name of the FHIR store to retrieve resources from. * @param content the {@link com.google.api.services.healthcare.v1beta1.model.SearchResourcesRequest} * @return the request */ public Search search(java.lang.String parent, com.google.api.services.healthcare.v1beta1.model.SearchResourcesRequest content) throws java.io.IOException { Search result = new Search(parent, content); initialize(result); return result; } public class Search extends CloudHealthcareRequest<com.google.api.services.healthcare.v1beta1.model.HttpBody> { private static final String REST_PATH = "v1beta1/{+parent}/fhir/_search"; private final java.util.regex.Pattern PARENT_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/datasets/[^/]+/fhirStores/[^/]+$"); /** * Searches for resources in the given FHIR store according to criteria specified as query * parameters. * * Implements the FHIR standard [search * interaction](http://hl7.org/implement/standards/fhir/STU3/http.html#search) using the search * semantics described in the [FHIR Search * specification](http://hl7.org/implement/standards/fhir/STU3/search.html). * * Supports three methods of search defined by the specification: * * * `GET [base]?[parameters]` to search across all resources. * `GET * [base]/[type]?[parameters]` to search resources of a specified type. * `POST * [base]/[type]/_search?[parameters]` as an alternate form having the same semantics as the `GET` * method. * * The `GET` methods do not support compartment searches. The `POST` method does not support * `application/x-www-form-urlencoded` search parameters. * * On success, the response body will contain a JSON-encoded representation of a `Bundle` resource * of type `searchset`, containing the results of the search. Errors generated by the FHIR store * will contain a JSON-encoded `OperationOutcome` resource describing the reason for the error. If * the request cannot be mapped to a valid API method on a FHIR store, a generic GCP error might * be returned instead. * * The server's capability statement, retrieved through capabilities, indicates the search * parameters that are supported on each FHIR resource. For the list of search parameters for * STU3, see the [STU3 FHIR Search Parameter * Registry](http://hl7.org/implement/standards/fhir/STU3/searchparameter-registry.html). * * Supported search modifiers: `:missing`, `:exact`, `:contains`, `:text`, `:in`, `:not-in`, * `:above`, `:below`, `:[type]`, `:not`, and `:recurse`. * * Supported search result parameters: `_sort`, `_count`, `_include`, `_revinclude`, * `_summary=text`, `_summary=data`, and `_elements`. * * The maximum number of search results returned defaults to 100, which can be overridden by the * `_count` parameter up to a maximum limit of 1000. If there are additional results, the returned * `Bundle` will contain pagination links. * * Resources with a total size larger than 5MB or a field count larger than 50,000 might not be * fully searchable as the server might trim its generated search index in those cases. * * Note: FHIR resources are indexed asynchronously, so there might be a slight delay between the * time a resource is created or changes and when the change is reflected in search results. * * Create a request for the method "fhir.search". * * This request holds the parameters needed by the the healthcare server. After setting any * optional parameters, call the {@link Search#execute()} method to invoke the remote operation. * <p> {@link * Search#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} must * be called to initialize this instance immediately after invoking the constructor. </p> * * @param parent Name of the FHIR store to retrieve resources from. * @param content the {@link com.google.api.services.healthcare.v1beta1.model.SearchResourcesRequest} * @since 1.13 */ protected Search(java.lang.String parent, com.google.api.services.healthcare.v1beta1.model.SearchResourcesRequest content) { super(CloudHealthcare.this, "POST", REST_PATH, content, com.google.api.services.healthcare.v1beta1.model.HttpBody.class); this.parent = com.google.api.client.util.Preconditions.checkNotNull(parent, "Required parameter parent must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), "Parameter parent must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/fhirStores/[^/]+$"); } } @Override public Search set$Xgafv(java.lang.String $Xgafv) { return (Search) super.set$Xgafv($Xgafv); } @Override public Search setAccessToken(java.lang.String accessToken) { return (Search) super.setAccessToken(accessToken); } @Override public Search setAlt(java.lang.String alt) { return (Search) super.setAlt(alt); } @Override public Search setCallback(java.lang.String callback) { return (Search) super.setCallback(callback); } @Override public Search setFields(java.lang.String fields) { return (Search) super.setFields(fields); } @Override public Search setKey(java.lang.String key) { return (Search) super.setKey(key); } @Override public Search setOauthToken(java.lang.String oauthToken) { return (Search) super.setOauthToken(oauthToken); } @Override public Search setPrettyPrint(java.lang.Boolean prettyPrint) { return (Search) super.setPrettyPrint(prettyPrint); } @Override public Search setQuotaUser(java.lang.String quotaUser) { return (Search) super.setQuotaUser(quotaUser); } @Override public Search setUploadType(java.lang.String uploadType) { return (Search) super.setUploadType(uploadType); } @Override public Search setUploadProtocol(java.lang.String uploadProtocol) { return (Search) super.setUploadProtocol(uploadProtocol); } /** Name of the FHIR store to retrieve resources from. */ @com.google.api.client.util.Key private java.lang.String parent; /** Name of the FHIR store to retrieve resources from. */ public java.lang.String getParent() { return parent; } /** Name of the FHIR store to retrieve resources from. */ public Search setParent(java.lang.String parent) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), "Parameter parent must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/fhirStores/[^/]+$"); } this.parent = parent; return this; } @Override public Search set(String parameterName, Object value) { return (Search) super.set(parameterName, value); } } /** * Updates the entire contents of a resource. * * Implements the FHIR standard [update * interaction](http://hl7.org/implement/standards/fhir/STU3/http.html#update). * * If the specified resource does not exist and the FHIR store has enable_update_create set, creates * the resource with the client-specified ID. * * The request body must contain a JSON-encoded FHIR resource, and the request headers must contain * `Content-Type: application/fhir+json`. The resource must contain an `id` element having an * identical value to the ID in the REST path of the request. * * On success, the response body will contain a JSON-encoded representation of the updated resource, * including the server-assigned version ID. Errors generated by the FHIR store will contain a JSON- * encoded `OperationOutcome` resource describing the reason for the error. If the request cannot be * mapped to a valid API method on a FHIR store, a generic GCP error might be returned instead. * * Create a request for the method "fhir.update". * * This request holds the parameters needed by the healthcare server. After setting any optional * parameters, call the {@link Update#execute()} method to invoke the remote operation. * * @param name The name of the resource to update. * @param content the {@link com.google.api.services.healthcare.v1beta1.model.HttpBody} * @return the request */ public Update update(java.lang.String name, com.google.api.services.healthcare.v1beta1.model.HttpBody content) throws java.io.IOException { Update result = new Update(name, content); initialize(result); return result; } public class Update extends CloudHealthcareRequest<com.google.api.services.healthcare.v1beta1.model.HttpBody> { private static final String REST_PATH = "v1beta1/{+name}"; private final java.util.regex.Pattern NAME_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/datasets/[^/]+/fhirStores/[^/]+/fhir/[^/]+/[^/]+$"); /** * Updates the entire contents of a resource. * * Implements the FHIR standard [update * interaction](http://hl7.org/implement/standards/fhir/STU3/http.html#update). * * If the specified resource does not exist and the FHIR store has enable_update_create set, * creates the resource with the client-specified ID. * * The request body must contain a JSON-encoded FHIR resource, and the request headers must * contain `Content-Type: application/fhir+json`. The resource must contain an `id` element having * an identical value to the ID in the REST path of the request. * * On success, the response body will contain a JSON-encoded representation of the updated * resource, including the server-assigned version ID. Errors generated by the FHIR store will * contain a JSON-encoded `OperationOutcome` resource describing the reason for the error. If the * request cannot be mapped to a valid API method on a FHIR store, a generic GCP error might be * returned instead. * * Create a request for the method "fhir.update". * * This request holds the parameters needed by the the healthcare server. After setting any * optional parameters, call the {@link Update#execute()} method to invoke the remote operation. * <p> {@link * Update#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} must * be called to initialize this instance immediately after invoking the constructor. </p> * * @param name The name of the resource to update. * @param content the {@link com.google.api.services.healthcare.v1beta1.model.HttpBody} * @since 1.13 */ protected Update(java.lang.String name, com.google.api.services.healthcare.v1beta1.model.HttpBody content) { super(CloudHealthcare.this, "PUT", REST_PATH, content, com.google.api.services.healthcare.v1beta1.model.HttpBody.class); this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), "Parameter name must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/fhirStores/[^/]+/fhir/[^/]+/[^/]+$"); } } @Override public Update set$Xgafv(java.lang.String $Xgafv) { return (Update) super.set$Xgafv($Xgafv); } @Override public Update setAccessToken(java.lang.String accessToken) { return (Update) super.setAccessToken(accessToken); } @Override public Update setAlt(java.lang.String alt) { return (Update) super.setAlt(alt); } @Override public Update setCallback(java.lang.String callback) { return (Update) super.setCallback(callback); } @Override public Update setFields(java.lang.String fields) { return (Update) super.setFields(fields); } @Override public Update setKey(java.lang.String key) { return (Update) super.setKey(key); } @Override public Update setOauthToken(java.lang.String oauthToken) { return (Update) super.setOauthToken(oauthToken); } @Override public Update setPrettyPrint(java.lang.Boolean prettyPrint) { return (Update) super.setPrettyPrint(prettyPrint); } @Override public Update setQuotaUser(java.lang.String quotaUser) { return (Update) super.setQuotaUser(quotaUser); } @Override public Update setUploadType(java.lang.String uploadType) { return (Update) super.setUploadType(uploadType); } @Override public Update setUploadProtocol(java.lang.String uploadProtocol) { return (Update) super.setUploadProtocol(uploadProtocol); } /** The name of the resource to update. */ @com.google.api.client.util.Key private java.lang.String name; /** The name of the resource to update. */ public java.lang.String getName() { return name; } /** The name of the resource to update. */ public Update setName(java.lang.String name) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), "Parameter name must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/fhirStores/[^/]+/fhir/[^/]+/[^/]+$"); } this.name = name; return this; } @Override public Update set(String parameterName, Object value) { return (Update) super.set(parameterName, value); } } /** * Gets the contents of a version (current or historical) of a FHIR resource by version ID. * * Implements the FHIR standard [vread * interaction](http://hl7.org/implement/standards/fhir/STU3/http.html#vread). * * On success, the response body will contain a JSON-encoded representation of the resource. Errors * generated by the FHIR store will contain a JSON-encoded `OperationOutcome` resource describing * the reason for the error. If the request cannot be mapped to a valid API method on a FHIR store, * a generic GCP error might be returned instead. * * Create a request for the method "fhir.vread". * * This request holds the parameters needed by the healthcare server. After setting any optional * parameters, call the {@link Vread#execute()} method to invoke the remote operation. * * @param name The name of the resource version to retrieve. * @return the request */ public Vread vread(java.lang.String name) throws java.io.IOException { Vread result = new Vread(name); initialize(result); return result; } public class Vread extends CloudHealthcareRequest<com.google.api.services.healthcare.v1beta1.model.HttpBody> { private static final String REST_PATH = "v1beta1/{+name}"; private final java.util.regex.Pattern NAME_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/datasets/[^/]+/fhirStores/[^/]+/fhir/[^/]+/[^/]+/_history/[^/]+$"); /** * Gets the contents of a version (current or historical) of a FHIR resource by version ID. * * Implements the FHIR standard [vread * interaction](http://hl7.org/implement/standards/fhir/STU3/http.html#vread). * * On success, the response body will contain a JSON-encoded representation of the resource. * Errors generated by the FHIR store will contain a JSON-encoded `OperationOutcome` resource * describing the reason for the error. If the request cannot be mapped to a valid API method on a * FHIR store, a generic GCP error might be returned instead. * * Create a request for the method "fhir.vread". * * This request holds the parameters needed by the the healthcare server. After setting any * optional parameters, call the {@link Vread#execute()} method to invoke the remote operation. * <p> {@link * Vread#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} must * be called to initialize this instance immediately after invoking the constructor. </p> * * @param name The name of the resource version to retrieve. * @since 1.13 */ protected Vread(java.lang.String name) { super(CloudHealthcare.this, "GET", REST_PATH, null, com.google.api.services.healthcare.v1beta1.model.HttpBody.class); this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), "Parameter name must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/fhirStores/[^/]+/fhir/[^/]+/[^/]+/_history/[^/]+$"); } } @Override public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException { return super.executeUsingHead(); } @Override public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException { return super.buildHttpRequestUsingHead(); } @Override public Vread set$Xgafv(java.lang.String $Xgafv) { return (Vread) super.set$Xgafv($Xgafv); } @Override public Vread setAccessToken(java.lang.String accessToken) { return (Vread) super.setAccessToken(accessToken); } @Override public Vread setAlt(java.lang.String alt) { return (Vread) super.setAlt(alt); } @Override public Vread setCallback(java.lang.String callback) { return (Vread) super.setCallback(callback); } @Override public Vread setFields(java.lang.String fields) { return (Vread) super.setFields(fields); } @Override public Vread setKey(java.lang.String key) { return (Vread) super.setKey(key); } @Override public Vread setOauthToken(java.lang.String oauthToken) { return (Vread) super.setOauthToken(oauthToken); } @Override public Vread setPrettyPrint(java.lang.Boolean prettyPrint) { return (Vread) super.setPrettyPrint(prettyPrint); } @Override public Vread setQuotaUser(java.lang.String quotaUser) { return (Vread) super.setQuotaUser(quotaUser); } @Override public Vread setUploadType(java.lang.String uploadType) { return (Vread) super.setUploadType(uploadType); } @Override public Vread setUploadProtocol(java.lang.String uploadProtocol) { return (Vread) super.setUploadProtocol(uploadProtocol); } /** The name of the resource version to retrieve. */ @com.google.api.client.util.Key private java.lang.String name; /** The name of the resource version to retrieve. */ public java.lang.String getName() { return name; } /** The name of the resource version to retrieve. */ public Vread setName(java.lang.String name) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), "Parameter name must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/fhirStores/[^/]+/fhir/[^/]+/[^/]+/_history/[^/]+$"); } this.name = name; return this; } @Override public Vread set(String parameterName, Object value) { return (Vread) super.set(parameterName, value); } } } } /** * An accessor for creating requests from the Hl7V2Stores collection. * * <p>The typical use is:</p> * <pre> * {@code CloudHealthcare healthcare = new CloudHealthcare(...);} * {@code CloudHealthcare.Hl7V2Stores.List request = healthcare.hl7V2Stores().list(parameters ...)} * </pre> * * @return the resource collection */ public Hl7V2Stores hl7V2Stores() { return new Hl7V2Stores(); } /** * The "hl7V2Stores" collection of methods. */ public class Hl7V2Stores { /** * Creates a new HL7v2 store within the parent dataset. * * Create a request for the method "hl7V2Stores.create". * * This request holds the parameters needed by the healthcare server. After setting any optional * parameters, call the {@link Create#execute()} method to invoke the remote operation. * * @param parent The name of the dataset this HL7v2 store belongs to. * @param content the {@link com.google.api.services.healthcare.v1beta1.model.Hl7V2Store} * @return the request */ public Create create(java.lang.String parent, com.google.api.services.healthcare.v1beta1.model.Hl7V2Store content) throws java.io.IOException { Create result = new Create(parent, content); initialize(result); return result; } public class Create extends CloudHealthcareRequest<com.google.api.services.healthcare.v1beta1.model.Hl7V2Store> { private static final String REST_PATH = "v1beta1/{+parent}/hl7V2Stores"; private final java.util.regex.Pattern PARENT_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/datasets/[^/]+$"); /** * Creates a new HL7v2 store within the parent dataset. * * Create a request for the method "hl7V2Stores.create". * * This request holds the parameters needed by the the healthcare server. After setting any * optional parameters, call the {@link Create#execute()} method to invoke the remote operation. * <p> {@link * Create#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} must * be called to initialize this instance immediately after invoking the constructor. </p> * * @param parent The name of the dataset this HL7v2 store belongs to. * @param content the {@link com.google.api.services.healthcare.v1beta1.model.Hl7V2Store} * @since 1.13 */ protected Create(java.lang.String parent, com.google.api.services.healthcare.v1beta1.model.Hl7V2Store content) { super(CloudHealthcare.this, "POST", REST_PATH, content, com.google.api.services.healthcare.v1beta1.model.Hl7V2Store.class); this.parent = com.google.api.client.util.Preconditions.checkNotNull(parent, "Required parameter parent must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), "Parameter parent must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+$"); } } @Override public Create set$Xgafv(java.lang.String $Xgafv) { return (Create) super.set$Xgafv($Xgafv); } @Override public Create setAccessToken(java.lang.String accessToken) { return (Create) super.setAccessToken(accessToken); } @Override public Create setAlt(java.lang.String alt) { return (Create) super.setAlt(alt); } @Override public Create setCallback(java.lang.String callback) { return (Create) super.setCallback(callback); } @Override public Create setFields(java.lang.String fields) { return (Create) super.setFields(fields); } @Override public Create setKey(java.lang.String key) { return (Create) super.setKey(key); } @Override public Create setOauthToken(java.lang.String oauthToken) { return (Create) super.setOauthToken(oauthToken); } @Override public Create setPrettyPrint(java.lang.Boolean prettyPrint) { return (Create) super.setPrettyPrint(prettyPrint); } @Override public Create setQuotaUser(java.lang.String quotaUser) { return (Create) super.setQuotaUser(quotaUser); } @Override public Create setUploadType(java.lang.String uploadType) { return (Create) super.setUploadType(uploadType); } @Override public Create setUploadProtocol(java.lang.String uploadProtocol) { return (Create) super.setUploadProtocol(uploadProtocol); } /** The name of the dataset this HL7v2 store belongs to. */ @com.google.api.client.util.Key private java.lang.String parent; /** The name of the dataset this HL7v2 store belongs to. */ public java.lang.String getParent() { return parent; } /** The name of the dataset this HL7v2 store belongs to. */ public Create setParent(java.lang.String parent) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), "Parameter parent must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+$"); } this.parent = parent; return this; } /** * The ID of the HL7v2 store that is being created. The string must match the following * regex: `[\p{L}\p{N}_\-\.]{1,256}`. */ @com.google.api.client.util.Key private java.lang.String hl7V2StoreId; /** The ID of the HL7v2 store that is being created. The string must match the following regex: `[\p{L}\p{N}_\-\.]{1,256}`. */ public java.lang.String getHl7V2StoreId() { return hl7V2StoreId; } /** * The ID of the HL7v2 store that is being created. The string must match the following * regex: `[\p{L}\p{N}_\-\.]{1,256}`. */ public Create setHl7V2StoreId(java.lang.String hl7V2StoreId) { this.hl7V2StoreId = hl7V2StoreId; return this; } @Override public Create set(String parameterName, Object value) { return (Create) super.set(parameterName, value); } } /** * Deletes the specified HL7v2 store and removes all messages that are contained within it. * * Create a request for the method "hl7V2Stores.delete". * * This request holds the parameters needed by the healthcare server. After setting any optional * parameters, call the {@link Delete#execute()} method to invoke the remote operation. * * @param name The resource name of the HL7v2 store to delete. * @return the request */ public Delete delete(java.lang.String name) throws java.io.IOException { Delete result = new Delete(name); initialize(result); return result; } public class Delete extends CloudHealthcareRequest<com.google.api.services.healthcare.v1beta1.model.Empty> { private static final String REST_PATH = "v1beta1/{+name}"; private final java.util.regex.Pattern NAME_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/datasets/[^/]+/hl7V2Stores/[^/]+$"); /** * Deletes the specified HL7v2 store and removes all messages that are contained within it. * * Create a request for the method "hl7V2Stores.delete". * * This request holds the parameters needed by the the healthcare server. After setting any * optional parameters, call the {@link Delete#execute()} method to invoke the remote operation. * <p> {@link * Delete#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} must * be called to initialize this instance immediately after invoking the constructor. </p> * * @param name The resource name of the HL7v2 store to delete. * @since 1.13 */ protected Delete(java.lang.String name) { super(CloudHealthcare.this, "DELETE", REST_PATH, null, com.google.api.services.healthcare.v1beta1.model.Empty.class); this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), "Parameter name must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/hl7V2Stores/[^/]+$"); } } @Override public Delete set$Xgafv(java.lang.String $Xgafv) { return (Delete) super.set$Xgafv($Xgafv); } @Override public Delete setAccessToken(java.lang.String accessToken) { return (Delete) super.setAccessToken(accessToken); } @Override public Delete setAlt(java.lang.String alt) { return (Delete) super.setAlt(alt); } @Override public Delete setCallback(java.lang.String callback) { return (Delete) super.setCallback(callback); } @Override public Delete setFields(java.lang.String fields) { return (Delete) super.setFields(fields); } @Override public Delete setKey(java.lang.String key) { return (Delete) super.setKey(key); } @Override public Delete setOauthToken(java.lang.String oauthToken) { return (Delete) super.setOauthToken(oauthToken); } @Override public Delete setPrettyPrint(java.lang.Boolean prettyPrint) { return (Delete) super.setPrettyPrint(prettyPrint); } @Override public Delete setQuotaUser(java.lang.String quotaUser) { return (Delete) super.setQuotaUser(quotaUser); } @Override public Delete setUploadType(java.lang.String uploadType) { return (Delete) super.setUploadType(uploadType); } @Override public Delete setUploadProtocol(java.lang.String uploadProtocol) { return (Delete) super.setUploadProtocol(uploadProtocol); } /** The resource name of the HL7v2 store to delete. */ @com.google.api.client.util.Key private java.lang.String name; /** The resource name of the HL7v2 store to delete. */ public java.lang.String getName() { return name; } /** The resource name of the HL7v2 store to delete. */ public Delete setName(java.lang.String name) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), "Parameter name must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/hl7V2Stores/[^/]+$"); } this.name = name; return this; } @Override public Delete set(String parameterName, Object value) { return (Delete) super.set(parameterName, value); } } /** * Gets the specified HL7v2 store. * * Create a request for the method "hl7V2Stores.get". * * This request holds the parameters needed by the healthcare server. After setting any optional * parameters, call the {@link Get#execute()} method to invoke the remote operation. * * @param name The resource name of the HL7v2 store to get. * @return the request */ public Get get(java.lang.String name) throws java.io.IOException { Get result = new Get(name); initialize(result); return result; } public class Get extends CloudHealthcareRequest<com.google.api.services.healthcare.v1beta1.model.Hl7V2Store> { private static final String REST_PATH = "v1beta1/{+name}"; private final java.util.regex.Pattern NAME_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/datasets/[^/]+/hl7V2Stores/[^/]+$"); /** * Gets the specified HL7v2 store. * * Create a request for the method "hl7V2Stores.get". * * This request holds the parameters needed by the the healthcare server. After setting any * optional parameters, call the {@link Get#execute()} method to invoke the remote operation. <p> * {@link Get#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} * must be called to initialize this instance immediately after invoking the constructor. </p> * * @param name The resource name of the HL7v2 store to get. * @since 1.13 */ protected Get(java.lang.String name) { super(CloudHealthcare.this, "GET", REST_PATH, null, com.google.api.services.healthcare.v1beta1.model.Hl7V2Store.class); this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), "Parameter name must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/hl7V2Stores/[^/]+$"); } } @Override public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException { return super.executeUsingHead(); } @Override public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException { return super.buildHttpRequestUsingHead(); } @Override public Get set$Xgafv(java.lang.String $Xgafv) { return (Get) super.set$Xgafv($Xgafv); } @Override public Get setAccessToken(java.lang.String accessToken) { return (Get) super.setAccessToken(accessToken); } @Override public Get setAlt(java.lang.String alt) { return (Get) super.setAlt(alt); } @Override public Get setCallback(java.lang.String callback) { return (Get) super.setCallback(callback); } @Override public Get setFields(java.lang.String fields) { return (Get) super.setFields(fields); } @Override public Get setKey(java.lang.String key) { return (Get) super.setKey(key); } @Override public Get setOauthToken(java.lang.String oauthToken) { return (Get) super.setOauthToken(oauthToken); } @Override public Get setPrettyPrint(java.lang.Boolean prettyPrint) { return (Get) super.setPrettyPrint(prettyPrint); } @Override public Get setQuotaUser(java.lang.String quotaUser) { return (Get) super.setQuotaUser(quotaUser); } @Override public Get setUploadType(java.lang.String uploadType) { return (Get) super.setUploadType(uploadType); } @Override public Get setUploadProtocol(java.lang.String uploadProtocol) { return (Get) super.setUploadProtocol(uploadProtocol); } /** The resource name of the HL7v2 store to get. */ @com.google.api.client.util.Key private java.lang.String name; /** The resource name of the HL7v2 store to get. */ public java.lang.String getName() { return name; } /** The resource name of the HL7v2 store to get. */ public Get setName(java.lang.String name) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), "Parameter name must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/hl7V2Stores/[^/]+$"); } this.name = name; return this; } @Override public Get set(String parameterName, Object value) { return (Get) super.set(parameterName, value); } } /** * Gets the access control policy for a resource. Returns an empty policy if the resource exists and * does not have a policy set. * * Create a request for the method "hl7V2Stores.getIamPolicy". * * This request holds the parameters needed by the healthcare server. After setting any optional * parameters, call the {@link GetIamPolicy#execute()} method to invoke the remote operation. * * @param resource REQUIRED: The resource for which the policy is being requested. See the operation documentation for * the appropriate value for this field. * @return the request */ public GetIamPolicy getIamPolicy(java.lang.String resource) throws java.io.IOException { GetIamPolicy result = new GetIamPolicy(resource); initialize(result); return result; } public class GetIamPolicy extends CloudHealthcareRequest<com.google.api.services.healthcare.v1beta1.model.Policy> { private static final String REST_PATH = "v1beta1/{+resource}:getIamPolicy"; private final java.util.regex.Pattern RESOURCE_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/datasets/[^/]+/hl7V2Stores/[^/]+$"); /** * Gets the access control policy for a resource. Returns an empty policy if the resource exists * and does not have a policy set. * * Create a request for the method "hl7V2Stores.getIamPolicy". * * This request holds the parameters needed by the the healthcare server. After setting any * optional parameters, call the {@link GetIamPolicy#execute()} method to invoke the remote * operation. <p> {@link * GetIamPolicy#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} * must be called to initialize this instance immediately after invoking the constructor. </p> * * @param resource REQUIRED: The resource for which the policy is being requested. See the operation documentation for * the appropriate value for this field. * @since 1.13 */ protected GetIamPolicy(java.lang.String resource) { super(CloudHealthcare.this, "GET", REST_PATH, null, com.google.api.services.healthcare.v1beta1.model.Policy.class); this.resource = com.google.api.client.util.Preconditions.checkNotNull(resource, "Required parameter resource must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(RESOURCE_PATTERN.matcher(resource).matches(), "Parameter resource must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/hl7V2Stores/[^/]+$"); } } @Override public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException { return super.executeUsingHead(); } @Override public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException { return super.buildHttpRequestUsingHead(); } @Override public GetIamPolicy set$Xgafv(java.lang.String $Xgafv) { return (GetIamPolicy) super.set$Xgafv($Xgafv); } @Override public GetIamPolicy setAccessToken(java.lang.String accessToken) { return (GetIamPolicy) super.setAccessToken(accessToken); } @Override public GetIamPolicy setAlt(java.lang.String alt) { return (GetIamPolicy) super.setAlt(alt); } @Override public GetIamPolicy setCallback(java.lang.String callback) { return (GetIamPolicy) super.setCallback(callback); } @Override public GetIamPolicy setFields(java.lang.String fields) { return (GetIamPolicy) super.setFields(fields); } @Override public GetIamPolicy setKey(java.lang.String key) { return (GetIamPolicy) super.setKey(key); } @Override public GetIamPolicy setOauthToken(java.lang.String oauthToken) { return (GetIamPolicy) super.setOauthToken(oauthToken); } @Override public GetIamPolicy setPrettyPrint(java.lang.Boolean prettyPrint) { return (GetIamPolicy) super.setPrettyPrint(prettyPrint); } @Override public GetIamPolicy setQuotaUser(java.lang.String quotaUser) { return (GetIamPolicy) super.setQuotaUser(quotaUser); } @Override public GetIamPolicy setUploadType(java.lang.String uploadType) { return (GetIamPolicy) super.setUploadType(uploadType); } @Override public GetIamPolicy setUploadProtocol(java.lang.String uploadProtocol) { return (GetIamPolicy) super.setUploadProtocol(uploadProtocol); } /** * REQUIRED: The resource for which the policy is being requested. See the operation * documentation for the appropriate value for this field. */ @com.google.api.client.util.Key private java.lang.String resource; /** REQUIRED: The resource for which the policy is being requested. See the operation documentation for the appropriate value for this field. */ public java.lang.String getResource() { return resource; } /** * REQUIRED: The resource for which the policy is being requested. See the operation * documentation for the appropriate value for this field. */ public GetIamPolicy setResource(java.lang.String resource) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(RESOURCE_PATTERN.matcher(resource).matches(), "Parameter resource must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/hl7V2Stores/[^/]+$"); } this.resource = resource; return this; } /** * Optional. The policy format version to be returned. * * Valid values are 0, 1, and 3. Requests specifying an invalid value will be rejected. * * Requests for policies with any conditional bindings must specify version 3. Policies * without any conditional bindings may specify any valid value or leave the field * unset. */ @com.google.api.client.util.Key("options.requestedPolicyVersion") private java.lang.Integer optionsRequestedPolicyVersion; /** Optional. The policy format version to be returned. Valid values are 0, 1, and 3. Requests specifying an invalid value will be rejected. Requests for policies with any conditional bindings must specify version 3. Policies without any conditional bindings may specify any valid value or leave the field unset. */ public java.lang.Integer getOptionsRequestedPolicyVersion() { return optionsRequestedPolicyVersion; } /** * Optional. The policy format version to be returned. * * Valid values are 0, 1, and 3. Requests specifying an invalid value will be rejected. * * Requests for policies with any conditional bindings must specify version 3. Policies * without any conditional bindings may specify any valid value or leave the field * unset. */ public GetIamPolicy setOptionsRequestedPolicyVersion(java.lang.Integer optionsRequestedPolicyVersion) { this.optionsRequestedPolicyVersion = optionsRequestedPolicyVersion; return this; } @Override public GetIamPolicy set(String parameterName, Object value) { return (GetIamPolicy) super.set(parameterName, value); } } /** * Lists the HL7v2 stores in the given dataset. * * Create a request for the method "hl7V2Stores.list". * * This request holds the parameters needed by the healthcare server. After setting any optional * parameters, call the {@link List#execute()} method to invoke the remote operation. * * @param parent Name of the dataset. * @return the request */ public List list(java.lang.String parent) throws java.io.IOException { List result = new List(parent); initialize(result); return result; } public class List extends CloudHealthcareRequest<com.google.api.services.healthcare.v1beta1.model.ListHl7V2StoresResponse> { private static final String REST_PATH = "v1beta1/{+parent}/hl7V2Stores"; private final java.util.regex.Pattern PARENT_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/datasets/[^/]+$"); /** * Lists the HL7v2 stores in the given dataset. * * Create a request for the method "hl7V2Stores.list". * * This request holds the parameters needed by the the healthcare server. After setting any * optional parameters, call the {@link List#execute()} method to invoke the remote operation. <p> * {@link List#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} * must be called to initialize this instance immediately after invoking the constructor. </p> * * @param parent Name of the dataset. * @since 1.13 */ protected List(java.lang.String parent) { super(CloudHealthcare.this, "GET", REST_PATH, null, com.google.api.services.healthcare.v1beta1.model.ListHl7V2StoresResponse.class); this.parent = com.google.api.client.util.Preconditions.checkNotNull(parent, "Required parameter parent must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), "Parameter parent must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+$"); } } @Override public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException { return super.executeUsingHead(); } @Override public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException { return super.buildHttpRequestUsingHead(); } @Override public List set$Xgafv(java.lang.String $Xgafv) { return (List) super.set$Xgafv($Xgafv); } @Override public List setAccessToken(java.lang.String accessToken) { return (List) super.setAccessToken(accessToken); } @Override public List setAlt(java.lang.String alt) { return (List) super.setAlt(alt); } @Override public List setCallback(java.lang.String callback) { return (List) super.setCallback(callback); } @Override public List setFields(java.lang.String fields) { return (List) super.setFields(fields); } @Override public List setKey(java.lang.String key) { return (List) super.setKey(key); } @Override public List setOauthToken(java.lang.String oauthToken) { return (List) super.setOauthToken(oauthToken); } @Override public List setPrettyPrint(java.lang.Boolean prettyPrint) { return (List) super.setPrettyPrint(prettyPrint); } @Override public List setQuotaUser(java.lang.String quotaUser) { return (List) super.setQuotaUser(quotaUser); } @Override public List setUploadType(java.lang.String uploadType) { return (List) super.setUploadType(uploadType); } @Override public List setUploadProtocol(java.lang.String uploadProtocol) { return (List) super.setUploadProtocol(uploadProtocol); } /** Name of the dataset. */ @com.google.api.client.util.Key private java.lang.String parent; /** Name of the dataset. */ public java.lang.String getParent() { return parent; } /** Name of the dataset. */ public List setParent(java.lang.String parent) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), "Parameter parent must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+$"); } this.parent = parent; return this; } /** * Restricts stores returned to those matching a filter. Syntax: * https://cloud.google.com/appengine/docs/standard/python/search/query_strings Only * filtering on labels is supported. For example, `labels.key=value`. */ @com.google.api.client.util.Key private java.lang.String filter; /** Restricts stores returned to those matching a filter. Syntax: https://cloud.google.com/appengine/docs/standard/python/search/query_strings Only filtering on labels is supported. For example, `labels.key=value`. */ public java.lang.String getFilter() { return filter; } /** * Restricts stores returned to those matching a filter. Syntax: * https://cloud.google.com/appengine/docs/standard/python/search/query_strings Only * filtering on labels is supported. For example, `labels.key=value`. */ public List setFilter(java.lang.String filter) { this.filter = filter; return this; } /** * Limit on the number of HL7v2 stores to return in a single response. If zero the * default page size of 100 is used. */ @com.google.api.client.util.Key private java.lang.Integer pageSize; /** Limit on the number of HL7v2 stores to return in a single response. If zero the default page size of 100 is used. */ public java.lang.Integer getPageSize() { return pageSize; } /** * Limit on the number of HL7v2 stores to return in a single response. If zero the * default page size of 100 is used. */ public List setPageSize(java.lang.Integer pageSize) { this.pageSize = pageSize; return this; } /** The next_page_token value returned from the previous List request, if any. */ @com.google.api.client.util.Key private java.lang.String pageToken; /** The next_page_token value returned from the previous List request, if any. */ public java.lang.String getPageToken() { return pageToken; } /** The next_page_token value returned from the previous List request, if any. */ public List setPageToken(java.lang.String pageToken) { this.pageToken = pageToken; return this; } @Override public List set(String parameterName, Object value) { return (List) super.set(parameterName, value); } } /** * Updates the HL7v2 store. * * Create a request for the method "hl7V2Stores.patch". * * This request holds the parameters needed by the healthcare server. After setting any optional * parameters, call the {@link Patch#execute()} method to invoke the remote operation. * * @param name Output only. Resource name of the HL7v2 store, of the form * `projects/{project_id}/datasets/{dataset_id}/hl7V2Stores/{hl7v2_store_id}`. * @param content the {@link com.google.api.services.healthcare.v1beta1.model.Hl7V2Store} * @return the request */ public Patch patch(java.lang.String name, com.google.api.services.healthcare.v1beta1.model.Hl7V2Store content) throws java.io.IOException { Patch result = new Patch(name, content); initialize(result); return result; } public class Patch extends CloudHealthcareRequest<com.google.api.services.healthcare.v1beta1.model.Hl7V2Store> { private static final String REST_PATH = "v1beta1/{+name}"; private final java.util.regex.Pattern NAME_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/datasets/[^/]+/hl7V2Stores/[^/]+$"); /** * Updates the HL7v2 store. * * Create a request for the method "hl7V2Stores.patch". * * This request holds the parameters needed by the the healthcare server. After setting any * optional parameters, call the {@link Patch#execute()} method to invoke the remote operation. * <p> {@link * Patch#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} must * be called to initialize this instance immediately after invoking the constructor. </p> * * @param name Output only. Resource name of the HL7v2 store, of the form * `projects/{project_id}/datasets/{dataset_id}/hl7V2Stores/{hl7v2_store_id}`. * @param content the {@link com.google.api.services.healthcare.v1beta1.model.Hl7V2Store} * @since 1.13 */ protected Patch(java.lang.String name, com.google.api.services.healthcare.v1beta1.model.Hl7V2Store content) { super(CloudHealthcare.this, "PATCH", REST_PATH, content, com.google.api.services.healthcare.v1beta1.model.Hl7V2Store.class); this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), "Parameter name must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/hl7V2Stores/[^/]+$"); } } @Override public Patch set$Xgafv(java.lang.String $Xgafv) { return (Patch) super.set$Xgafv($Xgafv); } @Override public Patch setAccessToken(java.lang.String accessToken) { return (Patch) super.setAccessToken(accessToken); } @Override public Patch setAlt(java.lang.String alt) { return (Patch) super.setAlt(alt); } @Override public Patch setCallback(java.lang.String callback) { return (Patch) super.setCallback(callback); } @Override public Patch setFields(java.lang.String fields) { return (Patch) super.setFields(fields); } @Override public Patch setKey(java.lang.String key) { return (Patch) super.setKey(key); } @Override public Patch setOauthToken(java.lang.String oauthToken) { return (Patch) super.setOauthToken(oauthToken); } @Override public Patch setPrettyPrint(java.lang.Boolean prettyPrint) { return (Patch) super.setPrettyPrint(prettyPrint); } @Override public Patch setQuotaUser(java.lang.String quotaUser) { return (Patch) super.setQuotaUser(quotaUser); } @Override public Patch setUploadType(java.lang.String uploadType) { return (Patch) super.setUploadType(uploadType); } @Override public Patch setUploadProtocol(java.lang.String uploadProtocol) { return (Patch) super.setUploadProtocol(uploadProtocol); } /** * Output only. Resource name of the HL7v2 store, of the form * `projects/{project_id}/datasets/{dataset_id}/hl7V2Stores/{hl7v2_store_id}`. */ @com.google.api.client.util.Key private java.lang.String name; /** Output only. Resource name of the HL7v2 store, of the form `projects/{project_id}/datasets/{dataset_id}/hl7V2Stores/{hl7v2_store_id}`. */ public java.lang.String getName() { return name; } /** * Output only. Resource name of the HL7v2 store, of the form * `projects/{project_id}/datasets/{dataset_id}/hl7V2Stores/{hl7v2_store_id}`. */ public Patch setName(java.lang.String name) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), "Parameter name must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/hl7V2Stores/[^/]+$"); } this.name = name; return this; } /** * The update mask applies to the resource. For the `FieldMask` definition, see * https://developers.google.com/protocol- * buffers/docs/reference/google.protobuf#fieldmask */ @com.google.api.client.util.Key private String updateMask; /** The update mask applies to the resource. For the `FieldMask` definition, see https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#fieldmask */ public String getUpdateMask() { return updateMask; } /** * The update mask applies to the resource. For the `FieldMask` definition, see * https://developers.google.com/protocol- * buffers/docs/reference/google.protobuf#fieldmask */ public Patch setUpdateMask(String updateMask) { this.updateMask = updateMask; return this; } @Override public Patch set(String parameterName, Object value) { return (Patch) super.set(parameterName, value); } } /** * Sets the access control policy on the specified resource. Replaces any existing policy. * * Can return Public Errors: NOT_FOUND, INVALID_ARGUMENT and PERMISSION_DENIED * * Create a request for the method "hl7V2Stores.setIamPolicy". * * This request holds the parameters needed by the healthcare server. After setting any optional * parameters, call the {@link SetIamPolicy#execute()} method to invoke the remote operation. * * @param resource REQUIRED: The resource for which the policy is being specified. See the operation documentation for * the appropriate value for this field. * @param content the {@link com.google.api.services.healthcare.v1beta1.model.SetIamPolicyRequest} * @return the request */ public SetIamPolicy setIamPolicy(java.lang.String resource, com.google.api.services.healthcare.v1beta1.model.SetIamPolicyRequest content) throws java.io.IOException { SetIamPolicy result = new SetIamPolicy(resource, content); initialize(result); return result; } public class SetIamPolicy extends CloudHealthcareRequest<com.google.api.services.healthcare.v1beta1.model.Policy> { private static final String REST_PATH = "v1beta1/{+resource}:setIamPolicy"; private final java.util.regex.Pattern RESOURCE_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/datasets/[^/]+/hl7V2Stores/[^/]+$"); /** * Sets the access control policy on the specified resource. Replaces any existing policy. * * Can return Public Errors: NOT_FOUND, INVALID_ARGUMENT and PERMISSION_DENIED * * Create a request for the method "hl7V2Stores.setIamPolicy". * * This request holds the parameters needed by the the healthcare server. After setting any * optional parameters, call the {@link SetIamPolicy#execute()} method to invoke the remote * operation. <p> {@link * SetIamPolicy#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} * must be called to initialize this instance immediately after invoking the constructor. </p> * * @param resource REQUIRED: The resource for which the policy is being specified. See the operation documentation for * the appropriate value for this field. * @param content the {@link com.google.api.services.healthcare.v1beta1.model.SetIamPolicyRequest} * @since 1.13 */ protected SetIamPolicy(java.lang.String resource, com.google.api.services.healthcare.v1beta1.model.SetIamPolicyRequest content) { super(CloudHealthcare.this, "POST", REST_PATH, content, com.google.api.services.healthcare.v1beta1.model.Policy.class); this.resource = com.google.api.client.util.Preconditions.checkNotNull(resource, "Required parameter resource must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(RESOURCE_PATTERN.matcher(resource).matches(), "Parameter resource must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/hl7V2Stores/[^/]+$"); } } @Override public SetIamPolicy set$Xgafv(java.lang.String $Xgafv) { return (SetIamPolicy) super.set$Xgafv($Xgafv); } @Override public SetIamPolicy setAccessToken(java.lang.String accessToken) { return (SetIamPolicy) super.setAccessToken(accessToken); } @Override public SetIamPolicy setAlt(java.lang.String alt) { return (SetIamPolicy) super.setAlt(alt); } @Override public SetIamPolicy setCallback(java.lang.String callback) { return (SetIamPolicy) super.setCallback(callback); } @Override public SetIamPolicy setFields(java.lang.String fields) { return (SetIamPolicy) super.setFields(fields); } @Override public SetIamPolicy setKey(java.lang.String key) { return (SetIamPolicy) super.setKey(key); } @Override public SetIamPolicy setOauthToken(java.lang.String oauthToken) { return (SetIamPolicy) super.setOauthToken(oauthToken); } @Override public SetIamPolicy setPrettyPrint(java.lang.Boolean prettyPrint) { return (SetIamPolicy) super.setPrettyPrint(prettyPrint); } @Override public SetIamPolicy setQuotaUser(java.lang.String quotaUser) { return (SetIamPolicy) super.setQuotaUser(quotaUser); } @Override public SetIamPolicy setUploadType(java.lang.String uploadType) { return (SetIamPolicy) super.setUploadType(uploadType); } @Override public SetIamPolicy setUploadProtocol(java.lang.String uploadProtocol) { return (SetIamPolicy) super.setUploadProtocol(uploadProtocol); } /** * REQUIRED: The resource for which the policy is being specified. See the operation * documentation for the appropriate value for this field. */ @com.google.api.client.util.Key private java.lang.String resource; /** REQUIRED: The resource for which the policy is being specified. See the operation documentation for the appropriate value for this field. */ public java.lang.String getResource() { return resource; } /** * REQUIRED: The resource for which the policy is being specified. See the operation * documentation for the appropriate value for this field. */ public SetIamPolicy setResource(java.lang.String resource) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(RESOURCE_PATTERN.matcher(resource).matches(), "Parameter resource must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/hl7V2Stores/[^/]+$"); } this.resource = resource; return this; } @Override public SetIamPolicy set(String parameterName, Object value) { return (SetIamPolicy) super.set(parameterName, value); } } /** * Returns permissions that a caller has on the specified resource. If the resource does not exist, * this will return an empty set of permissions, not a NOT_FOUND error. * * Note: This operation is designed to be used for building permission-aware UIs and command-line * tools, not for authorization checking. This operation may "fail open" without warning. * * Create a request for the method "hl7V2Stores.testIamPermissions". * * This request holds the parameters needed by the healthcare server. After setting any optional * parameters, call the {@link TestIamPermissions#execute()} method to invoke the remote operation. * * @param resource REQUIRED: The resource for which the policy detail is being requested. See the operation * documentation for the appropriate value for this field. * @param content the {@link com.google.api.services.healthcare.v1beta1.model.TestIamPermissionsRequest} * @return the request */ public TestIamPermissions testIamPermissions(java.lang.String resource, com.google.api.services.healthcare.v1beta1.model.TestIamPermissionsRequest content) throws java.io.IOException { TestIamPermissions result = new TestIamPermissions(resource, content); initialize(result); return result; } public class TestIamPermissions extends CloudHealthcareRequest<com.google.api.services.healthcare.v1beta1.model.TestIamPermissionsResponse> { private static final String REST_PATH = "v1beta1/{+resource}:testIamPermissions"; private final java.util.regex.Pattern RESOURCE_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/datasets/[^/]+/hl7V2Stores/[^/]+$"); /** * Returns permissions that a caller has on the specified resource. If the resource does not * exist, this will return an empty set of permissions, not a NOT_FOUND error. * * Note: This operation is designed to be used for building permission-aware UIs and command-line * tools, not for authorization checking. This operation may "fail open" without warning. * * Create a request for the method "hl7V2Stores.testIamPermissions". * * This request holds the parameters needed by the the healthcare server. After setting any * optional parameters, call the {@link TestIamPermissions#execute()} method to invoke the remote * operation. <p> {@link TestIamPermissions#initialize(com.google.api.client.googleapis.services.A * bstractGoogleClientRequest)} must be called to initialize this instance immediately after * invoking the constructor. </p> * * @param resource REQUIRED: The resource for which the policy detail is being requested. See the operation * documentation for the appropriate value for this field. * @param content the {@link com.google.api.services.healthcare.v1beta1.model.TestIamPermissionsRequest} * @since 1.13 */ protected TestIamPermissions(java.lang.String resource, com.google.api.services.healthcare.v1beta1.model.TestIamPermissionsRequest content) { super(CloudHealthcare.this, "POST", REST_PATH, content, com.google.api.services.healthcare.v1beta1.model.TestIamPermissionsResponse.class); this.resource = com.google.api.client.util.Preconditions.checkNotNull(resource, "Required parameter resource must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(RESOURCE_PATTERN.matcher(resource).matches(), "Parameter resource must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/hl7V2Stores/[^/]+$"); } } @Override public TestIamPermissions set$Xgafv(java.lang.String $Xgafv) { return (TestIamPermissions) super.set$Xgafv($Xgafv); } @Override public TestIamPermissions setAccessToken(java.lang.String accessToken) { return (TestIamPermissions) super.setAccessToken(accessToken); } @Override public TestIamPermissions setAlt(java.lang.String alt) { return (TestIamPermissions) super.setAlt(alt); } @Override public TestIamPermissions setCallback(java.lang.String callback) { return (TestIamPermissions) super.setCallback(callback); } @Override public TestIamPermissions setFields(java.lang.String fields) { return (TestIamPermissions) super.setFields(fields); } @Override public TestIamPermissions setKey(java.lang.String key) { return (TestIamPermissions) super.setKey(key); } @Override public TestIamPermissions setOauthToken(java.lang.String oauthToken) { return (TestIamPermissions) super.setOauthToken(oauthToken); } @Override public TestIamPermissions setPrettyPrint(java.lang.Boolean prettyPrint) { return (TestIamPermissions) super.setPrettyPrint(prettyPrint); } @Override public TestIamPermissions setQuotaUser(java.lang.String quotaUser) { return (TestIamPermissions) super.setQuotaUser(quotaUser); } @Override public TestIamPermissions setUploadType(java.lang.String uploadType) { return (TestIamPermissions) super.setUploadType(uploadType); } @Override public TestIamPermissions setUploadProtocol(java.lang.String uploadProtocol) { return (TestIamPermissions) super.setUploadProtocol(uploadProtocol); } /** * REQUIRED: The resource for which the policy detail is being requested. See the * operation documentation for the appropriate value for this field. */ @com.google.api.client.util.Key private java.lang.String resource; /** REQUIRED: The resource for which the policy detail is being requested. See the operation documentation for the appropriate value for this field. */ public java.lang.String getResource() { return resource; } /** * REQUIRED: The resource for which the policy detail is being requested. See the * operation documentation for the appropriate value for this field. */ public TestIamPermissions setResource(java.lang.String resource) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(RESOURCE_PATTERN.matcher(resource).matches(), "Parameter resource must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/hl7V2Stores/[^/]+$"); } this.resource = resource; return this; } @Override public TestIamPermissions set(String parameterName, Object value) { return (TestIamPermissions) super.set(parameterName, value); } } /** * An accessor for creating requests from the Messages collection. * * <p>The typical use is:</p> * <pre> * {@code CloudHealthcare healthcare = new CloudHealthcare(...);} * {@code CloudHealthcare.Messages.List request = healthcare.messages().list(parameters ...)} * </pre> * * @return the resource collection */ public Messages messages() { return new Messages(); } /** * The "messages" collection of methods. */ public class Messages { /** * Creates a message and sends a notification to the Cloud Pub/Sub topic. If configured, the MLLP * adapter listens to messages created by this method and sends those back to the hospital. A * successful response indicates the message has been persisted to storage and a Cloud Pub/Sub * notification has been sent. Sending to the hospital by the MLLP adapter happens asynchronously. * * Create a request for the method "messages.create". * * This request holds the parameters needed by the healthcare server. After setting any optional * parameters, call the {@link Create#execute()} method to invoke the remote operation. * * @param parent The name of the dataset this message belongs to. * @param content the {@link com.google.api.services.healthcare.v1beta1.model.CreateMessageRequest} * @return the request */ public Create create(java.lang.String parent, com.google.api.services.healthcare.v1beta1.model.CreateMessageRequest content) throws java.io.IOException { Create result = new Create(parent, content); initialize(result); return result; } public class Create extends CloudHealthcareRequest<com.google.api.services.healthcare.v1beta1.model.Message> { private static final String REST_PATH = "v1beta1/{+parent}/messages"; private final java.util.regex.Pattern PARENT_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/datasets/[^/]+/hl7V2Stores/[^/]+$"); /** * Creates a message and sends a notification to the Cloud Pub/Sub topic. If configured, the MLLP * adapter listens to messages created by this method and sends those back to the hospital. A * successful response indicates the message has been persisted to storage and a Cloud Pub/Sub * notification has been sent. Sending to the hospital by the MLLP adapter happens asynchronously. * * Create a request for the method "messages.create". * * This request holds the parameters needed by the the healthcare server. After setting any * optional parameters, call the {@link Create#execute()} method to invoke the remote operation. * <p> {@link * Create#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} must * be called to initialize this instance immediately after invoking the constructor. </p> * * @param parent The name of the dataset this message belongs to. * @param content the {@link com.google.api.services.healthcare.v1beta1.model.CreateMessageRequest} * @since 1.13 */ protected Create(java.lang.String parent, com.google.api.services.healthcare.v1beta1.model.CreateMessageRequest content) { super(CloudHealthcare.this, "POST", REST_PATH, content, com.google.api.services.healthcare.v1beta1.model.Message.class); this.parent = com.google.api.client.util.Preconditions.checkNotNull(parent, "Required parameter parent must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), "Parameter parent must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/hl7V2Stores/[^/]+$"); } } @Override public Create set$Xgafv(java.lang.String $Xgafv) { return (Create) super.set$Xgafv($Xgafv); } @Override public Create setAccessToken(java.lang.String accessToken) { return (Create) super.setAccessToken(accessToken); } @Override public Create setAlt(java.lang.String alt) { return (Create) super.setAlt(alt); } @Override public Create setCallback(java.lang.String callback) { return (Create) super.setCallback(callback); } @Override public Create setFields(java.lang.String fields) { return (Create) super.setFields(fields); } @Override public Create setKey(java.lang.String key) { return (Create) super.setKey(key); } @Override public Create setOauthToken(java.lang.String oauthToken) { return (Create) super.setOauthToken(oauthToken); } @Override public Create setPrettyPrint(java.lang.Boolean prettyPrint) { return (Create) super.setPrettyPrint(prettyPrint); } @Override public Create setQuotaUser(java.lang.String quotaUser) { return (Create) super.setQuotaUser(quotaUser); } @Override public Create setUploadType(java.lang.String uploadType) { return (Create) super.setUploadType(uploadType); } @Override public Create setUploadProtocol(java.lang.String uploadProtocol) { return (Create) super.setUploadProtocol(uploadProtocol); } /** The name of the dataset this message belongs to. */ @com.google.api.client.util.Key private java.lang.String parent; /** The name of the dataset this message belongs to. */ public java.lang.String getParent() { return parent; } /** The name of the dataset this message belongs to. */ public Create setParent(java.lang.String parent) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), "Parameter parent must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/hl7V2Stores/[^/]+$"); } this.parent = parent; return this; } @Override public Create set(String parameterName, Object value) { return (Create) super.set(parameterName, value); } } /** * Deletes an HL7v2 message. * * Create a request for the method "messages.delete". * * This request holds the parameters needed by the healthcare server. After setting any optional * parameters, call the {@link Delete#execute()} method to invoke the remote operation. * * @param name The resource name of the HL7v2 message to delete. * @return the request */ public Delete delete(java.lang.String name) throws java.io.IOException { Delete result = new Delete(name); initialize(result); return result; } public class Delete extends CloudHealthcareRequest<com.google.api.services.healthcare.v1beta1.model.Empty> { private static final String REST_PATH = "v1beta1/{+name}"; private final java.util.regex.Pattern NAME_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/datasets/[^/]+/hl7V2Stores/[^/]+/messages/[^/]+$"); /** * Deletes an HL7v2 message. * * Create a request for the method "messages.delete". * * This request holds the parameters needed by the the healthcare server. After setting any * optional parameters, call the {@link Delete#execute()} method to invoke the remote operation. * <p> {@link * Delete#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} must * be called to initialize this instance immediately after invoking the constructor. </p> * * @param name The resource name of the HL7v2 message to delete. * @since 1.13 */ protected Delete(java.lang.String name) { super(CloudHealthcare.this, "DELETE", REST_PATH, null, com.google.api.services.healthcare.v1beta1.model.Empty.class); this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), "Parameter name must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/hl7V2Stores/[^/]+/messages/[^/]+$"); } } @Override public Delete set$Xgafv(java.lang.String $Xgafv) { return (Delete) super.set$Xgafv($Xgafv); } @Override public Delete setAccessToken(java.lang.String accessToken) { return (Delete) super.setAccessToken(accessToken); } @Override public Delete setAlt(java.lang.String alt) { return (Delete) super.setAlt(alt); } @Override public Delete setCallback(java.lang.String callback) { return (Delete) super.setCallback(callback); } @Override public Delete setFields(java.lang.String fields) { return (Delete) super.setFields(fields); } @Override public Delete setKey(java.lang.String key) { return (Delete) super.setKey(key); } @Override public Delete setOauthToken(java.lang.String oauthToken) { return (Delete) super.setOauthToken(oauthToken); } @Override public Delete setPrettyPrint(java.lang.Boolean prettyPrint) { return (Delete) super.setPrettyPrint(prettyPrint); } @Override public Delete setQuotaUser(java.lang.String quotaUser) { return (Delete) super.setQuotaUser(quotaUser); } @Override public Delete setUploadType(java.lang.String uploadType) { return (Delete) super.setUploadType(uploadType); } @Override public Delete setUploadProtocol(java.lang.String uploadProtocol) { return (Delete) super.setUploadProtocol(uploadProtocol); } /** The resource name of the HL7v2 message to delete. */ @com.google.api.client.util.Key private java.lang.String name; /** The resource name of the HL7v2 message to delete. */ public java.lang.String getName() { return name; } /** The resource name of the HL7v2 message to delete. */ public Delete setName(java.lang.String name) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), "Parameter name must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/hl7V2Stores/[^/]+/messages/[^/]+$"); } this.name = name; return this; } @Override public Delete set(String parameterName, Object value) { return (Delete) super.set(parameterName, value); } } /** * Gets an HL7v2 message. * * Create a request for the method "messages.get". * * This request holds the parameters needed by the healthcare server. After setting any optional * parameters, call the {@link Get#execute()} method to invoke the remote operation. * * @param name The resource name of the HL7v2 message to retrieve. * @return the request */ public Get get(java.lang.String name) throws java.io.IOException { Get result = new Get(name); initialize(result); return result; } public class Get extends CloudHealthcareRequest<com.google.api.services.healthcare.v1beta1.model.Message> { private static final String REST_PATH = "v1beta1/{+name}"; private final java.util.regex.Pattern NAME_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/datasets/[^/]+/hl7V2Stores/[^/]+/messages/[^/]+$"); /** * Gets an HL7v2 message. * * Create a request for the method "messages.get". * * This request holds the parameters needed by the the healthcare server. After setting any * optional parameters, call the {@link Get#execute()} method to invoke the remote operation. <p> * {@link Get#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} * must be called to initialize this instance immediately after invoking the constructor. </p> * * @param name The resource name of the HL7v2 message to retrieve. * @since 1.13 */ protected Get(java.lang.String name) { super(CloudHealthcare.this, "GET", REST_PATH, null, com.google.api.services.healthcare.v1beta1.model.Message.class); this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), "Parameter name must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/hl7V2Stores/[^/]+/messages/[^/]+$"); } } @Override public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException { return super.executeUsingHead(); } @Override public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException { return super.buildHttpRequestUsingHead(); } @Override public Get set$Xgafv(java.lang.String $Xgafv) { return (Get) super.set$Xgafv($Xgafv); } @Override public Get setAccessToken(java.lang.String accessToken) { return (Get) super.setAccessToken(accessToken); } @Override public Get setAlt(java.lang.String alt) { return (Get) super.setAlt(alt); } @Override public Get setCallback(java.lang.String callback) { return (Get) super.setCallback(callback); } @Override public Get setFields(java.lang.String fields) { return (Get) super.setFields(fields); } @Override public Get setKey(java.lang.String key) { return (Get) super.setKey(key); } @Override public Get setOauthToken(java.lang.String oauthToken) { return (Get) super.setOauthToken(oauthToken); } @Override public Get setPrettyPrint(java.lang.Boolean prettyPrint) { return (Get) super.setPrettyPrint(prettyPrint); } @Override public Get setQuotaUser(java.lang.String quotaUser) { return (Get) super.setQuotaUser(quotaUser); } @Override public Get setUploadType(java.lang.String uploadType) { return (Get) super.setUploadType(uploadType); } @Override public Get setUploadProtocol(java.lang.String uploadProtocol) { return (Get) super.setUploadProtocol(uploadProtocol); } /** The resource name of the HL7v2 message to retrieve. */ @com.google.api.client.util.Key private java.lang.String name; /** The resource name of the HL7v2 message to retrieve. */ public java.lang.String getName() { return name; } /** The resource name of the HL7v2 message to retrieve. */ public Get setName(java.lang.String name) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), "Parameter name must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/hl7V2Stores/[^/]+/messages/[^/]+$"); } this.name = name; return this; } /** Specifies which parts of the Message resource to return in the response. */ @com.google.api.client.util.Key private java.lang.String view; /** Specifies which parts of the Message resource to return in the response. */ public java.lang.String getView() { return view; } /** Specifies which parts of the Message resource to return in the response. */ public Get setView(java.lang.String view) { this.view = view; return this; } @Override public Get set(String parameterName, Object value) { return (Get) super.set(parameterName, value); } } /** * Ingests a new HL7v2 message from the hospital and sends a notification to the Cloud Pub/Sub * topic. Return is an HL7v2 ACK message if the message was successfully stored. Otherwise an error * is returned. If an identical HL7v2 message is created twice only one resource is created on the * server and no error is reported. * * Create a request for the method "messages.ingest". * * This request holds the parameters needed by the healthcare server. After setting any optional * parameters, call the {@link Ingest#execute()} method to invoke the remote operation. * * @param parent The name of the HL7v2 store this message belongs to. * @param content the {@link com.google.api.services.healthcare.v1beta1.model.IngestMessageRequest} * @return the request */ public Ingest ingest(java.lang.String parent, com.google.api.services.healthcare.v1beta1.model.IngestMessageRequest content) throws java.io.IOException { Ingest result = new Ingest(parent, content); initialize(result); return result; } public class Ingest extends CloudHealthcareRequest<com.google.api.services.healthcare.v1beta1.model.IngestMessageResponse> { private static final String REST_PATH = "v1beta1/{+parent}/messages:ingest"; private final java.util.regex.Pattern PARENT_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/datasets/[^/]+/hl7V2Stores/[^/]+$"); /** * Ingests a new HL7v2 message from the hospital and sends a notification to the Cloud Pub/Sub * topic. Return is an HL7v2 ACK message if the message was successfully stored. Otherwise an * error is returned. If an identical HL7v2 message is created twice only one resource is created * on the server and no error is reported. * * Create a request for the method "messages.ingest". * * This request holds the parameters needed by the the healthcare server. After setting any * optional parameters, call the {@link Ingest#execute()} method to invoke the remote operation. * <p> {@link * Ingest#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} must * be called to initialize this instance immediately after invoking the constructor. </p> * * @param parent The name of the HL7v2 store this message belongs to. * @param content the {@link com.google.api.services.healthcare.v1beta1.model.IngestMessageRequest} * @since 1.13 */ protected Ingest(java.lang.String parent, com.google.api.services.healthcare.v1beta1.model.IngestMessageRequest content) { super(CloudHealthcare.this, "POST", REST_PATH, content, com.google.api.services.healthcare.v1beta1.model.IngestMessageResponse.class); this.parent = com.google.api.client.util.Preconditions.checkNotNull(parent, "Required parameter parent must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), "Parameter parent must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/hl7V2Stores/[^/]+$"); } } @Override public Ingest set$Xgafv(java.lang.String $Xgafv) { return (Ingest) super.set$Xgafv($Xgafv); } @Override public Ingest setAccessToken(java.lang.String accessToken) { return (Ingest) super.setAccessToken(accessToken); } @Override public Ingest setAlt(java.lang.String alt) { return (Ingest) super.setAlt(alt); } @Override public Ingest setCallback(java.lang.String callback) { return (Ingest) super.setCallback(callback); } @Override public Ingest setFields(java.lang.String fields) { return (Ingest) super.setFields(fields); } @Override public Ingest setKey(java.lang.String key) { return (Ingest) super.setKey(key); } @Override public Ingest setOauthToken(java.lang.String oauthToken) { return (Ingest) super.setOauthToken(oauthToken); } @Override public Ingest setPrettyPrint(java.lang.Boolean prettyPrint) { return (Ingest) super.setPrettyPrint(prettyPrint); } @Override public Ingest setQuotaUser(java.lang.String quotaUser) { return (Ingest) super.setQuotaUser(quotaUser); } @Override public Ingest setUploadType(java.lang.String uploadType) { return (Ingest) super.setUploadType(uploadType); } @Override public Ingest setUploadProtocol(java.lang.String uploadProtocol) { return (Ingest) super.setUploadProtocol(uploadProtocol); } /** The name of the HL7v2 store this message belongs to. */ @com.google.api.client.util.Key private java.lang.String parent; /** The name of the HL7v2 store this message belongs to. */ public java.lang.String getParent() { return parent; } /** The name of the HL7v2 store this message belongs to. */ public Ingest setParent(java.lang.String parent) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), "Parameter parent must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/hl7V2Stores/[^/]+$"); } this.parent = parent; return this; } @Override public Ingest set(String parameterName, Object value) { return (Ingest) super.set(parameterName, value); } } /** * Lists all the messages in the given HL7v2 store with support for filtering. * * Note: HL7v2 messages are indexed asynchronously, so there might be a slight delay between the * time a message is created and when it can be found through a filter. * * Create a request for the method "messages.list". * * This request holds the parameters needed by the healthcare server. After setting any optional * parameters, call the {@link List#execute()} method to invoke the remote operation. * * @param parent Name of the HL7v2 store to retrieve messages from. * @return the request */ public List list(java.lang.String parent) throws java.io.IOException { List result = new List(parent); initialize(result); return result; } public class List extends CloudHealthcareRequest<com.google.api.services.healthcare.v1beta1.model.ListMessagesResponse> { private static final String REST_PATH = "v1beta1/{+parent}/messages"; private final java.util.regex.Pattern PARENT_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/datasets/[^/]+/hl7V2Stores/[^/]+$"); /** * Lists all the messages in the given HL7v2 store with support for filtering. * * Note: HL7v2 messages are indexed asynchronously, so there might be a slight delay between the * time a message is created and when it can be found through a filter. * * Create a request for the method "messages.list". * * This request holds the parameters needed by the the healthcare server. After setting any * optional parameters, call the {@link List#execute()} method to invoke the remote operation. <p> * {@link List#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} * must be called to initialize this instance immediately after invoking the constructor. </p> * * @param parent Name of the HL7v2 store to retrieve messages from. * @since 1.13 */ protected List(java.lang.String parent) { super(CloudHealthcare.this, "GET", REST_PATH, null, com.google.api.services.healthcare.v1beta1.model.ListMessagesResponse.class); this.parent = com.google.api.client.util.Preconditions.checkNotNull(parent, "Required parameter parent must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), "Parameter parent must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/hl7V2Stores/[^/]+$"); } } @Override public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException { return super.executeUsingHead(); } @Override public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException { return super.buildHttpRequestUsingHead(); } @Override public List set$Xgafv(java.lang.String $Xgafv) { return (List) super.set$Xgafv($Xgafv); } @Override public List setAccessToken(java.lang.String accessToken) { return (List) super.setAccessToken(accessToken); } @Override public List setAlt(java.lang.String alt) { return (List) super.setAlt(alt); } @Override public List setCallback(java.lang.String callback) { return (List) super.setCallback(callback); } @Override public List setFields(java.lang.String fields) { return (List) super.setFields(fields); } @Override public List setKey(java.lang.String key) { return (List) super.setKey(key); } @Override public List setOauthToken(java.lang.String oauthToken) { return (List) super.setOauthToken(oauthToken); } @Override public List setPrettyPrint(java.lang.Boolean prettyPrint) { return (List) super.setPrettyPrint(prettyPrint); } @Override public List setQuotaUser(java.lang.String quotaUser) { return (List) super.setQuotaUser(quotaUser); } @Override public List setUploadType(java.lang.String uploadType) { return (List) super.setUploadType(uploadType); } @Override public List setUploadProtocol(java.lang.String uploadProtocol) { return (List) super.setUploadProtocol(uploadProtocol); } /** Name of the HL7v2 store to retrieve messages from. */ @com.google.api.client.util.Key private java.lang.String parent; /** Name of the HL7v2 store to retrieve messages from. */ public java.lang.String getParent() { return parent; } /** Name of the HL7v2 store to retrieve messages from. */ public List setParent(java.lang.String parent) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), "Parameter parent must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/hl7V2Stores/[^/]+$"); } this.parent = parent; return this; } /** * Restricts messages returned to those matching a filter. Syntax: * https://cloud.google.com/appengine/docs/standard/python/search/query_strings * * Fields/functions available for filtering are: * * * `message_type`, from the MSH-9 segment. For example, `NOT message_type = "ADT"`. * * `send_date` or `sendDate`, the YYYY-MM-DD date the message was sent in the * dataset's time_zone, from the MSH-7 segment. For example, `send_date < * "2017-01-02"`. * `send_time`, the timestamp when the message was sent, using the * RFC3339 time format for comparisons, from the MSH-7 segment. For example, * `send_time < "2017-01-02T00:00:00-05:00"`. * `send_facility`, the care center that * the message came from, from the MSH-4 segment. For example, `send_facility = * "ABC"`. * `PatientId(value, type)`, which matches if the message lists a patient * having an ID of the given value and type in the PID-2, PID-3, or PID-4 segments. * For example, `PatientId("123456", "MRN")`. * `labels.x`, a string value of the * label with key `x` as set using the Message.labels map. For example, * `labels."priority"="high"`. The operator `:*` can be used to assert the existence * of a label. For example, `labels."priority":*`. * * Limitations on conjunctions: * * * Negation on the patient ID function or the labels field is not supported. For * example, these queries are invalid: `NOT PatientId("123456", "MRN")`, `NOT * labels."tag1":*`, `NOT labels."tag2"="val2"`. * Conjunction of multiple patient ID * functions is not supported, for example this query is invalid: `PatientId("123456", * "MRN") AND PatientId("456789", "MRN")`. * Conjunction of multiple labels fields is * also not supported, for example this query is invalid: `labels."tag1":* AND * labels."tag2"="val2"`. * Conjunction of one patient ID function, one labels field * and conditions on other fields is supported. For example, this query is valid: * `PatientId("123456", "MRN") AND labels."tag1":* AND message_type = "ADT"`. */ @com.google.api.client.util.Key private java.lang.String filter; /** Restricts messages returned to those matching a filter. Syntax: https://cloud.google.com/appengine/docs/standard/python/search/query_strings Fields/functions available for filtering are: * `message_type`, from the MSH-9 segment. For example, `NOT message_type = "ADT"`. * `send_date` or `sendDate`, the YYYY-MM-DD date the message was sent in the dataset's time_zone, from the MSH-7 segment. For example, `send_date < "2017-01-02"`. * `send_time`, the timestamp when the message was sent, using the RFC3339 time format for comparisons, from the MSH-7 segment. For example, `send_time < "2017-01-02T00:00:00-05:00"`. * `send_facility`, the care center that the message came from, from the MSH-4 segment. For example, `send_facility = "ABC"`. * `PatientId(value, type)`, which matches if the message lists a patient having an ID of the given value and type in the PID-2, PID-3, or PID-4 segments. For example, `PatientId("123456", "MRN")`. * `labels.x`, a string value of the label with key `x` as set using the Message.labels map. For example, `labels."priority"="high"`. The operator `:*` can be used to assert the existence of a label. For example, `labels."priority":*`. Limitations on conjunctions: * Negation on the patient ID function or the labels field is not supported. For example, these queries are invalid: `NOT PatientId("123456", "MRN")`, `NOT labels."tag1":*`, `NOT labels."tag2"="val2"`. * Conjunction of multiple patient ID functions is not supported, for example this query is invalid: `PatientId("123456", "MRN") AND PatientId("456789", "MRN")`. * Conjunction of multiple labels fields is also not supported, for example this query is invalid: `labels."tag1":* AND labels."tag2"="val2"`. * Conjunction of one patient ID function, one labels field and conditions on other fields is supported. For example, this query is valid: `PatientId("123456", "MRN") AND labels."tag1":* AND message_type = "ADT"`. */ public java.lang.String getFilter() { return filter; } /** * Restricts messages returned to those matching a filter. Syntax: * https://cloud.google.com/appengine/docs/standard/python/search/query_strings * * Fields/functions available for filtering are: * * * `message_type`, from the MSH-9 segment. For example, `NOT message_type = "ADT"`. * * `send_date` or `sendDate`, the YYYY-MM-DD date the message was sent in the * dataset's time_zone, from the MSH-7 segment. For example, `send_date < * "2017-01-02"`. * `send_time`, the timestamp when the message was sent, using the * RFC3339 time format for comparisons, from the MSH-7 segment. For example, * `send_time < "2017-01-02T00:00:00-05:00"`. * `send_facility`, the care center that * the message came from, from the MSH-4 segment. For example, `send_facility = * "ABC"`. * `PatientId(value, type)`, which matches if the message lists a patient * having an ID of the given value and type in the PID-2, PID-3, or PID-4 segments. * For example, `PatientId("123456", "MRN")`. * `labels.x`, a string value of the * label with key `x` as set using the Message.labels map. For example, * `labels."priority"="high"`. The operator `:*` can be used to assert the existence * of a label. For example, `labels."priority":*`. * * Limitations on conjunctions: * * * Negation on the patient ID function or the labels field is not supported. For * example, these queries are invalid: `NOT PatientId("123456", "MRN")`, `NOT * labels."tag1":*`, `NOT labels."tag2"="val2"`. * Conjunction of multiple patient ID * functions is not supported, for example this query is invalid: `PatientId("123456", * "MRN") AND PatientId("456789", "MRN")`. * Conjunction of multiple labels fields is * also not supported, for example this query is invalid: `labels."tag1":* AND * labels."tag2"="val2"`. * Conjunction of one patient ID function, one labels field * and conditions on other fields is supported. For example, this query is valid: * `PatientId("123456", "MRN") AND labels."tag1":* AND message_type = "ADT"`. */ public List setFilter(java.lang.String filter) { this.filter = filter; return this; } /** * Orders messages returned by the specified order_by clause. Syntax: * https://cloud.google.com/apis/design/design_patterns#sorting_order * * Fields available for ordering are: * * * `send_time` */ @com.google.api.client.util.Key private java.lang.String orderBy; /** Orders messages returned by the specified order_by clause. Syntax: https://cloud.google.com/apis/design/design_patterns#sorting_order Fields available for ordering are: * `send_time` */ public java.lang.String getOrderBy() { return orderBy; } /** * Orders messages returned by the specified order_by clause. Syntax: * https://cloud.google.com/apis/design/design_patterns#sorting_order * * Fields available for ordering are: * * * `send_time` */ public List setOrderBy(java.lang.String orderBy) { this.orderBy = orderBy; return this; } /** * Limit on the number of messages to return in a single response. If zero the default * page size of 100 is used. */ @com.google.api.client.util.Key private java.lang.Integer pageSize; /** Limit on the number of messages to return in a single response. If zero the default page size of 100 is used. */ public java.lang.Integer getPageSize() { return pageSize; } /** * Limit on the number of messages to return in a single response. If zero the default * page size of 100 is used. */ public List setPageSize(java.lang.Integer pageSize) { this.pageSize = pageSize; return this; } /** The next_page_token value returned from the previous List request, if any. */ @com.google.api.client.util.Key private java.lang.String pageToken; /** The next_page_token value returned from the previous List request, if any. */ public java.lang.String getPageToken() { return pageToken; } /** The next_page_token value returned from the previous List request, if any. */ public List setPageToken(java.lang.String pageToken) { this.pageToken = pageToken; return this; } @Override public List set(String parameterName, Object value) { return (List) super.set(parameterName, value); } } /** * Update the message. * * Create a request for the method "messages.patch". * * This request holds the parameters needed by the healthcare server. After setting any optional * parameters, call the {@link Patch#execute()} method to invoke the remote operation. * * @param name Resource name of the Message, of the form * `projects/{project_id}/datasets/{dataset_id}/hl7V2Stores/{hl7_v2_store_id}/messages/{messa * ge_id}`. Assigned by the server. * @param content the {@link com.google.api.services.healthcare.v1beta1.model.Message} * @return the request */ public Patch patch(java.lang.String name, com.google.api.services.healthcare.v1beta1.model.Message content) throws java.io.IOException { Patch result = new Patch(name, content); initialize(result); return result; } public class Patch extends CloudHealthcareRequest<com.google.api.services.healthcare.v1beta1.model.Message> { private static final String REST_PATH = "v1beta1/{+name}"; private final java.util.regex.Pattern NAME_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/datasets/[^/]+/hl7V2Stores/[^/]+/messages/[^/]+$"); /** * Update the message. * * Create a request for the method "messages.patch". * * This request holds the parameters needed by the the healthcare server. After setting any * optional parameters, call the {@link Patch#execute()} method to invoke the remote operation. * <p> {@link * Patch#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} must * be called to initialize this instance immediately after invoking the constructor. </p> * * @param name Resource name of the Message, of the form * `projects/{project_id}/datasets/{dataset_id}/hl7V2Stores/{hl7_v2_store_id}/messages/{messa * ge_id}`. Assigned by the server. * @param content the {@link com.google.api.services.healthcare.v1beta1.model.Message} * @since 1.13 */ protected Patch(java.lang.String name, com.google.api.services.healthcare.v1beta1.model.Message content) { super(CloudHealthcare.this, "PATCH", REST_PATH, content, com.google.api.services.healthcare.v1beta1.model.Message.class); this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), "Parameter name must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/hl7V2Stores/[^/]+/messages/[^/]+$"); } } @Override public Patch set$Xgafv(java.lang.String $Xgafv) { return (Patch) super.set$Xgafv($Xgafv); } @Override public Patch setAccessToken(java.lang.String accessToken) { return (Patch) super.setAccessToken(accessToken); } @Override public Patch setAlt(java.lang.String alt) { return (Patch) super.setAlt(alt); } @Override public Patch setCallback(java.lang.String callback) { return (Patch) super.setCallback(callback); } @Override public Patch setFields(java.lang.String fields) { return (Patch) super.setFields(fields); } @Override public Patch setKey(java.lang.String key) { return (Patch) super.setKey(key); } @Override public Patch setOauthToken(java.lang.String oauthToken) { return (Patch) super.setOauthToken(oauthToken); } @Override public Patch setPrettyPrint(java.lang.Boolean prettyPrint) { return (Patch) super.setPrettyPrint(prettyPrint); } @Override public Patch setQuotaUser(java.lang.String quotaUser) { return (Patch) super.setQuotaUser(quotaUser); } @Override public Patch setUploadType(java.lang.String uploadType) { return (Patch) super.setUploadType(uploadType); } @Override public Patch setUploadProtocol(java.lang.String uploadProtocol) { return (Patch) super.setUploadProtocol(uploadProtocol); } /** * Resource name of the Message, of the form `projects/{project_id}/datasets/{dataset_ * id}/hl7V2Stores/{hl7_v2_store_id}/messages/{message_id}`. Assigned by the server. */ @com.google.api.client.util.Key private java.lang.String name; /** Resource name of the Message, of the form `projects/{project_id}/datasets/{dataset_id}/hl7V2Stores/{hl7_v2_store_id}/messages/{message_id}`. Assigned by the server. */ public java.lang.String getName() { return name; } /** * Resource name of the Message, of the form `projects/{project_id}/datasets/{dataset_ * id}/hl7V2Stores/{hl7_v2_store_id}/messages/{message_id}`. Assigned by the server. */ public Patch setName(java.lang.String name) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), "Parameter name must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/hl7V2Stores/[^/]+/messages/[^/]+$"); } this.name = name; return this; } /** * The update mask applies to the resource. For the `FieldMask` definition, see * https://developers.google.com/protocol- * buffers/docs/reference/google.protobuf#fieldmask Only the `labels` field is allowed * to be updated. The labels in the request are merged with the existing set of * labels. Existing labels with the same keys are updated. */ @com.google.api.client.util.Key private String updateMask; /** The update mask applies to the resource. For the `FieldMask` definition, see https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#fieldmask Only the `labels` field is allowed to be updated. The labels in the request are merged with the existing set of labels. Existing labels with the same keys are updated. */ public String getUpdateMask() { return updateMask; } /** * The update mask applies to the resource. For the `FieldMask` definition, see * https://developers.google.com/protocol- * buffers/docs/reference/google.protobuf#fieldmask Only the `labels` field is allowed * to be updated. The labels in the request are merged with the existing set of * labels. Existing labels with the same keys are updated. */ public Patch setUpdateMask(String updateMask) { this.updateMask = updateMask; return this; } @Override public Patch set(String parameterName, Object value) { return (Patch) super.set(parameterName, value); } } } } /** * An accessor for creating requests from the Operations collection. * * <p>The typical use is:</p> * <pre> * {@code CloudHealthcare healthcare = new CloudHealthcare(...);} * {@code CloudHealthcare.Operations.List request = healthcare.operations().list(parameters ...)} * </pre> * * @return the resource collection */ public Operations operations() { return new Operations(); } /** * The "operations" collection of methods. */ public class Operations { /** * Gets the latest state of a long-running operation. Clients can use this method to poll the * operation result at intervals as recommended by the API service. * * Create a request for the method "operations.get". * * This request holds the parameters needed by the healthcare server. After setting any optional * parameters, call the {@link Get#execute()} method to invoke the remote operation. * * @param name The name of the operation resource. * @return the request */ public Get get(java.lang.String name) throws java.io.IOException { Get result = new Get(name); initialize(result); return result; } public class Get extends CloudHealthcareRequest<com.google.api.services.healthcare.v1beta1.model.Operation> { private static final String REST_PATH = "v1beta1/{+name}"; private final java.util.regex.Pattern NAME_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/datasets/[^/]+/operations/[^/]+$"); /** * Gets the latest state of a long-running operation. Clients can use this method to poll the * operation result at intervals as recommended by the API service. * * Create a request for the method "operations.get". * * This request holds the parameters needed by the the healthcare server. After setting any * optional parameters, call the {@link Get#execute()} method to invoke the remote operation. <p> * {@link Get#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} * must be called to initialize this instance immediately after invoking the constructor. </p> * * @param name The name of the operation resource. * @since 1.13 */ protected Get(java.lang.String name) { super(CloudHealthcare.this, "GET", REST_PATH, null, com.google.api.services.healthcare.v1beta1.model.Operation.class); this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), "Parameter name must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/operations/[^/]+$"); } } @Override public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException { return super.executeUsingHead(); } @Override public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException { return super.buildHttpRequestUsingHead(); } @Override public Get set$Xgafv(java.lang.String $Xgafv) { return (Get) super.set$Xgafv($Xgafv); } @Override public Get setAccessToken(java.lang.String accessToken) { return (Get) super.setAccessToken(accessToken); } @Override public Get setAlt(java.lang.String alt) { return (Get) super.setAlt(alt); } @Override public Get setCallback(java.lang.String callback) { return (Get) super.setCallback(callback); } @Override public Get setFields(java.lang.String fields) { return (Get) super.setFields(fields); } @Override public Get setKey(java.lang.String key) { return (Get) super.setKey(key); } @Override public Get setOauthToken(java.lang.String oauthToken) { return (Get) super.setOauthToken(oauthToken); } @Override public Get setPrettyPrint(java.lang.Boolean prettyPrint) { return (Get) super.setPrettyPrint(prettyPrint); } @Override public Get setQuotaUser(java.lang.String quotaUser) { return (Get) super.setQuotaUser(quotaUser); } @Override public Get setUploadType(java.lang.String uploadType) { return (Get) super.setUploadType(uploadType); } @Override public Get setUploadProtocol(java.lang.String uploadProtocol) { return (Get) super.setUploadProtocol(uploadProtocol); } /** The name of the operation resource. */ @com.google.api.client.util.Key private java.lang.String name; /** The name of the operation resource. */ public java.lang.String getName() { return name; } /** The name of the operation resource. */ public Get setName(java.lang.String name) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), "Parameter name must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/operations/[^/]+$"); } this.name = name; return this; } @Override public Get set(String parameterName, Object value) { return (Get) super.set(parameterName, value); } } /** * Lists operations that match the specified filter in the request. If the server doesn't support * this method, it returns `UNIMPLEMENTED`. * * NOTE: the `name` binding allows API services to override the binding to use different resource * name schemes, such as `users/operations`. To override the binding, API services can add a binding * such as `"/v1/{name=users}/operations"` to their service configuration. For backwards * compatibility, the default name includes the operations collection id, however overriding users * must ensure the name binding is the parent resource, without the operations collection id. * * Create a request for the method "operations.list". * * This request holds the parameters needed by the healthcare server. After setting any optional * parameters, call the {@link List#execute()} method to invoke the remote operation. * * @param name The name of the operation's parent resource. * @return the request */ public List list(java.lang.String name) throws java.io.IOException { List result = new List(name); initialize(result); return result; } public class List extends CloudHealthcareRequest<com.google.api.services.healthcare.v1beta1.model.ListOperationsResponse> { private static final String REST_PATH = "v1beta1/{+name}/operations"; private final java.util.regex.Pattern NAME_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/datasets/[^/]+$"); /** * Lists operations that match the specified filter in the request. If the server doesn't support * this method, it returns `UNIMPLEMENTED`. * * NOTE: the `name` binding allows API services to override the binding to use different resource * name schemes, such as `users/operations`. To override the binding, API services can add a * binding such as `"/v1/{name=users}/operations"` to their service configuration. For backwards * compatibility, the default name includes the operations collection id, however overriding users * must ensure the name binding is the parent resource, without the operations collection id. * * Create a request for the method "operations.list". * * This request holds the parameters needed by the the healthcare server. After setting any * optional parameters, call the {@link List#execute()} method to invoke the remote operation. <p> * {@link List#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} * must be called to initialize this instance immediately after invoking the constructor. </p> * * @param name The name of the operation's parent resource. * @since 1.13 */ protected List(java.lang.String name) { super(CloudHealthcare.this, "GET", REST_PATH, null, com.google.api.services.healthcare.v1beta1.model.ListOperationsResponse.class); this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), "Parameter name must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+$"); } } @Override public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException { return super.executeUsingHead(); } @Override public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException { return super.buildHttpRequestUsingHead(); } @Override public List set$Xgafv(java.lang.String $Xgafv) { return (List) super.set$Xgafv($Xgafv); } @Override public List setAccessToken(java.lang.String accessToken) { return (List) super.setAccessToken(accessToken); } @Override public List setAlt(java.lang.String alt) { return (List) super.setAlt(alt); } @Override public List setCallback(java.lang.String callback) { return (List) super.setCallback(callback); } @Override public List setFields(java.lang.String fields) { return (List) super.setFields(fields); } @Override public List setKey(java.lang.String key) { return (List) super.setKey(key); } @Override public List setOauthToken(java.lang.String oauthToken) { return (List) super.setOauthToken(oauthToken); } @Override public List setPrettyPrint(java.lang.Boolean prettyPrint) { return (List) super.setPrettyPrint(prettyPrint); } @Override public List setQuotaUser(java.lang.String quotaUser) { return (List) super.setQuotaUser(quotaUser); } @Override public List setUploadType(java.lang.String uploadType) { return (List) super.setUploadType(uploadType); } @Override public List setUploadProtocol(java.lang.String uploadProtocol) { return (List) super.setUploadProtocol(uploadProtocol); } /** The name of the operation's parent resource. */ @com.google.api.client.util.Key private java.lang.String name; /** The name of the operation's parent resource. */ public java.lang.String getName() { return name; } /** The name of the operation's parent resource. */ public List setName(java.lang.String name) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), "Parameter name must conform to the pattern " + "^projects/[^/]+/locations/[^/]+/datasets/[^/]+$"); } this.name = name; return this; } /** The standard list filter. */ @com.google.api.client.util.Key private java.lang.String filter; /** The standard list filter. */ public java.lang.String getFilter() { return filter; } /** The standard list filter. */ public List setFilter(java.lang.String filter) { this.filter = filter; return this; } /** The standard list page size. */ @com.google.api.client.util.Key private java.lang.Integer pageSize; /** The standard list page size. */ public java.lang.Integer getPageSize() { return pageSize; } /** The standard list page size. */ public List setPageSize(java.lang.Integer pageSize) { this.pageSize = pageSize; return this; } /** The standard list page token. */ @com.google.api.client.util.Key private java.lang.String pageToken; /** The standard list page token. */ public java.lang.String getPageToken() { return pageToken; } /** The standard list page token. */ public List setPageToken(java.lang.String pageToken) { this.pageToken = pageToken; return this; } @Override public List set(String parameterName, Object value) { return (List) super.set(parameterName, value); } } } } } } /** * Builder for {@link CloudHealthcare}. * * <p> * Implementation is not thread-safe. * </p> * * @since 1.3.0 */ public static final class Builder extends com.google.api.client.googleapis.services.json.AbstractGoogleJsonClient.Builder { /** * Returns an instance of a new builder. * * @param transport HTTP transport, which should normally be: * <ul> * <li>Google App Engine: * {@code com.google.api.client.extensions.appengine.http.UrlFetchTransport}</li> * <li>Android: {@code newCompatibleTransport} from * {@code com.google.api.client.extensions.android.http.AndroidHttp}</li> * <li>Java: {@link com.google.api.client.googleapis.javanet.GoogleNetHttpTransport#newTrustedTransport()} * </li> * </ul> * @param jsonFactory JSON factory, which may be: * <ul> * <li>Jackson: {@code com.google.api.client.json.jackson2.JacksonFactory}</li> * <li>Google GSON: {@code com.google.api.client.json.gson.GsonFactory}</li> * <li>Android Honeycomb or higher: * {@code com.google.api.client.extensions.android.json.AndroidJsonFactory}</li> * </ul> * @param httpRequestInitializer HTTP request initializer or {@code null} for none * @since 1.7 */ public Builder(com.google.api.client.http.HttpTransport transport, com.google.api.client.json.JsonFactory jsonFactory, com.google.api.client.http.HttpRequestInitializer httpRequestInitializer) { super( transport, jsonFactory, DEFAULT_ROOT_URL, DEFAULT_SERVICE_PATH, httpRequestInitializer, false); setBatchPath(DEFAULT_BATCH_PATH); } /** Builds a new instance of {@link CloudHealthcare}. */ @Override public CloudHealthcare build() { return new CloudHealthcare(this); } @Override public Builder setRootUrl(String rootUrl) { return (Builder) super.setRootUrl(rootUrl); } @Override public Builder setServicePath(String servicePath) { return (Builder) super.setServicePath(servicePath); } @Override public Builder setBatchPath(String batchPath) { return (Builder) super.setBatchPath(batchPath); } @Override public Builder setHttpRequestInitializer(com.google.api.client.http.HttpRequestInitializer httpRequestInitializer) { return (Builder) super.setHttpRequestInitializer(httpRequestInitializer); } @Override public Builder setApplicationName(String applicationName) { return (Builder) super.setApplicationName(applicationName); } @Override public Builder setSuppressPatternChecks(boolean suppressPatternChecks) { return (Builder) super.setSuppressPatternChecks(suppressPatternChecks); } @Override public Builder setSuppressRequiredParameterChecks(boolean suppressRequiredParameterChecks) { return (Builder) super.setSuppressRequiredParameterChecks(suppressRequiredParameterChecks); } @Override public Builder setSuppressAllChecks(boolean suppressAllChecks) { return (Builder) super.setSuppressAllChecks(suppressAllChecks); } /** * Set the {@link CloudHealthcareRequestInitializer}. * * @since 1.12 */ public Builder setCloudHealthcareRequestInitializer( CloudHealthcareRequestInitializer cloudhealthcareRequestInitializer) { return (Builder) super.setGoogleClientRequestInitializer(cloudhealthcareRequestInitializer); } @Override public Builder setGoogleClientRequestInitializer( com.google.api.client.googleapis.services.GoogleClientRequestInitializer googleClientRequestInitializer) { return (Builder) super.setGoogleClientRequestInitializer(googleClientRequestInitializer); } } }
[ "chingor@google.com" ]
chingor@google.com
265b0bbf3d16da6ef0d0d15ae1b32be693137853
63b8f78137bf0b95f55ca9c8d4df2a209471e67a
/javaEx/src/com/java/api/CalendarEx.java
a1ec0cb83587febcb474bd5520fe37398bed7ab2
[]
no_license
sandee-han/bit-java
508d41c65ae8965419deb2960ea72308b18e122e
7b5a268bb16c2ed81bc2a0a4ab04990ae67539f3
refs/heads/master
2022-12-04T08:59:42.118868
2020-08-27T02:49:06
2020-08-27T02:49:06
284,865,249
0
0
null
null
null
null
UTF-8
Java
false
false
1,681
java
package com.java.api; import java.util.Calendar; import java.text.SimpleDateFormat; public class CalendarEx { public static void main(String[] args) { // Calendar 얻기 -> getInstance() Calendar now = Calendar.getInstance(); Calendar custom = Calendar.getInstance(); // 날짜 정보의 변경 custom.set(1999, 11, 31); // 12월 31일 // 상수가 많다 int nowYear = now.get(Calendar.YEAR); int nowMonth = now.get(Calendar.MONTH) + 1; // 주의 : 0부터 시작 int nowDate = now.get(Calendar.DATE); System.out.printf("오늘 %d년 %d월 %d일%n", nowYear, nowMonth, nowDate); // 날짜의 연산 // 10년 뒤로 이동 Calendar future = Calendar.getInstance(); future.add(Calendar.YEAR, 10); System.out.printf("10년 후 : %d년 %d월 %d일%n", future.get(Calendar.YEAR), future.get(Calendar.MONTH) + 1, future.get(Calendar.DATE) ); // 이 날은 무슨 요일? int dow = future.get(Calendar.DAY_OF_WEEK); System.out.println("10년 후 오늘의 요일: " + dow); String dowStr; switch(dow) { case Calendar.SUNDAY: // 1 dowStr = "일요일"; break; case Calendar.MONDAY: dowStr = "월요일"; break; case Calendar.TUESDAY: dowStr = "화요일"; break; case Calendar.WEDNESDAY: dowStr = "수요일"; break; case Calendar.THURSDAY: dowStr = "목요일"; break; case Calendar.FRIDAY: dowStr = "금요일"; break; case Calendar.SATURDAY: dowStr = "토요일"; break; default: dowStr = "?????"; } System.out.println("10년 후 오늘은 " + dowStr); } }
[ "iwmism1938@naver.com" ]
iwmism1938@naver.com
4c7c60a93a827db9d630f7bbfa2a6193540af1b3
a76ee1942c50861df4256887786e948477bebcd3
/app/src/androidTest/java/com/solrom/edgar/petagram20/ExampleInstrumentedTest.java
85db29734eab55f9fd94c6bcb395fc9754290ee3
[]
no_license
EdgarSRSR/Petagram2.0
fb78a318ebfce62306dfeb7ffa513f0dd7faae74
ee045d293c5a4351baf8322b819c1de5ad879250
refs/heads/master
2021-07-03T18:37:00.037941
2017-09-25T23:19:15
2017-09-25T23:19:15
103,080,914
0
0
null
null
null
null
UTF-8
Java
false
false
758
java
package com.solrom.edgar.petagram20; import android.content.Context; import android.support.test.InstrumentationRegistry; import android.support.test.runner.AndroidJUnit4; import org.junit.Test; import org.junit.runner.RunWith; import static org.junit.Assert.*; /** * Instrumentation test, which will execute on an Android device. * * @see <a href="http://d.android.com/tools/testing">Testing documentation</a> */ @RunWith(AndroidJUnit4.class) public class ExampleInstrumentedTest { @Test public void useAppContext() throws Exception { // Context of the app under test. Context appContext = InstrumentationRegistry.getTargetContext(); assertEquals("com.solrom.edgar.petagram20", appContext.getPackageName()); } }
[ "edgarsolisromeu@gmail.com" ]
edgarsolisromeu@gmail.com
d28eb5cb14a2ad536c580c465f2f166ffae905ee
185461a4e1e647918ba491742e27d617072108fd
/JasperReporter/src/main/java/mx/edu/itt/report/template/package-info.java
4ee9bc8cfdc098eb255bab9e7385b78d31ae7fec
[]
no_license
haxdai/JavaFXExampleApp
a8a97421754ef1673c565c0522de4083cc0eaab7
77f13f3166ffd4037b08db9e8caf706681a95659
refs/heads/master
2020-04-07T22:27:20.729176
2018-11-30T16:24:44
2018-11-30T16:24:44
158,770,970
0
0
null
null
null
null
UTF-8
Java
false
false
76
java
/** * */ /** * @author hasdai * */ package mx.edu.itt.report.template;
[ "me@hasdaipacheco.com" ]
me@hasdaipacheco.com
882e1b325be5fa9fad873aa697ea43f1ab4cf5a0
c1365cfc8240097065599c2a97cf3e3706781809
/app/src/main/java/com/example/hotelreserve/ui/HotelDetailFragment.java
f2df8b2a9dfee5052dc36cb8478d1e47f0b66c9f
[ "MIT", "LicenseRef-scancode-unknown-license-reference" ]
permissive
ubelyse/IPWeek
a0f69e834da9c729ea64eccc981579bebd497720
39ef0f463116fe2277ee616b43e14261520e0593
refs/heads/master
2023-02-11T17:22:06.730378
2021-01-13T21:02:57
2021-01-13T21:02:57
327,902,557
0
0
null
null
null
null
UTF-8
Java
false
false
3,438
java
package com.example.hotelreserve.ui; import androidx.fragment.app.Fragment; import android.content.Intent; import android.net.Uri; import android.os.Bundle; import android.view.LayoutInflater; import android.view.View; import android.view.ViewGroup; import android.widget.ImageView; import android.widget.TextView; import com.example.hotelreserve.R; import com.example.hotelreserve.models.Hotels; import com.squareup.picasso.Picasso; import org.parceler.Parcels; import butterknife.BindView; import butterknife.ButterKnife; public class HotelDetailFragment extends Fragment implements View.OnClickListener{ @BindView(R.id.hotelimage) ImageView mImageLabel; @BindView(R.id.hotelnametxt) TextView mNameLabel; @BindView(R.id.hoteltype) TextView mCategoriesLabel; @BindView(R.id.ratingTextView) TextView mRatingLabel; @BindView(R.id.websiteTextView) TextView mWebsiteLabel; @BindView(R.id.phoneTextView) TextView mPhoneLabel; @BindView(R.id.addressTextView) TextView mAddressLabel; @BindView(R.id.savehotelbtn) TextView msavehotelbtn; private Hotels mhotels; public HotelDetailFragment() { // Required empty public constructor } public static HotelDetailFragment newInstance(Hotels hotels){ HotelDetailFragment hotelDetailFragment = new HotelDetailFragment(); Bundle args = new Bundle(); args.putParcelable("hotel", Parcels.wrap(hotels)); hotelDetailFragment.setArguments(args); return hotelDetailFragment; } @Override public void onCreate(Bundle savedInstanceState){ super.onCreate(savedInstanceState); assert getArguments() != null; mhotels = Parcels.unwrap(getArguments().getParcelable("hotel")); } @Override public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) { // Inflate the layout for this fragment View view = inflater.inflate(R.layout.fragment_hotel_detail, container, false); ButterKnife.bind(this, view); Picasso.get().load(mhotels.getImageUrl()).into(mImageLabel); mNameLabel.setText(mhotels.getName()); mCategoriesLabel.setText(android.text.TextUtils.join(", ", mhotels.getCategories())); mRatingLabel.setText(Double.toString(mhotels.getRating()) + "/5"); mPhoneLabel.setText(mhotels.getPhone()); mAddressLabel.setText(android.text.TextUtils.join(", ", mhotels.getAddress())); mWebsiteLabel.setOnClickListener(this); mPhoneLabel.setOnClickListener(this); mAddressLabel.setOnClickListener(this); return view; } @Override public void onClick(View v){ if (v == mWebsiteLabel){ Intent webIntent = new Intent(Intent.ACTION_VIEW, Uri.parse(mhotels.getWebsite())); startActivity(webIntent); } if (v == mPhoneLabel) { Intent phoneIntent = new Intent(Intent.ACTION_DIAL, Uri.parse("tel:" + mhotels.getPhone())); startActivity(phoneIntent); }if (v == mAddressLabel) { Intent mapIntent = new Intent(Intent.ACTION_VIEW, Uri.parse("geo:" + mhotels.getLatitude() + "," + mhotels.getLongitude() + "?q=(" + mhotels.getName() + ")")); startActivity(mapIntent); } } }
[ "ubelyse1@gmail.com" ]
ubelyse1@gmail.com
7ec50495035c92a4305eaa2035dc3666b2ddbcc7
627c5c65298c2a9068e7511d6fdd79b97acc77e1
/17211160128 王泽飞 web大作业/final_work/src/main/java/com/example/final_work/pojo/AdPromotion.java
86a2556c3327e4c4ae18f121aaa0df2ae89dd8fe
[]
no_license
wangzefei98/huashan
7766890e46b596e2798fb278b05b684caa0c7fcb
b3b8a66deaf38cdb7eef3b1584a5117ba2dd9fd9
refs/heads/master
2023-04-23T14:00:27.604006
2021-05-06T02:05:51
2021-05-06T02:09:24
362,680,168
0
0
null
null
null
null
UTF-8
Java
false
false
2,123
java
package com.example.final_work.pojo; import java.util.Date; public class AdPromotion { private Integer id;//主键ID private Integer appId;//appId private String adPicPath;//广告图片存储路径 private Integer adPV;//广告点击量 private Integer carouselPosition;//轮播位(1-n) private Date startTime;//广告起效时间 private Date endTime;//广告失效时间 private Integer createdBy;//创建者 private Date creationDate;//创建时间 private Integer modifyBy;//更新者 private Date modifyDate;//更新时间 private AppInfo appInfo; public AppInfo getAppInfo() { return appInfo; } public void setAppInfo(AppInfo appInfo) { this.appInfo = appInfo; } public Integer getId() { return id; } public void setId(Integer id) { this.id = id; } public Integer getAppId() { return appId; } public void setAppId(Integer appId) { this.appId = appId; } public String getAdPicPath() { return adPicPath; } public void setAdPicPath(String adPicPath) { this.adPicPath = adPicPath; } public Integer getAdPV() { return adPV; } public void setAdPV(Integer adPV) { this.adPV = adPV; } public Integer getCarouselPosition() { return carouselPosition; } public void setCarouselPosition(Integer carouselPosition) { this.carouselPosition = carouselPosition; } public Date getStartTime() { return startTime; } public void setStartTime(Date startTime) { this.startTime = startTime; } public Date getEndTime() { return endTime; } public void setEndTime(Date endTime) { this.endTime = endTime; } public Integer getCreatedBy() { return createdBy; } public void setCreatedBy(Integer createdBy) { this.createdBy = createdBy; } public Date getCreationDate() { return creationDate; } public void setCreationDate(Date creationDate) { this.creationDate = creationDate; } public Integer getModifyBy() { return modifyBy; } public void setModifyBy(Integer modifyBy) { this.modifyBy = modifyBy; } public Date getModifyDate() { return modifyDate; } public void setModifyDate(Date modifyDate) { this.modifyDate = modifyDate; } }
[ "504157333@qq.com" ]
504157333@qq.com
746d65daf03f3401f6cd3d282fc0370c2a8e3d81
a6001e0ef15e682c1ae15bdc12cb4dd7361ae411
/src/main/java/com/clhlock/CLHLock1.java
ac22dfae99b9228a12f40a07dc6129c52552f81c
[]
no_license
shelldonGuo/hello
7988b9babf762a3b5f80b33553675cb6e39d982a
3e1388c2f7da95776e8c93123f7bc617c8830f49
refs/heads/master
2021-01-10T00:53:12.446777
2017-05-04T09:52:13
2017-05-04T09:52:13
37,997,440
0
0
null
null
null
null
UTF-8
Java
false
false
1,697
java
package com.clhlock; import java.util.concurrent.atomic.AtomicReference; public class CLHLock1 { private final ThreadLocal<Node> prev; private final ThreadLocal<Node> current; private final AtomicReference<Node> tail = new AtomicReference<Node>(new Node()); public CLHLock1() { current = new ThreadLocal<Node>() { protected Node initialValue() { return new Node(); } }; prev = new ThreadLocal<Node>(); } public void lock() { final Node node = current.get(); node.locked = true; // 一个CAS操作即可将当前线程对应的节点加入到队列中, // 并且同时获得了前继节点的引用,然后就是等待前继释放锁 Node pred = tail.getAndSet(node); prev.set(pred); // 记录前继节点,在unlock时回收为当前节点,再利用 while (pred.locked) {// 进入自旋 } } public void unlock() { final Node node = current.get(); node.locked = false; // 这里使用前继节点作为当前节点,因为当前节点可能正在被后续节点监控如果 // 如果使用原来的节点作为当前节点,当本线程再次请求lock(locked=true) // 同时后续节点还在监控本节点的锁定状态,则后续节点不能得到锁,本节点也会卡在请求lock上,导致死锁 current.set(prev.get()); // current.set(new Node()); // 如果不使用回收的前继节点,则需要重新生成一个节点。老的当前节点不能立刻用 } private class Node { private volatile boolean locked = false; } }
[ "guoxuedong@xiaomi.com" ]
guoxuedong@xiaomi.com
274f1cf83319b1223776b6c7bd29ea0b04adde18
40782d39533f9352d767a92851c1e46f8cd5efaf
/ql/src/test/org/apache/hadoop/hive/ql/exec/TestExecDriver.java
0eb7c5ae00793cd36eb98d9ca7e26bbe997b0031
[ "Apache-2.0", "MIT", "JSON", "GPL-1.0-or-later", "BSD-3-Clause", "LicenseRef-scancode-jdbm-1.00" ]
permissive
ycp1027/hive0.14--dgf
fe685ef55457b2f17f486fb13d9d66cd20b1f87c
fb4beba60270f3f1dba4ffc04579cc32b54bf732
refs/heads/master
2022-10-29T07:10:16.030631
2019-12-16T08:01:39
2019-12-16T08:01:39
228,332,697
0
0
Apache-2.0
2022-10-05T00:00:09
2019-12-16T07:56:07
Java
UTF-8
Java
false
false
21,506
java
/** * Licensed to the Apache Software Foundation (ASF) under one * or more contributor license agreements. See the NOTICE file * distributed with this work for additional information * regarding copyright ownership. The ASF licenses this file * to you under the Apache License, Version 2.0 (the * "License"); you may not use this file except in compliance * with the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ package org.apache.hadoop.hive.ql.exec; import java.io.File; import java.io.FileInputStream; import java.util.ArrayList; import java.util.LinkedList; import java.util.List; import junit.framework.TestCase; import org.apache.commons.logging.Log; import org.apache.commons.logging.LogFactory; import org.apache.hadoop.fs.FSDataInputStream; import org.apache.hadoop.fs.FileSystem; import org.apache.hadoop.fs.Path; import org.apache.hadoop.hive.conf.HiveConf; import org.apache.hadoop.hive.metastore.MetaStoreUtils; import org.apache.hadoop.hive.ql.DriverContext; import org.apache.hadoop.hive.ql.WindowsPathUtil; import org.apache.hadoop.hive.ql.exec.mr.ExecDriver; import org.apache.hadoop.hive.ql.exec.mr.MapRedTask; import org.apache.hadoop.hive.ql.io.AcidUtils; import org.apache.hadoop.hive.ql.io.IgnoreKeyTextOutputFormat; import org.apache.hadoop.hive.ql.metadata.Hive; import org.apache.hadoop.hive.ql.metadata.Table; import org.apache.hadoop.hive.ql.parse.SemanticException; import org.apache.hadoop.hive.ql.plan.ExprNodeColumnDesc; import org.apache.hadoop.hive.ql.plan.ExprNodeConstantDesc; import org.apache.hadoop.hive.ql.plan.ExprNodeDesc; import org.apache.hadoop.hive.ql.plan.ExprNodeFieldDesc; import org.apache.hadoop.hive.ql.plan.ExprNodeGenericFuncDesc; import org.apache.hadoop.hive.ql.plan.ExtractDesc; import org.apache.hadoop.hive.ql.plan.FileSinkDesc; import org.apache.hadoop.hive.ql.plan.FilterDesc; import org.apache.hadoop.hive.ql.plan.MapredWork; import org.apache.hadoop.hive.ql.plan.PartitionDesc; import org.apache.hadoop.hive.ql.plan.PlanUtils; import org.apache.hadoop.hive.ql.plan.ReduceSinkDesc; import org.apache.hadoop.hive.ql.plan.ReduceWork; import org.apache.hadoop.hive.ql.plan.ScriptDesc; import org.apache.hadoop.hive.ql.plan.SelectDesc; import org.apache.hadoop.hive.ql.session.SessionState; import org.apache.hadoop.hive.serde.serdeConstants; import org.apache.hadoop.hive.serde2.typeinfo.TypeInfoFactory; import org.apache.hadoop.mapred.TextInputFormat; import org.apache.hadoop.util.Shell; /** * Mimics the actual query compiler in generating end to end plans and testing * them out. * */ public class TestExecDriver extends TestCase { static HiveConf conf; private static final String tmpdir; private static final Log LOG = LogFactory.getLog(TestExecDriver.class); private static final Path tmppath; private static Hive db; private static FileSystem fs; static { try { conf = new HiveConf(ExecDriver.class); conf.setBoolVar(HiveConf.ConfVars.SUBMITVIACHILD, true); conf.setBoolVar(HiveConf.ConfVars.SUBMITLOCALTASKVIACHILD, true); SessionState.start(conf); //convert possible incompatible Windows path in config if (Shell.WINDOWS) { WindowsPathUtil.convertPathsFromWindowsToHdfs(conf); } tmpdir = System.getProperty("test.tmp.dir"); tmppath = new Path(tmpdir); fs = FileSystem.get(conf); if (fs.exists(tmppath) && !fs.getFileStatus(tmppath).isDir()) { throw new RuntimeException(tmpdir + " exists but is not a directory"); } if (!fs.exists(tmppath)) { if (!fs.mkdirs(tmppath)) { throw new RuntimeException("Could not make scratch directory " + tmpdir); } } LOG.info("Directory of actual files: " + tmppath); for (Object one : Utilities.makeList("mapplan1.out", "mapplan2.out", "mapredplan1.out", "mapredplan2.out", "mapredplan3.out", "mapredplan4.out", "mapredplan5.out", "mapredplan6.out")) { Path onedir = new Path(tmppath, (String) one); if (fs.exists(onedir)) { fs.delete(onedir, true); } } // copy the test files into hadoop if required. int i = 0; Path[] hadoopDataFile = new Path[2]; String[] testFiles = {"kv1.txt", "kv2.txt"}; String testFileDir = new Path(conf.get("test.data.files")).toUri().getPath(); LOG.info("Directory of expected files: " + testFileDir); for (String oneFile : testFiles) { Path localDataFile = new Path(testFileDir, oneFile); hadoopDataFile[i] = new Path(tmppath, oneFile); fs.copyFromLocalFile(false, true, localDataFile, hadoopDataFile[i]); i++; } // load the test files into tables i = 0; db = Hive.get(conf); String[] srctables = {"src", "src2"}; LinkedList<String> cols = new LinkedList<String>(); cols.add("key"); cols.add("value"); for (String src : srctables) { db.dropTable(MetaStoreUtils.DEFAULT_DATABASE_NAME, src, true, true); db.createTable(src, cols, null, TextInputFormat.class, IgnoreKeyTextOutputFormat.class); db.loadTable(hadoopDataFile[i], src, false, false, true, false, false); i++; } } catch (Throwable e) { throw new RuntimeException("Encountered throwable", e); } } MapredWork mr; @Override protected void setUp() { mr = PlanUtils.getMapRedWork(); } public static void addMapWork(MapredWork mr, Table tbl, String alias, Operator<?> work) { mr.getMapWork().addMapWork(tbl.getDataLocation().toString(), alias, work, new PartitionDesc( Utilities.getTableDesc(tbl), null)); } private static void fileDiff(String datafile, String testdir) throws Exception { String testFileDir = conf.get("test.data.files"); FileInputStream fi_gold = new FileInputStream(new File(testFileDir, datafile)); // inbuilt assumption that the testdir has only one output file. Path di_test = new Path(tmppath, testdir); if (!fs.exists(di_test)) { throw new RuntimeException(tmpdir + File.separator + testdir + " does not exist"); } if (!fs.getFileStatus(di_test).isDir()) { throw new RuntimeException(tmpdir + File.separator + testdir + " is not a directory"); } FSDataInputStream fi_test = fs.open((fs.listStatus(di_test))[0].getPath()); boolean ignoreWhitespace = Shell.WINDOWS; if (!Utilities.contentsEqual(fi_gold, fi_test, ignoreWhitespace)) { LOG.error(di_test.toString() + " does not match " + datafile); assertEquals(false, true); } } private FilterDesc getTestFilterDesc(String column) { ArrayList<ExprNodeDesc> children1 = new ArrayList<ExprNodeDesc>(); children1.add(new ExprNodeColumnDesc(TypeInfoFactory.stringTypeInfo, column, "", false)); ExprNodeDesc lhs = new ExprNodeGenericFuncDesc( TypeInfoFactory.doubleTypeInfo, FunctionRegistry.getFunctionInfo( serdeConstants.DOUBLE_TYPE_NAME).getGenericUDF(), children1); ArrayList<ExprNodeDesc> children2 = new ArrayList<ExprNodeDesc>(); children2.add(new ExprNodeConstantDesc(TypeInfoFactory.longTypeInfo, Long .valueOf(100))); ExprNodeDesc rhs = new ExprNodeGenericFuncDesc( TypeInfoFactory.doubleTypeInfo, FunctionRegistry.getFunctionInfo( serdeConstants.DOUBLE_TYPE_NAME).getGenericUDF(), children2); ArrayList<ExprNodeDesc> children3 = new ArrayList<ExprNodeDesc>(); children3.add(lhs); children3.add(rhs); ExprNodeDesc desc = new ExprNodeGenericFuncDesc( TypeInfoFactory.booleanTypeInfo, FunctionRegistry.getFunctionInfo("<") .getGenericUDF(), children3); return new FilterDesc(desc, false); } @SuppressWarnings("unchecked") private void populateMapPlan1(Table src) { Operator<FileSinkDesc> op2 = OperatorFactory.get(new FileSinkDesc(new Path(tmpdir + File.separator + "mapplan1.out"), Utilities.defaultTd, true)); Operator<FilterDesc> op1 = OperatorFactory.get(getTestFilterDesc("key"), op2); addMapWork(mr, src, "a", op1); } @SuppressWarnings("unchecked") private void populateMapPlan2(Table src) { Operator<FileSinkDesc> op3 = OperatorFactory.get(new FileSinkDesc(new Path(tmpdir + File.separator + "mapplan2.out"), Utilities.defaultTd, false)); Operator<ScriptDesc> op2 = OperatorFactory.get(new ScriptDesc("cat", PlanUtils.getDefaultTableDesc("" + Utilities.tabCode, "key,value"), TextRecordWriter.class, PlanUtils.getDefaultTableDesc("" + Utilities.tabCode, "key,value"), TextRecordReader.class, TextRecordReader.class, PlanUtils.getDefaultTableDesc("" + Utilities.tabCode, "key")), op3); Operator<FilterDesc> op1 = OperatorFactory.get(getTestFilterDesc("key"), op2); addMapWork(mr, src, "a", op1); } @SuppressWarnings("unchecked") private void populateMapRedPlan1(Table src) throws SemanticException { ArrayList<String> outputColumns = new ArrayList<String>(); for (int i = 0; i < 2; i++) { outputColumns.add("_col" + i); } // map-side work Operator<ReduceSinkDesc> op1 = OperatorFactory.get(PlanUtils .getReduceSinkDesc(Utilities.makeList(getStringColumn("key")), Utilities.makeList(getStringColumn("value")), outputColumns, true, -1, 1, -1, AcidUtils.Operation.NOT_ACID)); addMapWork(mr, src, "a", op1); ReduceWork rWork = new ReduceWork(); rWork.setNumReduceTasks(Integer.valueOf(1)); rWork.setKeyDesc(op1.getConf().getKeySerializeInfo()); rWork.getTagToValueDesc().add(op1.getConf().getValueSerializeInfo()); mr.setReduceWork(rWork); // reduce side work Operator<FileSinkDesc> op3 = OperatorFactory.get(new FileSinkDesc(new Path(tmpdir + File.separator + "mapredplan1.out"), Utilities.defaultTd, false)); Operator<ExtractDesc> op2 = OperatorFactory.get(new ExtractDesc( getStringColumn(Utilities.ReduceField.VALUE.toString())), op3); rWork.setReducer(op2); } @SuppressWarnings("unchecked") private void populateMapRedPlan2(Table src) throws SemanticException { ArrayList<String> outputColumns = new ArrayList<String>(); for (int i = 0; i < 2; i++) { outputColumns.add("_col" + i); } // map-side work Operator<ReduceSinkDesc> op1 = OperatorFactory.get(PlanUtils .getReduceSinkDesc(Utilities.makeList(getStringColumn("key")), Utilities .makeList(getStringColumn("key"), getStringColumn("value")), outputColumns, false, -1, 1, -1, AcidUtils.Operation.NOT_ACID)); addMapWork(mr, src, "a", op1); ReduceWork rWork = new ReduceWork(); rWork.setNumReduceTasks(Integer.valueOf(1)); rWork.setKeyDesc(op1.getConf().getKeySerializeInfo()); rWork.getTagToValueDesc().add(op1.getConf().getValueSerializeInfo()); mr.setReduceWork(rWork); // reduce side work Operator<FileSinkDesc> op4 = OperatorFactory.get(new FileSinkDesc(new Path(tmpdir + File.separator + "mapredplan2.out"), Utilities.defaultTd, false)); Operator<FilterDesc> op3 = OperatorFactory.get(getTestFilterDesc("0"), op4); Operator<ExtractDesc> op2 = OperatorFactory.get(new ExtractDesc( getStringColumn(Utilities.ReduceField.VALUE.toString())), op3); rWork.setReducer(op2); } /** * test reduce with multiple tagged inputs. */ @SuppressWarnings("unchecked") private void populateMapRedPlan3(Table src, Table src2) throws SemanticException { List<String> outputColumns = new ArrayList<String>(); for (int i = 0; i < 2; i++) { outputColumns.add("_col" + i); } // map-side work Operator<ReduceSinkDesc> op1 = OperatorFactory.get(PlanUtils .getReduceSinkDesc(Utilities.makeList(getStringColumn("key")), Utilities.makeList(getStringColumn("value")), outputColumns, true, Byte.valueOf((byte) 0), 1, -1, AcidUtils.Operation.NOT_ACID)); addMapWork(mr, src, "a", op1); Operator<ReduceSinkDesc> op2 = OperatorFactory.get(PlanUtils .getReduceSinkDesc(Utilities.makeList(getStringColumn("key")), Utilities.makeList(getStringColumn("key")), outputColumns, true, Byte.valueOf((byte) 1), Integer.MAX_VALUE, -1, AcidUtils.Operation.NOT_ACID)); addMapWork(mr, src2, "b", op2); ReduceWork rWork = new ReduceWork(); rWork.setNumReduceTasks(Integer.valueOf(1)); rWork.setNeedsTagging(true); rWork.setKeyDesc(op1.getConf().getKeySerializeInfo()); rWork.getTagToValueDesc().add(op1.getConf().getValueSerializeInfo()); mr.setReduceWork(rWork); rWork.getTagToValueDesc().add(op2.getConf().getValueSerializeInfo()); // reduce side work Operator<FileSinkDesc> op4 = OperatorFactory.get(new FileSinkDesc(new Path(tmpdir + File.separator + "mapredplan3.out"), Utilities.defaultTd, false)); Operator<SelectDesc> op5 = OperatorFactory.get(new SelectDesc(Utilities .makeList(new ExprNodeFieldDesc(TypeInfoFactory.stringTypeInfo, new ExprNodeColumnDesc(TypeInfoFactory.getListTypeInfo(TypeInfoFactory.stringTypeInfo), Utilities.ReduceField.VALUE.toString(), "", false), "0", false)), Utilities.makeList(outputColumns.get(0))), op4); rWork.setReducer(op5); } @SuppressWarnings("unchecked") private void populateMapRedPlan4(Table src) throws SemanticException { // map-side work ArrayList<String> outputColumns = new ArrayList<String>(); for (int i = 0; i < 2; i++) { outputColumns.add("_col" + i); } Operator<ReduceSinkDesc> op1 = OperatorFactory.get(PlanUtils .getReduceSinkDesc(Utilities.makeList(getStringColumn("tkey")), Utilities.makeList(getStringColumn("tkey"), getStringColumn("tvalue")), outputColumns, false, -1, 1, -1, AcidUtils.Operation.NOT_ACID)); Operator<ScriptDesc> op0 = OperatorFactory.get(new ScriptDesc("cat", PlanUtils.getDefaultTableDesc("" + Utilities.tabCode, "key,value"), TextRecordWriter.class, PlanUtils.getDefaultTableDesc("" + Utilities.tabCode, "tkey,tvalue"), TextRecordReader.class, TextRecordReader.class, PlanUtils.getDefaultTableDesc("" + Utilities.tabCode, "key")), op1); Operator<SelectDesc> op4 = OperatorFactory.get(new SelectDesc(Utilities .makeList(getStringColumn("key"), getStringColumn("value")), outputColumns), op0); addMapWork(mr, src, "a", op4); ReduceWork rWork = new ReduceWork(); rWork.setKeyDesc(op1.getConf().getKeySerializeInfo()); rWork.getTagToValueDesc().add(op1.getConf().getValueSerializeInfo()); rWork.setNumReduceTasks(Integer.valueOf(1)); mr.setReduceWork(rWork); // reduce side work Operator<FileSinkDesc> op3 = OperatorFactory.get(new FileSinkDesc(new Path(tmpdir + File.separator + "mapredplan4.out"), Utilities.defaultTd, false)); Operator<ExtractDesc> op2 = OperatorFactory.get(new ExtractDesc( getStringColumn(Utilities.ReduceField.VALUE.toString())), op3); rWork.setReducer(op2); } public static ExprNodeColumnDesc getStringColumn(String columnName) { return new ExprNodeColumnDesc(TypeInfoFactory.stringTypeInfo, columnName, "", false); } @SuppressWarnings("unchecked") private void populateMapRedPlan5(Table src) throws SemanticException { // map-side work ArrayList<String> outputColumns = new ArrayList<String>(); for (int i = 0; i < 2; i++) { outputColumns.add("_col" + i); } Operator<ReduceSinkDesc> op0 = OperatorFactory.get(PlanUtils .getReduceSinkDesc(Utilities.makeList(getStringColumn("0")), Utilities .makeList(getStringColumn("0"), getStringColumn("1")), outputColumns, false, -1, 1, -1, AcidUtils.Operation.NOT_ACID)); Operator<SelectDesc> op4 = OperatorFactory.get(new SelectDesc(Utilities .makeList(getStringColumn("key"), getStringColumn("value")), outputColumns), op0); addMapWork(mr, src, "a", op4); ReduceWork rWork = new ReduceWork(); mr.setReduceWork(rWork); rWork.setNumReduceTasks(Integer.valueOf(1)); rWork.setKeyDesc(op0.getConf().getKeySerializeInfo()); rWork.getTagToValueDesc().add(op0.getConf().getValueSerializeInfo()); // reduce side work Operator<FileSinkDesc> op3 = OperatorFactory.get(new FileSinkDesc(new Path(tmpdir + File.separator + "mapredplan5.out"), Utilities.defaultTd, false)); Operator<ExtractDesc> op2 = OperatorFactory.get(new ExtractDesc( getStringColumn(Utilities.ReduceField.VALUE.toString())), op3); rWork.setReducer(op2); } @SuppressWarnings("unchecked") private void populateMapRedPlan6(Table src) throws SemanticException { // map-side work ArrayList<String> outputColumns = new ArrayList<String>(); for (int i = 0; i < 2; i++) { outputColumns.add("_col" + i); } Operator<ReduceSinkDesc> op1 = OperatorFactory.get(PlanUtils .getReduceSinkDesc(Utilities.makeList(getStringColumn("tkey")), Utilities.makeList(getStringColumn("tkey"), getStringColumn("tvalue")), outputColumns, false, -1, 1, -1, AcidUtils.Operation.NOT_ACID)); Operator<ScriptDesc> op0 = OperatorFactory.get(new ScriptDesc( "\'cat\'", PlanUtils.getDefaultTableDesc("" + Utilities.tabCode, "tkey,tvalue"), TextRecordWriter.class, PlanUtils .getDefaultTableDesc("" + Utilities.tabCode, "tkey,tvalue"), TextRecordReader.class, TextRecordReader.class, PlanUtils.getDefaultTableDesc("" + Utilities.tabCode, "key")), op1); Operator<SelectDesc> op4 = OperatorFactory.get(new SelectDesc(Utilities .makeList(getStringColumn("key"), getStringColumn("value")), outputColumns), op0); addMapWork(mr, src, "a", op4); ReduceWork rWork = new ReduceWork(); mr.setReduceWork(rWork); rWork.setNumReduceTasks(Integer.valueOf(1)); rWork.setKeyDesc(op1.getConf().getKeySerializeInfo()); rWork.getTagToValueDesc().add(op1.getConf().getValueSerializeInfo()); // reduce side work Operator<FileSinkDesc> op3 = OperatorFactory.get(new FileSinkDesc(new Path(tmpdir + File.separator + "mapredplan6.out"), Utilities.defaultTd, false)); Operator<FilterDesc> op2 = OperatorFactory.get(getTestFilterDesc("0"), op3); Operator<ExtractDesc> op5 = OperatorFactory.get(new ExtractDesc( getStringColumn(Utilities.ReduceField.VALUE.toString())), op2); rWork.setReducer(op5); } private void executePlan() throws Exception { String testName = new Exception().getStackTrace()[1].getMethodName(); MapRedTask mrtask = new MapRedTask(); DriverContext dctx = new DriverContext (); mrtask.setWork(mr); mrtask.initialize(conf, null, dctx); int exitVal = mrtask.execute(dctx); if (exitVal != 0) { LOG.error(testName + " execution failed with exit status: " + exitVal); assertEquals(true, false); } LOG.info(testName + " execution completed successfully"); } public void testMapPlan1() throws Exception { LOG.info("Beginning testMapPlan1"); populateMapPlan1(db.getTable(MetaStoreUtils.DEFAULT_DATABASE_NAME, "src")); executePlan(); fileDiff("lt100.txt.deflate", "mapplan1.out"); } public void testMapPlan2() throws Exception { LOG.info("Beginning testMapPlan2"); populateMapPlan2(db.getTable(MetaStoreUtils.DEFAULT_DATABASE_NAME, "src")); executePlan(); fileDiff("lt100.txt", "mapplan2.out"); } public void testMapRedPlan1() throws Exception { LOG.info("Beginning testMapRedPlan1"); populateMapRedPlan1(db.getTable(MetaStoreUtils.DEFAULT_DATABASE_NAME, "src")); executePlan(); fileDiff("kv1.val.sorted.txt", "mapredplan1.out"); } public void testMapRedPlan2() throws Exception { LOG.info("Beginning testMapPlan2"); populateMapRedPlan2(db.getTable(MetaStoreUtils.DEFAULT_DATABASE_NAME, "src")); executePlan(); fileDiff("lt100.sorted.txt", "mapredplan2.out"); } public void testMapRedPlan3() throws Exception { LOG.info("Beginning testMapPlan3"); populateMapRedPlan3(db.getTable(MetaStoreUtils.DEFAULT_DATABASE_NAME, "src"), db.getTable(MetaStoreUtils.DEFAULT_DATABASE_NAME, "src2")); executePlan(); fileDiff("kv1kv2.cogroup.txt", "mapredplan3.out"); } public void testMapRedPlan4() throws Exception { LOG.info("Beginning testMapPlan4"); populateMapRedPlan4(db.getTable(MetaStoreUtils.DEFAULT_DATABASE_NAME, "src")); executePlan(); fileDiff("kv1.string-sorted.txt", "mapredplan4.out"); } public void testMapRedPlan5() throws Exception { LOG.info("Beginning testMapPlan5"); populateMapRedPlan5(db.getTable(MetaStoreUtils.DEFAULT_DATABASE_NAME, "src")); executePlan(); fileDiff("kv1.string-sorted.txt", "mapredplan5.out"); } public void testMapRedPlan6() throws Exception { LOG.info("Beginning testMapPlan6"); populateMapRedPlan6(db.getTable(MetaStoreUtils.DEFAULT_DATABASE_NAME, "src")); executePlan(); fileDiff("lt100.sorted.txt", "mapredplan6.out"); } }
[ "yangchuanpeng@iee.ac.cn" ]
yangchuanpeng@iee.ac.cn
05bf8195b2f994d4a1fbc990cfc45ab5e6e547a7
28f0e554f3412e88a00ad418181bb5df9e7c8010
/src/main/java/adeo/leroymerlin/cdp/EventController.java
2ba1d3fa0223be460d878cebd64773112b8cf994
[]
no_license
rratefiarivony/tests-technique
203bd0835c5ae5dad58a2bfe23b5b6c61d8b2dd9
465fc61d333568cce139f5db4374451ed1579d30
refs/heads/main
2023-08-16T09:33:59.176546
2021-09-22T08:58:12
2021-09-22T08:58:12
409,132,027
1
0
null
null
null
null
UTF-8
Java
false
false
1,119
java
package adeo.leroymerlin.cdp; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.web.bind.annotation.*; import java.util.List; @RestController @RequestMapping("/api/events") public class EventController { private final EventService eventService; @Autowired public EventController(EventService eventService) { this.eventService = eventService; } @RequestMapping(value = "/", method = RequestMethod.GET) public List<Event> findEvents() { return eventService.getEvents(); } @RequestMapping(value = "/search/{query}", method = RequestMethod.GET) public List<Event> findEvents(@PathVariable String query) { return eventService.getFilteredEvents(query); } @RequestMapping(value = "/{id}", method = RequestMethod.DELETE) public void deleteEvent(@PathVariable Long id) { eventService.delete(id); } @RequestMapping(value = "/{id}", method = RequestMethod.PUT) public void updateEvent(@PathVariable Long id, @RequestBody Event event) { eventService.updateEvent(id, event); } }
[ "rratefiarivony@ineat.fr" ]
rratefiarivony@ineat.fr
640f134706b1a88e9c28945862e22e161681311c
f5505bcc49701e3ffa31ffa2ec0314d76853b171
/CS1010J/ps2ex21/skeleton/PS2_Ex21_Legendre.java
7152bcf9472e0ac0d825eef2101b7d2c34138e35
[]
no_license
ArcBri/Java-Coursework
4ef36a7c5757b3d1a7d91e1bda8fe2fd792a33e4
251222f3d54f5a73a55e2eca8868c51eb800345b
refs/heads/master
2020-05-03T08:48:14.242682
2019-04-01T11:17:02
2019-04-01T11:17:02
178,536,686
0
0
null
null
null
null
UTF-8
Java
false
false
1,387
java
/* * CS1010J Programming Methodology * Problem Set 2 Exercise #21: PS2_Ex21_Legendre.java * * <Programme to verify Legendre conjecture> * * * <Arcillas Brian Joshua Pelaez> */ import java.util.*; class Legendre { public static void main(String[] args) { Scanner sc= new Scanner(System.in); System.out.print("Enter n: "); int n=sc.nextInt(); if(testConjecture(n)==true){ System.out.println("true"); } } // Verify if there is at least one prime number in // each range (1^2 to 2^2), (2^2 to 3^2), (n^2 to (n+1)^2) public static boolean testConjecture(int n) { for(int p=1; p<=n; p++){ if(hasPrime((p*p),((p+1)*(p+1)))){ return true; } } return false; // stub, to be replaced by your code } // Check whether there is any prime in range [low, high], // return true if so, or false otherwise public static boolean hasPrime(int low, int high) { while(low<=high){ if(isPrime(low)){ return true; } low++; } return false; // stub, to be replaced by your code } // <Write a short description of the method here> public static boolean isPrime(int num) { for(int factor=2; factor<=num/2; factor++){ if(num%factor==0){ return false; }// stub, to be replaced by your code } return true; } }
[ "Brian" ]
Brian
e2f8f11fb3e5a1ab3a4efffbc2015d1c5a01ee79
1ba2f238e91e5ed786c17088e5c375d4665ad1ff
/ding-impl/ding-presentation-impl/src/main/java/org/cytoscape/ding/internal/gradients/radial/RadialGradientEditor.java
f4c01e81a8a11ab7cb8505254f5ab2f48994fe69
[]
no_license
ahmedmekkawy/cytoscape-impl
22b430151d679b2f1ab6eabfcb02e03ed3719672
ebe264fe19c32e6dfe0195912ffb607081018f2b
refs/heads/master
2021-01-18T16:56:23.654175
2015-01-28T23:36:59
2015-02-09T23:30:10
null
0
0
null
null
null
null
UTF-8
Java
false
false
2,303
java
package org.cytoscape.ding.internal.gradients.radial; import static org.cytoscape.ding.internal.gradients.radial.RadialGradient.CENTER; import java.awt.geom.Point2D; import java.beans.PropertyChangeEvent; import java.beans.PropertyChangeListener; import javax.swing.GroupLayout; import javax.swing.GroupLayout.Alignment; import javax.swing.JLabel; import javax.swing.JPanel; import org.cytoscape.ding.internal.gradients.AbstractGradientEditor; import org.cytoscape.ding.internal.util.PointPicker; public class RadialGradientEditor extends AbstractGradientEditor<RadialGradient> { private static final long serialVersionUID = 5997072753907737888L; private JLabel centerLbl; private PointPicker pointPicker; // ==[ CONSTRUCTORS ]=============================================================================================== public RadialGradientEditor(final RadialGradient gradient) { super(gradient); } // ==[ PRIVATE METHODS ]============================================================================================ @Override protected void createLabels() { super.createLabels(); centerLbl = new JLabel("Center"); } @Override protected JPanel getOtherOptionsPnl() { final JPanel p = super.getOtherOptionsPnl(); p.setVisible(true); final GroupLayout layout = new GroupLayout(p); p.setLayout(layout); layout.setAutoCreateContainerGaps(false); layout.setHorizontalGroup(layout.createParallelGroup(Alignment.LEADING, true) .addComponent(centerLbl) .addComponent(getPointPicker(), GroupLayout.PREFERRED_SIZE, GroupLayout.DEFAULT_SIZE, GroupLayout.PREFERRED_SIZE) ); layout.setVerticalGroup(layout.createSequentialGroup() .addComponent(centerLbl) .addComponent(getPointPicker()) ); return p; } private PointPicker getPointPicker() { if (pointPicker == null) { final Point2D center = gradient.get(CENTER, Point2D.class, new Point2D.Double(0.5, 0.5)); pointPicker = new PointPicker(100, 12, center); pointPicker.addPropertyChangeListener("value", new PropertyChangeListener() { @Override public void propertyChange(PropertyChangeEvent e) { final Point2D newCenter = (Point2D) e.getNewValue(); gradient.set(CENTER, newCenter); } }); } return pointPicker; } }
[ "chrtannus@gmail.com" ]
chrtannus@gmail.com
d55a722e7ce96a885819f81be5e74bacbb130d27
a666cca05f2c0fbc1967505ccf41817f56efc034
/app/src/androidTest/java/com/cl/peopledetailscl6/ExampleInstrumentedTest.java
a6e24736e611f11136e3c9e39d7fa209e93b7123
[]
no_license
lalitwdhw/PepleDetailsCL6
e6c568bfba460402b751533b48a65349211fe153
08aac7e5495dcde77993c1313ec372e783790d91
refs/heads/master
2020-05-02T22:19:31.211062
2019-04-15T14:56:52
2019-04-15T14:56:52
178,248,598
0
0
null
null
null
null
UTF-8
Java
false
false
730
java
package com.cl.peopledetailscl6; import android.content.Context; import android.support.test.InstrumentationRegistry; import android.support.test.runner.AndroidJUnit4; import org.junit.Test; import org.junit.runner.RunWith; import static org.junit.Assert.*; /** * Instrumented test, which will execute on an Android device. * * @see <a href="http://d.android.com/tools/testing">Testing documentation</a> */ @RunWith(AndroidJUnit4.class) public class ExampleInstrumentedTest { @Test public void useAppContext() { // Context of the app under test. Context appContext = InstrumentationRegistry.getTargetContext(); assertEquals("com.cl.peopledetailscl6", appContext.getPackageName()); } }
[ "lalit.mohan@jungleworks.com" ]
lalit.mohan@jungleworks.com
8d1d2cb2759b070963e5ffaca1750733ca31bcc6
619f22149af820b0368981131b76d66fecefa648
/UVa/Q1213.java
e909bb508496dfe71d45085cd992674d91f7ec2e
[]
no_license
prathamtandon/competitive-programming
bd6a12c06c972dd3748f8ef0480322660ca22b7a
618405c78f06739ef1f2684080412f7038e74496
refs/heads/master
2021-01-23T06:05:37.930079
2017-11-02T18:16:50
2017-11-02T18:16:50
86,336,093
1
0
null
null
null
null
UTF-8
Java
false
false
2,063
java
import java.io.BufferedReader; import java.io.IOException; import java.io.InputStreamReader; import java.util.ArrayList; import java.util.Arrays; import java.util.StringTokenizer; class Q1213 { private static ArrayList<Integer> primes = new ArrayList<>(); private static void generatePrimes() { boolean[] visited = new boolean[1121]; Arrays.fill(visited, true); for (int i = 2; i*i <= 1120 ; i++) { if(!visited[i]) continue; for (int j = 2*i; j <= 1120 ; j+=i) { visited[j] = false; } } primes.add(0); for (int i = 2; i < 1121; i++) { if(visited[i]) primes.add(i); } } public static void main(String[] args) throws IOException { generatePrimes(); BufferedReader reader = new BufferedReader(new InputStreamReader(System.in)); int[][][] table = new int[1125][20][primes.size()+10]; while(true) { StringTokenizer tokenizer = new StringTokenizer(reader.readLine()); int n = Integer.parseInt(tokenizer.nextToken()); int k = Integer.parseInt(tokenizer.nextToken()); if(n == 0 && k == 0) break; for (int i = 0; i <= n; i++) { for (int j = 0; j <= k; j++) { for (int l = 1; l < primes.size(); l++) { table[i][j][l] = 0; } } } for (int i = 0; i < primes.size(); i++) { table[0][0][i] = 1; } for (int i = 1; i <= n; i++) { for (int j = 1; j <= k; j++) { for (int l = 1; l < primes.size(); l++) { table[i][j][l] = table[i][j][l-1]; if(primes.get(l) <= i) table[i][j][l] += table[i-primes.get(l)][j-1][l-1]; } } } System.out.println(table[n][k][primes.size()-1]); } } }
[ "prathamt@outlook.com" ]
prathamt@outlook.com
6ff286c87f080558d18f4cbeae82685e0fcc6b91
b84da6a24f402f5d1de520fa621344862793490b
/src/capgemini/firstproject/welcome/Lab1_Ex2.java
44bf754301bfcab780db528e9e4dd82b7e2f8af2
[]
no_license
siddharthvrma/Capgemini-Training
36a91c1b7b7fd5caa08bb844a5cd466a5951373a
bf6dea392d1f4f34fe8db94808c5b266ef481383
refs/heads/master
2021-01-02T17:27:36.465457
2020-02-11T09:35:10
2020-02-11T09:35:10
239,722,009
0
0
null
null
null
null
UTF-8
Java
false
false
506
java
package capgemini.firstproject.welcome; public class Lab1_Ex2 { int natural_number=100; public static void main(String[] args) { Lab1_Ex2 mObject = new Lab1_Ex2(); System.out.println("Diff b/w the sum of sq of first n natural no and the sq of their sum is "+mObject.calculateDifference(mObject.natural_number)); } public int calculateDifference(int n) { int sum=0, sum1 =0,sum2=0; for(int i=0;i<=n;i++) { sum1=sum1+i; sum2=sum2+(i*i); } sum=sum2-(sum1*sum1); return sum; } }
[ "sidverma1199@gmail.com" ]
sidverma1199@gmail.com
0384b7c989e891ffa6f6e9e1e669b789a1cad25d
47e9deb15406d88278cdebf841552baf7a8623e4
/src/main/java/com/fartecx/utils/FartecxError.java
af7b84f7931f56ace8756f37d4ecca2464cd9c47
[]
no_license
linghuchong33433/idrg
adabcc13ef796aa3c3dab4c8d017e66a8d51d4ba
83c1dbed76df318e913eadd15561b6652b3e1c74
refs/heads/master
2020-04-10T20:22:09.535266
2018-12-13T03:40:33
2018-12-13T03:40:33
161,265,358
0
0
null
null
null
null
UTF-8
Java
false
false
2,579
java
package com.fartecx.utils; import org.apache.shiro.authc.IncorrectCredentialsException; import org.apache.shiro.authc.UnknownAccountException; import javax.servlet.http.HttpServletRequest; /** * ======================== * Created with IntelliJ IDEA * Author:Mr.Su * Date:2018/11/22 * Time:13:41 * ======================== */ public class FartecxError { public static final int CODE_OK = 0; public static final int CODE_OTHER = 1; public static final int CODE_INVALID_PARAM = 2; public static final int CODE_NEED_VERIFYCODE = 3; public static final int CODE_ALREADY_EXIST = 4; public static final String[] ERROR_MESSAGES = {"", "其他错误", "", "请输入验证码", "已存在" }; public Integer error; public String message; public Object obj; public FartecxError() { this.error = CODE_OK; this.message = ""; } public FartecxError(int code, String message) { this.error = code; this.message = message; } @Override public String toString() { return "FartecxError{" + "error=" + error + ", message=" + message + ", obj=" + obj.toString() + "}"; } public boolean hasError() { return this.error != CODE_OK; } static public FartecxError fromRequest(HttpServletRequest request) { if (null == request) { return new FartecxError(); } String exceptionClassName = (String)request.getAttribute("shiroLoginFailure"); if(UnknownAccountException.class.getName().equals(exceptionClassName)) { return new FartecxError(CODE_INVALID_PARAM, "无效的用户名/密码"); } else if(IncorrectCredentialsException.class.getName().equals(exceptionClassName)) { return new FartecxError(CODE_INVALID_PARAM, "无效的用户名/密码"); } else if("postVerify.error".equals(exceptionClassName)) { return new FartecxError(CODE_NEED_VERIFYCODE, "验证码错误"); } else if(exceptionClassName != null) { return new FartecxError(CODE_OTHER, ERROR_MESSAGES[CODE_OTHER]); } Object verify = request.getAttribute("needVerifyCode"); if(null != verify) { boolean needVerifyCode = (boolean)verify; if (needVerifyCode) { return new FartecxError(CODE_NEED_VERIFYCODE, ERROR_MESSAGES[CODE_NEED_VERIFYCODE]); } } return new FartecxError(); } }
[ "1240898751@qq.com" ]
1240898751@qq.com
726f7c4bec8d9dc22eb62d05c1826f388296e436
aec658c7e4871245298242a1a5c6a7d2f8e8c6c7
/app/controllers/UserController.java
e5ef40c43ee451e2645b1481a12b9b728dc32898
[]
no_license
liammagee/cos2
a5e6196fd3410aba778967ee2361c7a5f661b5f0
15df4858dcf3272659e2053a87caea0f10b49cb3
refs/heads/master
2020-12-07T17:10:36.394924
2014-03-03T21:08:16
2014-03-03T21:08:16
14,879,117
0
0
null
null
null
null
UTF-8
Java
false
false
2,162
java
package controllers; import models.*; import play.mvc.Result; import play.*; import play.data.Form; import play.mvc.*; import init.BasicInit; import views.html.*; import views.html.index; /** * Created with IntelliJ IDEA. * User: liam * Date: 15/11/2013 * Time: 5:06 PM * To change this template use File | Settings | File Templates. */ public class UserController extends Controller { static Form<User> userForm = Form.form(User.class); public static Result showRegister() { return ok( views.html.users.register.render(userForm) ); } public static Result register() { Form<User> filledForm = userForm.bindFromRequest(); if(filledForm.hasErrors()) { return badRequest( views.html.users.register.render(filledForm) ); } else { User user = filledForm.get(); User.create(user); session("username", user.getUsername()); // Create the default project - TODO: make this configurable BasicInit.addTehranAirPollutionProject(BasicInit.getEntityManager(), user); return redirect(routes.ProjectController.projects()); } } public static Result login() { Form<User> filledForm = userForm.bindFromRequest(); // Authenticate User user = User.authenticate(filledForm.get()); if(user == null) { flash("error", "Sorry, " + filledForm.get().getUsername() + ", you'll need to try logging in again."); return unauthorized( views.html.index.render(filledForm) ); } else { session("username", user.getUsername()); flash("success", "Welcome " + user.getUsername() + "!"); return redirect(routes.ProjectController.projects()); } } public static Result logout() { session().remove("username"); flash("success", "You have been successfully logged out. "); return redirect(routes.Application.index()); } public static String getLoggedInUsername() { return session("username"); } }
[ "liam.magee@gmail.com" ]
liam.magee@gmail.com
6e08b872886f7c70b0f5eceeefedaaa9457b569e
4434a4c0fc0de1943fac6b67d21c0a902f884948
/src/main/java/qa/automation/page/screen/HomePage.java
cde475a1bb6ad885028904ddd18abc56024dabca
[]
no_license
munnakr643/oct
c446c8eea7e995b2bdaff945f3d5891ff886efc8
f579180b99e7d6abfa907c0f6429604df8b4f8d5
refs/heads/master
2023-02-18T18:42:32.873467
2021-01-06T13:07:52
2021-01-06T13:07:52
305,895,074
0
0
null
2021-01-07T14:44:02
2020-10-21T03:13:11
HTML
UTF-8
Java
false
false
9,143
java
package qa.automation.page.screen; import io.appium.java_client.AppiumDriver; import io.appium.java_client.MobileElement; import io.appium.java_client.pagefactory.AndroidFindBy; import qa.automation.page.screen.manager.ScreenManager; public class HomePage extends ScreenManager { @Override protected String getTitle() { // TODO Auto-generated method stub return null; } public HomePage(AppiumDriver<MobileElement> driver) { super(driver); } @AndroidFindBy(xpath="//android.view.View[@content-desc='Mobiles']") public MobileElement Mobiles; @AndroidFindBy(xpath="//android.view.View[@content-desc='Electronics']") public MobileElement Electronics; @AndroidFindBy(xpath="//android.view.View[@content-desc='Home']") public MobileElement Home; @AndroidFindBy(xpath="//android.view.View[@content-desc='Mobiles']") public MobileElement Appliances; @AndroidFindBy(xpath="//android.view.View[@content-desc='Fashion']") public MobileElement Fashion; @AndroidFindBy(xpath="//android.widget.Button[@text='Select delivery location']") public MobileElement SelectLocation; @AndroidFindBy(xpath="//android.widget.TextView[@text='Search for apps and content']") public MobileElement search; @AndroidFindBy(xpath="//android.widget.EditText[@text='Search for apps and content']") public MobileElement searchAppInput; @AndroidFindBy(xpath="//android.widget.TextView[@text='Profile']") public MobileElement Profile; @AndroidFindBy(xpath="//android.widget.TextView[@text='Quote']") public MobileElement quote; @AndroidFindBy(xpath="//android.widget.Button[@text='Suggest Plans']") public MobileElement suggestPlans; @AndroidFindBy(xpath="//android.widget.RadioButton[@text='Car Insurance']") public MobileElement selectCarIns; @AndroidFindBy(xpath="//android.widget.EditText[@text='Customer Name (Optional)']") public MobileElement customerName; @AndroidFindBy(xpath="//android.widget.Button[@text='Next']") public MobileElement next; @AndroidFindBy(xpath="//android.widget.TextView[@text='HONDA']") public MobileElement selectHonda; @AndroidFindBy(xpath="//android.widget.TextView[@text='City']") public MobileElement selectCityCar; @AndroidFindBy(xpath="//android.widget.RadioButton[@text='Petrol']") public MobileElement selectPetrol; @AndroidFindBy(xpath="//android.widget.TextView[@text='Mumbai']") public MobileElement selectCityName; @AndroidFindBy(xpath="//android.widget.RadioButton[@text='1.3 EXI (1343 CC)']") public MobileElement selectExi; @AndroidFindBy(xpath="//android.widget.TextView[contains(@text,'MH01')]") public MobileElement selectMh01; @AndroidFindBy(xpath="//android.widget.EditText[@text='DD/MM/YYYY']") public MobileElement selectDate; @AndroidFindBy(xpath="//android.widget.RadioButton[@text='Not expired Yet']") public MobileElement selectExpiry; @AndroidFindBy(xpath="//android.widget.CompoundButton[@text='35%']") public MobileElement selectNcb35; @AndroidFindBy(xpath="//android.widget.RadioButton[@text='1 yr Comprehensive/ Standard Policy']") public MobileElement selectComprehensive; @AndroidFindBy(xpath="//android.widget.TextView[@text='Save this quote as Lead']") public MobileElement quoteSave; @AndroidFindBy(xpath="//android.widget.TextView[@text='HDFC ERGO General']") public MobileElement hdfcErgo; @AndroidFindBy(xpath="//android.widget.Button[@text='Generate Quote']") public MobileElement generalQuote; @AndroidFindBy(xpath="//android.widget.Button[@text='Buy Now']") public MobileElement buyNow; @AndroidFindBy(xpath="//android.widget.Button[@text='View Details']") public MobileElement viewDetails; @AndroidFindBy(xpath="//android.widget.RadioButton[@text='Mr.']") public MobileElement selectMr; @AndroidFindBy(xpath="//android.widget.EditText[@text='First Name']") public MobileElement firName; @AndroidFindBy(xpath="//android.widget.EditText[@text='Middle Name']") public MobileElement midName; @AndroidFindBy(xpath="//android.widget.EditText[@text='Last Name']") public MobileElement lastName; @AndroidFindBy(xpath="//android.widget.EditText[@text='Date Of Birth']") public MobileElement dateOfBirth; @AndroidFindBy(xpath="//android.widget.EditText[@text='Email']") public MobileElement email; @AndroidFindBy(xpath="//android.widget.EditText[@text='Phone']") public MobileElement phone; @AndroidFindBy(xpath="//android.widget.RadioButton[@text='Male']") public MobileElement selectMale; @AndroidFindBy(xpath="//android.widget.RadioButton[@text='Single']") public MobileElement selectSingle; @AndroidFindBy(xpath="//android.widget.EditText[@text='Address Line 1']") public MobileElement addressLine1; @AndroidFindBy(xpath="//android.widget.EditText[@text='Address Line 2']") public MobileElement addressLine2; @AndroidFindBy(xpath="//android.widget.EditText[@text='Address Line 3']") public MobileElement addressLine3; @AndroidFindBy(xpath="//android.widget.EditText[@text='Pincode']") public MobileElement pincode; @AndroidFindBy(xpath="//android.widget.Spinner[contains(@resource-id,'actv_value')]") public MobileElement selectState; @AndroidFindBy(xpath="(//android.widget.Spinner[contains(@resource-id,'actv_value')])[2]") public MobileElement selectCityforAddress; @AndroidFindBy(xpath="(//android.widget.Spinner[contains(@resource-id,'actv_value')])[3]") public MobileElement selectDistric; @AndroidFindBy(xpath="(//android.widget.Spinner[contains(@resource-id,'actv_value')])[4]") public MobileElement selectCountry; @AndroidFindBy(xpath="//android.widget.CheckBox[@text='Same as Communication Address']") public MobileElement sameAsCAdd1; @AndroidFindBy(xpath="//android.widget.CheckBox[contains(@text,'Same as')]") public MobileElement sameAsCAdd2; @AndroidFindBy(xpath="//android.widget.TextView[@text='Permanent Address']") public MobileElement permanentAddress; @AndroidFindBy(xpath="//android.widget.TextView[@text='Registration Address']") public MobileElement registrationAddress; @AndroidFindBy(xpath="//android.widget.TextView[@text='City Name']") public MobileElement cityName; @AndroidFindBy(xpath="//android.widget.TextView[@text='District Name']") public MobileElement distric; @AndroidFindBy(xpath="//android.widget.TextView[@text='Country Name']") public MobileElement countyName; @AndroidFindBy(xpath="//android.widget.EditText[@text='Name']") public MobileElement nomineeName; @AndroidFindBy(xpath="//android.widget.EditText[@text='Address']") public MobileElement nomineeAddress; @AndroidFindBy(xpath="//android.widget.Spinner[contains(@resource-id,'actv_value')]") public MobileElement nomineeRelation; @AndroidFindBy(xpath="//android.widget.EditText[contains(@text,'License Plate Number')]") public MobileElement licensePlateNum; @AndroidFindBy(xpath="//android.widget.EditText[@text='Manufacturing Date']") public MobileElement ManfuctDate; @AndroidFindBy(xpath="//android.widget.EditText[@text='Chassis Number']") public MobileElement chassisNumber; @AndroidFindBy(xpath="//android.widget.EditText[@text='Engine Number']") public MobileElement engineNumber; @AndroidFindBy(xpath="//android.widget.Button[@text='Review & Submit']") public MobileElement reviewSubmit; @AndroidFindBy(xpath="//android.widget.ImageButton[contains(@resource-id,'text_input_end_icon')]") public MobileElement clickOnCalenderLogo; @AndroidFindBy(xpath="//android.widget.Button[@content-desc='Change to previous month']") public MobileElement prevMonth; @AndroidFindBy(xpath="//android.widget.Button[@content-desc='Change to next month']") public MobileElement nextMonth; @AndroidFindBy(xpath="//android.widget.Button[contains(@resource-id,'month_navigation_fragment_toggle')]") public MobileElement selectYear; @AndroidFindBy(xpath="//android.widget.ImageButton[@content-desc='Switch to text input mode']") public MobileElement switchInputDate; @AndroidFindBy(xpath="//android.widget.TextView[@text='Date']") public MobileElement enterDate; @AndroidFindBy(xpath="//android.widget.TextView[@text='16']") public MobileElement date16; @AndroidFindBy(xpath="//android.widget.Button[@text='OK']") public MobileElement clickOk; @AndroidFindBy(xpath="//android.widget.Spinner[contains(@resource-id,'actv_value')]") public MobileElement actv_valueDropdown; @AndroidFindBy(xpath="//android.widget.RadioButton[@text='Yes']") public MobileElement yes; @AndroidFindBy(xpath="//android.widget.RadioButton[@text='No']") public MobileElement no; @AndroidFindBy(xpath="//android.widget.TextView[@text='Policy Expiry Date']") public MobileElement policyExpiryDate; @AndroidFindBy(xpath="//android.widget.EditText[@text='Previous Policy Number']") public MobileElement prevPolicyNum; @AndroidFindBy(xpath="(//android.widget.ImageButton[contains(@resource-id,'text_input_end_icon')])[2]") public MobileElement policyExDate; }
[ "kumarmunna643@gmail.com" ]
kumarmunna643@gmail.com
92f25b41037bba566becdf25079f4bb9458d79f7
b923d8dec7ae521891b17e40691194d935f058af
/csx42-s19-assign4-ksaini1-master/kulraj_saini_assign4/multiThreadedHS/src/multiThreadedHS/util/StdoutDisplayInterface.java
bcf51bdfb0c6d38992392fd26008b163e8d8f229
[]
no_license
ksaini1/DesignPattern
a1a79888629aabe113c93b200991a2a44ca39105
11e566a49d7bab5d917ccd617040bf90f572cdc1
refs/heads/master
2022-08-29T15:39:32.619747
2020-05-22T00:36:53
2020-05-22T00:36:53
265,982,242
0
0
null
null
null
null
UTF-8
Java
false
false
112
java
package multiThreadedHS.util; public interface StdoutDisplayInterface { public void writeToStdout(String s); }
[ "noreply@github.com" ]
ksaini1.noreply@github.com
59300780353ea0a89c5ade9416b4ea0c889f27f9
881c5f3a69329bf68a5aa0d8120432a466a45e2c
/spring-boot-kafka-sample/src/main/java/com/flexy/kafka/jsonstore/KafkaJsonStoreConfig.java
976a7cbf392a28627544d625a4a014c8c5a974ed
[]
no_license
arunvelusamyd/maximums-samples-v2
6ffca48972c997c281f05e25109d06526d31407a
8a0c55c726a411631b7b7c53c0bd98182106e8d8
refs/heads/main
2023-04-02T15:01:11.869929
2021-04-16T02:49:08
2021-04-16T02:49:08
358,275,351
0
0
null
null
null
null
UTF-8
Java
false
false
2,810
java
package com.flexy.kafka.jsonstore; import org.apache.kafka.clients.admin.NewTopic; import org.apache.kafka.clients.consumer.ConsumerConfig; import org.apache.kafka.clients.producer.ProducerConfig; import org.apache.kafka.common.serialization.StringDeserializer; import org.apache.kafka.common.serialization.StringSerializer; import org.springframework.beans.factory.annotation.Value; import org.springframework.context.annotation.Bean; import org.springframework.context.annotation.Configuration; import org.springframework.kafka.annotation.EnableKafka; import org.springframework.kafka.config.ConcurrentKafkaListenerContainerFactory; import org.springframework.kafka.core.*; import org.springframework.kafka.support.serializer.JsonDeserializer; import org.springframework.kafka.support.serializer.JsonSerializer; import java.util.HashMap; import java.util.Map; @EnableKafka @Configuration public class KafkaJsonStoreConfig { @Value(value = "${kafka.bootstrapAddress}") private String bootstrapAddress; @Value(value = "${topic.name.product}") private String productTopicName; public ConsumerFactory<String, Product> productConsumerFactory() { Map<String, Object> props = new HashMap<>(); props.put(ConsumerConfig.BOOTSTRAP_SERVERS_CONFIG, bootstrapAddress); props.put(ConsumerConfig.GROUP_ID_CONFIG, "product"); return new DefaultKafkaConsumerFactory<>(props, new StringDeserializer(), new JsonDeserializer<>(Product.class)); } @Bean public ConcurrentKafkaListenerContainerFactory<String, Product> productKafkaListenerContainerFactory() { ConcurrentKafkaListenerContainerFactory<String, Product> factory = new ConcurrentKafkaListenerContainerFactory<>(); factory.setConsumerFactory(productConsumerFactory()); return factory; } @Bean public ProducerFactory<String, Product> productProducerFactory() { Map<String, Object> configProps = new HashMap<>(); configProps.put(ProducerConfig.BOOTSTRAP_SERVERS_CONFIG, bootstrapAddress); configProps.put(ProducerConfig.KEY_SERIALIZER_CLASS_CONFIG, StringSerializer.class); configProps.put(ProducerConfig.VALUE_SERIALIZER_CLASS_CONFIG, JsonSerializer.class); return new DefaultKafkaProducerFactory<>(configProps); } @Bean public KafkaTemplate<String, Product> productKafkaTemplate() { return new KafkaTemplate<>(productProducerFactory()); } @Bean public NewTopic topic4() { return new NewTopic(productTopicName, 1, (short) 1); } @Bean public ProductMessageProducer productMessageProducer() { return new ProductMessageProducer(); } @Bean public ProductMessageListener productMessageListener() { return new ProductMessageListener(); } }
[ "arunvelusamyd@gmail.com" ]
arunvelusamyd@gmail.com
9f74118134ca61a09da55ee28d1f4f05924557e4
2626f467b449f47b96f05f2492b9c90b3343f8c4
/src/main/java/fi/vm/kapa/rova/vare/model/SearchTypeEnum.java
6fcdd13a57a2f055235f98b78d6c5df4c7f053f8
[ "MIT" ]
permissive
vrk-kpa/roles-auths-engine-api
59d8af828326ac90a9bab7473bc6dab7645244da
e8ec5f6897a5987479942821ed2d0f86ea891b69
refs/heads/master
2021-09-01T13:34:45.962101
2017-12-27T08:03:22
2017-12-27T08:03:22
32,150,925
0
0
null
null
null
null
UTF-8
Java
false
false
1,252
java
/** * The MIT License * Copyright (c) 2016 Population Register Centre * * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal * in the Software without restriction, including without limitation the rights * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell * copies of the Software, and to permit persons to whom the Software is * furnished to do so, subject to the following conditions: * * The above copyright notice and this permission notice shall be included in * all copies or substantial portions of the Software. * * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN * THE SOFTWARE. */ package fi.vm.kapa.rova.vare.model; public enum SearchTypeEnum { ALL, PERSONS, ORGANIZATIONS; }
[ "riku.kokko@gofore.com" ]
riku.kokko@gofore.com
c57f16731dd56e2c93a8d5f1d19b50ec8879f073
f0417c99a40f2978304c51ecb7e8d074f7883715
/Servlet/src/main/java/cn11/xyh/Filter/EncodingFilter02/LoginServlet.java
f9ea3ca7cf8c5674896d243dd7d65925669be650
[]
no_license
DanielXu1993/J2EE
76eb884fb97f6d306957fba93c04e6199d7dcd82
722e605922147443b1b08b20967f10c8b121b3b7
refs/heads/master
2020-03-18T17:06:25.620703
2019-02-03T01:35:34
2019-02-03T01:35:34
135,006,611
0
0
null
null
null
null
UTF-8
Java
false
false
861
java
package cn11.xyh.Filter.EncodingFilter02; import javax.servlet.ServletException; import javax.servlet.annotation.WebServlet; import javax.servlet.http.HttpServlet; import javax.servlet.http.HttpServletRequest; import javax.servlet.http.HttpServletResponse; import java.io.IOException; @WebServlet(name = "login", urlPatterns = "/login") public class LoginServlet extends HttpServlet { @Override protected void doPost(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException { String username = request.getParameter("username"); System.out.println(username); } @Override protected void doGet(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException { this.doPost(request, response); } }
[ "540402187@qq.com" ]
540402187@qq.com
ccf5044592aedb8ce0d3951352540d41976548ea
f1301af15dc7f5257531393984a478f578e49fb9
/src/main/java/eney/security/JwtAuthenticationEntryPoint.java
6d3eeb900684c96fd7b4ce685bd0dde5c95ef8c2
[]
no_license
lemur0920/eney_react
db2837501731412f6c313bdb0b1c6c8aad1a4393
014fa98284adb61c9451c85221442100c768a2bb
refs/heads/master
2023-01-12T06:41:24.391898
2020-11-09T02:06:01
2020-11-09T02:06:01
311,199,257
0
0
null
null
null
null
UTF-8
Java
false
false
1,092
java
package eney.security; import eney.web.UserController; import eney.web.UserController; import org.slf4j.Logger; import org.slf4j.LoggerFactory; import org.springframework.security.core.AuthenticationException; import org.springframework.security.web.AuthenticationEntryPoint; import org.springframework.stereotype.Component; import javax.servlet.ServletException; import javax.servlet.http.HttpServletRequest; import javax.servlet.http.HttpServletResponse; import java.io.IOException; @Component public class JwtAuthenticationEntryPoint implements AuthenticationEntryPoint { private static final Logger logger = LoggerFactory.getLogger(UserController.class); @Override public void commence(HttpServletRequest httpServletRequest, HttpServletResponse httpServletResponse, AuthenticationException e) throws IOException, ServletException { logger.error("Responding with unauthorized error. Message - {}", e.getMessage()); httpServletResponse.sendError(HttpServletResponse.SC_UNAUTHORIZED, e.getMessage()); } }
[ "lemur12@naver.com" ]
lemur12@naver.com
8ac777a0d9406332df605bc8023ee523b508e397
f6ebc33241145b2c60ade7ef5303f8d0b4753030
/src/main/java/ubertweakstor/lagfarmfinder/LagFarmFinder.java
1e500e8b61499d3b9598285ec9b76555a94179df
[]
no_license
TimGaming/LagFarmFinder
5346a6a018ece13d33abbd094a07b0f05af8edbb
c7bfb5284134d5731756b2f8c41e929b8ba78866
refs/heads/master
2016-09-06T03:48:32.135171
2013-12-19T07:33:41
2013-12-19T07:33:41
null
0
0
null
null
null
null
UTF-8
Java
false
false
4,497
java
/* * Author: John "Ubertweakstor" Board * Date: 21/12/12 14:10 * Description: XRay Detector Plugin */ package ubertweakstor.lagfarmfinder; import java.util.HashMap; import java.util.Map; import java.util.logging.Logger; import org.bukkit.ChatColor; import org.bukkit.command.Command; import org.bukkit.command.CommandSender; import org.bukkit.entity.Player; import org.bukkit.plugin.java.JavaPlugin; public class LagFarmFinder extends JavaPlugin { static final Logger log = Logger.getLogger("Minecraft"); /* * Name: onEnable Description: Called when plugin is enabled. Returns: None * Parameters: None Requirements: None */ @Override public void onEnable() { log.info("Enabled."); } /* * Name: onDisable Description: Called when plugin is disabled. Returns: * None Parameters: None Requirements: None */ @Override public void onDisable() { log.info("Disabled."); } // =====[Util]=====// /* * Name: onCommand Description: Called when a command has been executed * Returns: boolean Parameters: CommandSender sender, Command cmd, String * label, String[] args Requirements: None */ @Override public boolean onCommand(CommandSender sender, Command cmd, String label, String[] args) { CommandSender ply = sender; if (label.equalsIgnoreCase("mobcount")){ if (args.length!=2){ ply.sendMessage(ChatColor.RED+"ERROR: Invalid Syntax."); return true; } if (getServer().getPlayer(args[0])==null){ ply.sendMessage(ChatColor.RED+"ERROR: Player Not Online"); return true; } if(Integer.valueOf(args[1])>200){ ply.sendMessage(ChatColor.RED+"ERROR: Please do not select a radius higher than 200."); return true; } try{ Integer.valueOf(args[1]); }catch (Exception ex){ ply.sendMessage(ChatColor.RED+"Radius not valid."); return true; } ply.sendMessage(ChatColor.BLUE+"Number of mobs in a "+args[1]+ " radius around "+ChatColor.BLUE+args[0]+": "+ ChatColor.RED+String.valueOf(getNumberOfEntitiesNear(getServer().getPlayer(args[0]), Integer.valueOf(args[1])))); return true; } else if(label.equalsIgnoreCase("findlag")){ HashMap<Player, Integer> top = new HashMap<Player, Integer>(); if(args.length==1 && Integer.valueOf(args[0])>200){ ply.sendMessage(ChatColor.RED+"ERROR: Please do not select a radius higher than 200."); return true; } for(Player p: getServer().getOnlinePlayers()){ if (args.length >= 1){ top.put(p, getNumberOfEntitiesNear(p, Integer.valueOf(args[0]))); } else{ top.put(p, getNumberOfEntitiesNear(p, 80)); } } int iterations = 0; if (top.size() > 10){ iterations = 10; } else { iterations = top.size(); } int cnt = 1; for(int x = 0; x!=iterations; x++){ Map.Entry<Player, Integer> maxEntry = null; for(Map.Entry<Player, Integer> entry: top.entrySet()){ if (maxEntry == null || entry.getValue()>maxEntry.getValue()){ maxEntry = entry; } } ply.sendMessage(ChatColor.GREEN+String.valueOf(cnt)+ ". "+ChatColor.RED+((Player)maxEntry.getKey()).getName()+ ": "+ChatColor.BLUE+String.valueOf(maxEntry.getValue())); top.remove(maxEntry.getKey()); cnt++; } } return true; } public int getNumberOfEntitiesNear(Player p, int radius){ try{ return p.getNearbyEntities(radius, radius, radius).size(); } catch (Exception ex){ return -1; } } }
[ "johnsBogAcc@gmail.com" ]
johnsBogAcc@gmail.com
56f57831ad4bc34a9973a38f041adc1f8c314b4c
bc787d00739d2846333dac8f8001e8131eb5183d
/src/main/java/com/services/AccountServiceImpl.java
1badcdb4aa1860c895b66efb7a62d9200897d331
[]
no_license
SauriBabu/SpringMVCLearn
7cb00459d4be9666e5993a592a7edc4f505e780f
5a6e9c6d3de21121c5b47120d8e5a0bf9213195c
refs/heads/master
2020-03-30T02:18:35.626295
2018-09-27T18:07:34
2018-09-27T18:07:34
150,624,808
0
0
null
null
null
null
UTF-8
Java
false
false
1,371
java
package com.services; import java.util.List; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Service; import org.springframework.transaction.annotation.Propagation; import org.springframework.transaction.annotation.Transactional; import com.model.Account; import com.repository.AccountRepository; @Service public class AccountServiceImpl implements AccountService { @Autowired private AccountRepository repository; /* (non-Javadoc) * @see com.services.AcccountService#getAccounts() */ @Override public List<Account> getAccounts() { System.out.println("AccountServiceImpl.getAccounts()"); return repository.getAllAccount(); } /* (non-Javadoc) * @see com.services.AcccountService#saveAccount(com.model.Account) */ @Override public void saveAccount(Account acc) { System.out.println("AccountServiceImpl.saveAccount()"); repository.saveAccount(acc); } @Override // @Transactional(propagation=Propagation.REQUIRES_NEW,rollbackFor={Exception.class}) public void transfer(int fromId,int toId,double amt)throws Exception { try { repository.deposit(toId, amt); repository.withdraw(fromId, amt); System.out.println("AccountServiceImpl.transfer() : success"); } catch (Exception e) { System.out.println("AccountServiceImpl.transfer() : fail"); throw e; } } }
[ "Saurabh Singh" ]
Saurabh Singh
9663b2c2318b50c2320586ff523bffc5e50d5b54
53915d9fc02f16fd175ddb3ecf6e6cf82c5dacb0
/User.java
39bc0555b2ebb52ea008d84b221fb9a8742ec6da
[]
no_license
Anna-MariaFilipova/MobileOperator
52a90dabb772d3de0ad40d643e19003b0128a4d1
e10c50044d6dc908beca9d6ed09861e31e55b544
refs/heads/master
2022-11-21T08:05:18.949154
2020-07-15T11:42:03
2020-07-15T11:42:03
278,878,191
0
0
null
null
null
null
UTF-8
Java
false
false
929
java
package mobileOperator; public class User { private int id; private String name; private String email; private String password; User(String name, String email, String password, int id) { this.id = id; this.name = name; this.email = email; this.password = password; } User(String name, String email, String password) { this.name = name; this.email = email; this.password = password; } public void setId(int id) { this.id = id; } public int getId() { return id; } public void setName(String name) { this.name = name; } public void setEmail(String email) { this.email = email; } public void setPassword(String password) throws PasswordException { this.password = password; } public String getName() { return name; } public String getEmail() { return email; } public String getPassword() { return password; } }
[ "noreply@github.com" ]
Anna-MariaFilipova.noreply@github.com
73f3ad0a642bdf0d68fe369725a94ca4052f6749
78ee3681df2d72d2d132dd6fcc97cda846a9e10e
/src/test/java/com/eip/chapter10/PostOrderTraversalTest.java
2e29bfde7e5e2fb717a6ff5b58bc5fb46995854e
[]
no_license
sdpatil/ElementsOfProgrammingInterview
1bf00bb3d366b9c07ba13f05d3430459cf542ff5
b3390677765713056f41072cc16cd6f4f426c0e9
refs/heads/master
2021-05-23T04:59:01.383832
2019-09-03T22:30:31
2019-09-03T22:30:31
81,218,472
1
0
null
2020-10-12T23:52:48
2017-02-07T14:44:29
Java
UTF-8
Java
false
false
1,571
java
package com.eip.chapter10; import org.junit.Before; import org.junit.Test; /** * Created by sunilpatil on 2/18/17. */ public class PostOrderTraversalTest { PreOrderTraversal treeTraversal; BinaryTreeNode<Integer> rootNode; @Before public void setup(){ treeTraversal = new PreOrderTraversal(); rootNode = new BinaryTreeNode<Integer>(314); rootNode.left = new BinaryTreeNode<Integer>(6); rootNode.right = new BinaryTreeNode<Integer>(6); rootNode.left.left = new BinaryTreeNode<Integer>(271); rootNode.left.left.left = new BinaryTreeNode<Integer>(28); rootNode.left.left.right = new BinaryTreeNode<Integer>(0); rootNode.left.right = new BinaryTreeNode<Integer>(561); rootNode.left.right.right = new BinaryTreeNode<Integer>(3); rootNode.left.right.right.left = new BinaryTreeNode<Integer>(17); rootNode.right.left = new BinaryTreeNode<Integer>(2); rootNode.right.left.right = new BinaryTreeNode<Integer>(1); rootNode.right.left.right.left = new BinaryTreeNode<Integer>(401); rootNode.right.left.right.right = new BinaryTreeNode<Integer>(257); rootNode.right.left.right.left = new BinaryTreeNode<Integer>(401); rootNode.right.left.right.left.right = new BinaryTreeNode<Integer>(641); rootNode.right.right = new BinaryTreeNode<Integer>(271); rootNode.right.right.right = new BinaryTreeNode<Integer>(28); } @Test public void simpleTest(){ treeTraversal.preOrderTraversal(rootNode); } }
[ "sunilpatil@maprtech.com" ]
sunilpatil@maprtech.com
bb946a05ac07f576c53597ffb344ec4748b59157
9006cac101627c34c52520494beb8d4bf01b7584
/sudoku/src/main/java/sudoku4/main.java
86f55d50290c37ce1bf3bede3863c1a245d148b5
[]
no_license
Albert-cmd/Sudoku
f0fee858afaed6dffe41e29308aa4a0fb49e1535
978445d03a25292d69138ca876f862e44c16be74
refs/heads/master
2022-12-31T08:21:13.978374
2020-10-22T18:22:22
2020-10-22T18:22:22
239,848,414
0
0
null
null
null
null
UTF-8
Java
false
false
1,240
java
/* * To change this license header, choose License Headers in Project Properties. * To change this template file, choose Tools | Templates * and open the template in the editor. */ package sudoku4; import javax.swing.JLabel; import javax.swing.SwingConstants; import javax.swing.table.DefaultTableCellRenderer; import javax.swing.table.DefaultTableModel; import static sudoku4.Inici_controller.dificultad; /** * * @author Albert Workstation */ public class main { /** * @param args the command line arguments */ public static void main(String[] args) { // TODO code application logic here // ON N ES IGUAL AL NOMBRE DE COLUMNES // K IGUAL AL NOMBRE DE BUITS QUE VOLEM // DIFICIL 30 K=51 MITJA 35 K=46 FACIL 40=41 finestra_inici fi; tauler t; Tauler_controller tc; Inici_controller ic; fi = new finestra_inici(); t = new tauler(); tc = new Tauler_controller(t); ic = new Inici_controller(fi, tc); fi.setVisible(true); fi.setLocationRelativeTo(null); } }
[ "noreply@github.com" ]
Albert-cmd.noreply@github.com
1bf429e5e2fc0d8a85a8f56868c53075be761800
40c3fcdef18020c903929ba0981e8c6c0dcd09f8
/tubemq-core/src/main/java/org/apache/tubemq/corebase/utils/MixedUtils.java
17ccb5e4e8ea1a54ad3097fc543fc9746f6f3c89
[ "Apache-2.0", "MIT", "BSD-3-Clause", "LicenseRef-scancode-unknown-license-reference" ]
permissive
zjmeow/incubator-tubemq
7dabb443452d291dee6adb0c3f5f5acb82de01ba
e25e399c6994d9dc45f10e84dd1f5b50dd072b11
refs/heads/master
2022-12-05T00:09:45.448367
2020-08-19T11:08:54
2020-08-19T11:08:54
288,690,447
1
0
Apache-2.0
2020-08-19T09:32:46
2020-08-19T09:32:45
null
UTF-8
Java
false
false
1,327
java
/* * Licensed to the Apache Software Foundation (ASF) under one or more * contributor license agreements. See the NOTICE file distributed with * this work for additional information regarding copyright ownership. * The ASF licenses this file to You under the Apache License, Version 2.0 * (the "License"); you may not use this file except in compliance with * the License. You may obtain a copy of the License at * <p> * http://www.apache.org/licenses/LICENSE-2.0 * <p> * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ package org.apache.tubemq.corebase.utils; public class MixedUtils { // java version cache private static String javaVersion = ""; static { javaVersion = System.getProperty("java.version"); } public static String getJavaVersion() { if (TStringUtils.isEmpty(javaVersion)) { return ""; } else { int maxLen = Math.min(javaVersion.length(), 100); return javaVersion.substring(0, maxLen); } } }
[ "noreply@github.com" ]
zjmeow.noreply@github.com
60eee52c6643931c52ac5a5b322128ebcede002a
015a6020b6f797559da466427cab077caeb72951
/src/main/java/com/anhtt/eTutor/model/Student.java
abc543e160e93c35cd481f9f57dad31fe11da751
[]
no_license
pkimanh03/EtutorSpringBoot
5a6c494fce940b5c26db22e62f260a2d81e3f37b
3a1820e66af9b50837fc4972d394eca0dff3aab0
refs/heads/main
2023-01-07T10:10:51.346623
2020-11-08T14:32:56
2020-11-08T14:32:56
310,622,579
0
0
null
null
null
null
UTF-8
Java
false
false
3,267
java
package com.anhtt.eTutor.model; import org.hibernate.annotations.GenericGenerator; import org.hibernate.annotations.Type; import org.springframework.beans.factory.annotation.Value; import javax.persistence.*; import java.util.UUID; @Entity @Table(name = "Student") public class Student { @Id @GeneratedValue(generator = "uuid2") @GenericGenerator(name = "uuid2", strategy = "org.hibernate.id.UUIDGenerator") @Column(name = "id", columnDefinition = "UNIQUEIDENTIFIER") @Type(type = "org.hibernate.type.UUIDCharType") private UUID id; @Column(name = "fullname", columnDefinition = "NVARCHAR(max)") private String fullname; @Column(name = "age") private int age; @Column(name = "address", columnDefinition = "NVARCHAR(max)") private String address; @Column(name = "phoneNumber") private String phoneNumber; @Column(name = "favoriteMajors", columnDefinition = "NVARCHAR(max)") private String favoriteMajors; @OneToOne(cascade = CascadeType.ALL) @JoinColumn(name = "accountId", referencedColumnName = "id", nullable = false) private Account studentAccount; @Value(value = "false") @Column(name = "isDeleted") private boolean isDelete; public Student() { } public Student(String fullname, int age, String address, String phoneNumber, String favoriteMajors, Account studentAccount, boolean isDelete) { this.fullname = fullname; this.age = age; this.address = address; this.phoneNumber = phoneNumber; this.favoriteMajors = favoriteMajors; this.studentAccount = studentAccount; this.isDelete = isDelete; } public Student(String fullname, int age, String address, String phoneNumber, String favoriteMajors, boolean isDelete) { this.fullname = fullname; this.age = age; this.address = address; this.phoneNumber = phoneNumber; this.favoriteMajors = favoriteMajors; this.isDelete = isDelete; } public UUID getId() { return id; } public void setId(UUID id) { this.id = id; } public String getFullname() { return fullname; } public void setFullname(String fullname) { this.fullname = fullname; } public int getAge() { return age; } public void setAge(int age) { this.age = age; } public String getAddress() { return address; } public void setAddress(String address) { this.address = address; } public String getPhoneNumber() { return phoneNumber; } public void setPhoneNumber(String phoneNumber) { this.phoneNumber = phoneNumber; } public String getFavoriteMajors() { return favoriteMajors; } public void setFavoriteMajors(String favoriteMajors) { this.favoriteMajors = favoriteMajors; } public Account getStudentAccount() { return studentAccount; } public void setStudentAccount(Account studentAccount) { this.studentAccount = studentAccount; } public boolean isDelete() { return isDelete; } public void setDelete(boolean delete) { isDelete = delete; } }
[ "anh.pn@geekup.vn" ]
anh.pn@geekup.vn
560c6b15c526aa73c00eaff8327f95647175dd3f
c65e7564c27048ea6dd7b014e3eba9b9c4f097f3
/src/main/java/co/com/sofka/pet_project/jefe/value/Caracteristica.java
192f641370aff66ca69d2b046614bb55a8137fb0
[]
no_license
Calapzu/pet-project
de7ad032fb7116943446ea6a5876121e014f5d76
7bc9e3684f66a11de92755ac4d0041dbfd5cab10
refs/heads/master
2023-08-07T01:08:31.621592
2021-09-28T15:03:56
2021-09-28T15:03:56
411,328,631
0
0
null
null
null
null
UTF-8
Java
false
false
871
java
package co.com.sofka.pet_project.jefe.value; import co.com.sofka.domain.generic.ValueObject; import java.util.Objects; public class Caracteristica implements ValueObject<String> { private final String value; public Caracteristica(String value) { this.value = Objects.requireNonNull(value); if(this.value.isBlank()){ throw new IllegalArgumentException("La caracteristica no puede estar vacia"); } } @Override public boolean equals(Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; Caracteristica that = (Caracteristica) o; return Objects.equals(value, that.value); } @Override public int hashCode() { return Objects.hash(value); } @Override public String value() { return value; } }
[ "yamsoncalapzu@gmail.com" ]
yamsoncalapzu@gmail.com