_id
stringlengths
2
7
title
stringlengths
3
140
partition
stringclasses
3 values
text
stringlengths
73
34.1k
language
stringclasses
1 value
meta_information
dict
q10400
gslbservice.update
train
public static base_response update(nitro_service client, gslbservice resource) throws Exception { gslbservice updateresource = new gslbservice(); updateresource.servicename = resource.servicename; updateresource.ipaddress = resource.ipaddress; updateresource.publicip = resource.publicip; updateresource.publicport = resource.publicport; updateresource.cip = resource.cip; updateresource.cipheader = resource.cipheader; updateresource.sitepersistence = resource.sitepersistence; updateresource.siteprefix = resource.siteprefix; updateresource.maxclient = resource.maxclient; updateresource.healthmonitor = resource.healthmonitor; updateresource.maxbandwidth = resource.maxbandwidth; updateresource.downstateflush = resource.downstateflush; updateresource.maxaaausers = resource.maxaaausers; updateresource.viewname = resource.viewname; updateresource.viewip = resource.viewip; updateresource.monthreshold = resource.monthreshold; updateresource.weight = resource.weight; updateresource.monitor_name_svc = resource.monitor_name_svc; updateresource.hashid = resource.hashid; updateresource.comment = resource.comment; updateresource.appflowlog = resource.appflowlog; return updateresource.update_resource(client); }
java
{ "resource": "" }
q10401
gslbservice.update
train
public static base_responses update(nitro_service client, gslbservice resources[]) throws Exception { base_responses result = null; if (resources != null && resources.length > 0) { gslbservice updateresources[] = new gslbservice[resources.length]; for (int i=0;i<resources.length;i++){ updateresources[i] = new gslbservice(); updateresources[i].servicename = resources[i].servicename; updateresources[i].ipaddress = resources[i].ipaddress; updateresources[i].publicip = resources[i].publicip; updateresources[i].publicport = resources[i].publicport; updateresources[i].cip = resources[i].cip; updateresources[i].cipheader = resources[i].cipheader; updateresources[i].sitepersistence = resources[i].sitepersistence; updateresources[i].siteprefix = resources[i].siteprefix; updateresources[i].maxclient = resources[i].maxclient; updateresources[i].healthmonitor = resources[i].healthmonitor; updateresources[i].maxbandwidth = resources[i].maxbandwidth; updateresources[i].downstateflush = resources[i].downstateflush; updateresources[i].maxaaausers = resources[i].maxaaausers; updateresources[i].viewname = resources[i].viewname; updateresources[i].viewip = resources[i].viewip; updateresources[i].monthreshold = resources[i].monthreshold; updateresources[i].weight = resources[i].weight; updateresources[i].monitor_name_svc = resources[i].monitor_name_svc; updateresources[i].hashid = resources[i].hashid; updateresources[i].comment = resources[i].comment; updateresources[i].appflowlog = resources[i].appflowlog; } result = update_bulk_request(client, updateresources); } return result; }
java
{ "resource": "" }
q10402
gslbservice.unset
train
public static base_responses unset(nitro_service client, gslbservice resources[], String[] args) throws Exception { base_responses result = null; if (resources != null && resources.length > 0) { gslbservice unsetresources[] = new gslbservice[resources.length]; for (int i=0;i<resources.length;i++){ unsetresources[i] = new gslbservice(); unsetresources[i].servicename = resources[i].servicename; } result = unset_bulk_request(client, unsetresources,args); } return result; }
java
{ "resource": "" }
q10403
gslbservice.rename
train
public static base_response rename(nitro_service client, gslbservice resource, String new_servicename) throws Exception { gslbservice renameresource = new gslbservice(); renameresource.servicename = resource.servicename; return renameresource.rename_resource(client,new_servicename); }
java
{ "resource": "" }
q10404
gslbservice.get
train
public static gslbservice[] get(nitro_service service) throws Exception{ gslbservice obj = new gslbservice(); gslbservice[] response = (gslbservice[])obj.get_resources(service); return response; }
java
{ "resource": "" }
q10405
gslbservice.get
train
public static gslbservice get(nitro_service service, String servicename) throws Exception{ gslbservice obj = new gslbservice(); obj.set_servicename(servicename); gslbservice response = (gslbservice) obj.get_resource(service); return response; }
java
{ "resource": "" }
q10406
gslbservice.get_filtered
train
public static gslbservice[] get_filtered(nitro_service service, filtervalue[] filter) throws Exception{ gslbservice obj = new gslbservice(); options option = new options(); option.set_filter(filter); gslbservice[] response = (gslbservice[]) obj.getfiltered(service, option); return response; }
java
{ "resource": "" }
q10407
aaaglobal_binding.get
train
public static aaaglobal_binding get(nitro_service service) throws Exception{ aaaglobal_binding obj = new aaaglobal_binding(); aaaglobal_binding response = (aaaglobal_binding) obj.get_resource(service); return response; }
java
{ "resource": "" }
q10408
clusterinstance.add
train
public static base_response add(nitro_service client, clusterinstance resource) throws Exception { clusterinstance addresource = new clusterinstance(); addresource.clid = resource.clid; addresource.deadinterval = resource.deadinterval; addresource.hellointerval = resource.hellointerval; addresource.preemption = resource.preemption; return addresource.add_resource(client); }
java
{ "resource": "" }
q10409
clusterinstance.add
train
public static base_responses add(nitro_service client, clusterinstance resources[]) throws Exception { base_responses result = null; if (resources != null && resources.length > 0) { clusterinstance addresources[] = new clusterinstance[resources.length]; for (int i=0;i<resources.length;i++){ addresources[i] = new clusterinstance(); addresources[i].clid = resources[i].clid; addresources[i].deadinterval = resources[i].deadinterval; addresources[i].hellointerval = resources[i].hellointerval; addresources[i].preemption = resources[i].preemption; } result = add_bulk_request(client, addresources); } return result; }
java
{ "resource": "" }
q10410
clusterinstance.delete
train
public static base_response delete(nitro_service client, Long clid) throws Exception { clusterinstance deleteresource = new clusterinstance(); deleteresource.clid = clid; return deleteresource.delete_resource(client); }
java
{ "resource": "" }
q10411
clusterinstance.delete
train
public static base_responses delete(nitro_service client, clusterinstance resources[]) throws Exception { base_responses result = null; if (resources != null && resources.length > 0) { clusterinstance deleteresources[] = new clusterinstance[resources.length]; for (int i=0;i<resources.length;i++){ deleteresources[i] = new clusterinstance(); deleteresources[i].clid = resources[i].clid; } result = delete_bulk_request(client, deleteresources); } return result; }
java
{ "resource": "" }
q10412
clusterinstance.update
train
public static base_response update(nitro_service client, clusterinstance resource) throws Exception { clusterinstance updateresource = new clusterinstance(); updateresource.clid = resource.clid; updateresource.deadinterval = resource.deadinterval; updateresource.hellointerval = resource.hellointerval; updateresource.preemption = resource.preemption; return updateresource.update_resource(client); }
java
{ "resource": "" }
q10413
clusterinstance.update
train
public static base_responses update(nitro_service client, clusterinstance resources[]) throws Exception { base_responses result = null; if (resources != null && resources.length > 0) { clusterinstance updateresources[] = new clusterinstance[resources.length]; for (int i=0;i<resources.length;i++){ updateresources[i] = new clusterinstance(); updateresources[i].clid = resources[i].clid; updateresources[i].deadinterval = resources[i].deadinterval; updateresources[i].hellointerval = resources[i].hellointerval; updateresources[i].preemption = resources[i].preemption; } result = update_bulk_request(client, updateresources); } return result; }
java
{ "resource": "" }
q10414
clusterinstance.unset
train
public static base_response unset(nitro_service client, clusterinstance resource, String[] args) throws Exception{ clusterinstance unsetresource = new clusterinstance(); unsetresource.clid = resource.clid; return unsetresource.unset_resource(client,args); }
java
{ "resource": "" }
q10415
clusterinstance.unset
train
public static base_responses unset(nitro_service client, Long clid[], String args[]) throws Exception { base_responses result = null; if (clid != null && clid.length > 0) { clusterinstance unsetresources[] = new clusterinstance[clid.length]; for (int i=0;i<clid.length;i++){ unsetresources[i] = new clusterinstance(); unsetresources[i].clid = clid[i]; } result = unset_bulk_request(client, unsetresources,args); } return result; }
java
{ "resource": "" }
q10416
clusterinstance.enable
train
public static base_response enable(nitro_service client, Long clid) throws Exception { clusterinstance enableresource = new clusterinstance(); enableresource.clid = clid; return enableresource.perform_operation(client,"enable"); }
java
{ "resource": "" }
q10417
clusterinstance.enable
train
public static base_responses enable(nitro_service client, Long clid[]) throws Exception { base_responses result = null; if (clid != null && clid.length > 0) { clusterinstance enableresources[] = new clusterinstance[clid.length]; for (int i=0;i<clid.length;i++){ enableresources[i] = new clusterinstance(); enableresources[i].clid = clid[i]; } result = perform_operation_bulk_request(client, enableresources,"enable"); } return result; }
java
{ "resource": "" }
q10418
clusterinstance.disable
train
public static base_response disable(nitro_service client, Long clid) throws Exception { clusterinstance disableresource = new clusterinstance(); disableresource.clid = clid; return disableresource.perform_operation(client,"disable"); }
java
{ "resource": "" }
q10419
clusterinstance.disable
train
public static base_responses disable(nitro_service client, Long clid[]) throws Exception { base_responses result = null; if (clid != null && clid.length > 0) { clusterinstance disableresources[] = new clusterinstance[clid.length]; for (int i=0;i<clid.length;i++){ disableresources[i] = new clusterinstance(); disableresources[i].clid = clid[i]; } result = perform_operation_bulk_request(client, disableresources,"disable"); } return result; }
java
{ "resource": "" }
q10420
clusterinstance.get
train
public static clusterinstance[] get(nitro_service service) throws Exception{ clusterinstance obj = new clusterinstance(); clusterinstance[] response = (clusterinstance[])obj.get_resources(service); return response; }
java
{ "resource": "" }
q10421
clusterinstance.get
train
public static clusterinstance get(nitro_service service, Long clid) throws Exception{ clusterinstance obj = new clusterinstance(); obj.set_clid(clid); clusterinstance response = (clusterinstance) obj.get_resource(service); return response; }
java
{ "resource": "" }
q10422
clusterinstance.get
train
public static clusterinstance[] get(nitro_service service, Long clid[]) throws Exception{ if (clid !=null && clid.length>0) { clusterinstance response[] = new clusterinstance[clid.length]; clusterinstance obj[] = new clusterinstance[clid.length]; for (int i=0;i<clid.length;i++) { obj[i] = new clusterinstance(); obj[i].set_clid(clid[i]); response[i] = (clusterinstance) obj[i].get_resource(service); } return response; } return null; }
java
{ "resource": "" }
q10423
vpnglobal_vpnnexthopserver_binding.get
train
public static vpnglobal_vpnnexthopserver_binding[] get(nitro_service service) throws Exception{ vpnglobal_vpnnexthopserver_binding obj = new vpnglobal_vpnnexthopserver_binding(); vpnglobal_vpnnexthopserver_binding response[] = (vpnglobal_vpnnexthopserver_binding[]) obj.get_resources(service); return response; }
java
{ "resource": "" }
q10424
appfwpolicy_csvserver_binding.get
train
public static appfwpolicy_csvserver_binding[] get(nitro_service service, String name) throws Exception{ appfwpolicy_csvserver_binding obj = new appfwpolicy_csvserver_binding(); obj.set_name(name); appfwpolicy_csvserver_binding response[] = (appfwpolicy_csvserver_binding[]) obj.get_resources(service); return response; }
java
{ "resource": "" }
q10425
vpnvserver_aaapreauthenticationpolicy_binding.get
train
public static vpnvserver_aaapreauthenticationpolicy_binding[] get(nitro_service service, String name) throws Exception{ vpnvserver_aaapreauthenticationpolicy_binding obj = new vpnvserver_aaapreauthenticationpolicy_binding(); obj.set_name(name); vpnvserver_aaapreauthenticationpolicy_binding response[] = (vpnvserver_aaapreauthenticationpolicy_binding[]) obj.get_resources(service); return response; }
java
{ "resource": "" }
q10426
shutdown.Shutdown
train
public static base_response Shutdown(nitro_service client, shutdown resource) throws Exception { shutdown Shutdownresource = new shutdown(); return Shutdownresource.perform_operation(client); }
java
{ "resource": "" }
q10427
MtasSolrCollectionCache.getDataById
train
public HashSet<String> getDataById(String id) throws IOException { if (idToVersion.containsKey(id)) { return get(id); } else { return null; } }
java
{ "resource": "" }
q10428
MtasSolrCollectionCache.getAutomatonById
train
public Automaton getAutomatonById(String id) throws IOException { if (idToVersion.containsKey(id)) { List<BytesRef> bytesArray = new ArrayList<>(); Set<String> data = get(id); if (data != null) { Term term; for (String item : data) { term = new Term("dummy", item); bytesArray.add(term.bytes()); } Collections.sort(bytesArray); return Automata.makeStringUnion(bytesArray); } } return null; }
java
{ "resource": "" }
q10429
MtasSolrCollectionCache.deleteById
train
public void deleteById(String id) { if (idToVersion.containsKey(id)) { String version = idToVersion.remove(id); expirationVersion.remove(version); versionToItem.remove(version); if (collectionCachePath != null && !collectionCachePath.resolve(version).toFile().delete()) { log.debug("couldn't delete " + version); } } }
java
{ "resource": "" }
q10430
NERFeatureFactory.filterTag
train
private String filterTag(String tag) { AttributeValues answerAV = TagSet.getTagSet().fromTag(tag); answerAV.removeNonlexicalAttributes(); return TagSet.getTagSet().toTag(answerAV); }
java
{ "resource": "" }
q10431
ipv6.update
train
public static base_response update(nitro_service client, ipv6 resource) throws Exception { ipv6 updateresource = new ipv6(); updateresource.ralearning = resource.ralearning; updateresource.routerredirection = resource.routerredirection; updateresource.ndbasereachtime = resource.ndbasereachtime; updateresource.ndretransmissiontime = resource.ndretransmissiontime; updateresource.natprefix = resource.natprefix; updateresource.dodad = resource.dodad; return updateresource.update_resource(client); }
java
{ "resource": "" }
q10432
ipv6.unset
train
public static base_response unset(nitro_service client, ipv6 resource, String[] args) throws Exception{ ipv6 unsetresource = new ipv6(); return unsetresource.unset_resource(client,args); }
java
{ "resource": "" }
q10433
ipv6.get
train
public static ipv6 get(nitro_service service) throws Exception{ ipv6 obj = new ipv6(); ipv6[] response = (ipv6[])obj.get_resources(service); return response[0]; }
java
{ "resource": "" }
q10434
filterpolicy_binding.get
train
public static filterpolicy_binding get(nitro_service service, String name) throws Exception{ filterpolicy_binding obj = new filterpolicy_binding(); obj.set_name(name); filterpolicy_binding response = (filterpolicy_binding) obj.get_resource(service); return response; }
java
{ "resource": "" }
q10435
coparameter.unset
train
public static base_response unset(nitro_service client, coparameter resource, String[] args) throws Exception{ coparameter unsetresource = new coparameter(); return unsetresource.unset_resource(client,args); }
java
{ "resource": "" }
q10436
dbdbprofile.add
train
public static base_response add(nitro_service client, dbdbprofile resource) throws Exception { dbdbprofile addresource = new dbdbprofile(); addresource.name = resource.name; addresource.interpretquery = resource.interpretquery; addresource.stickiness = resource.stickiness; addresource.kcdaccount = resource.kcdaccount; addresource.conmultiplex = resource.conmultiplex; return addresource.add_resource(client); }
java
{ "resource": "" }
q10437
dbdbprofile.add
train
public static base_responses add(nitro_service client, dbdbprofile resources[]) throws Exception { base_responses result = null; if (resources != null && resources.length > 0) { dbdbprofile addresources[] = new dbdbprofile[resources.length]; for (int i=0;i<resources.length;i++){ addresources[i] = new dbdbprofile(); addresources[i].name = resources[i].name; addresources[i].interpretquery = resources[i].interpretquery; addresources[i].stickiness = resources[i].stickiness; addresources[i].kcdaccount = resources[i].kcdaccount; addresources[i].conmultiplex = resources[i].conmultiplex; } result = add_bulk_request(client, addresources); } return result; }
java
{ "resource": "" }
q10438
dbdbprofile.update
train
public static base_response update(nitro_service client, dbdbprofile resource) throws Exception { dbdbprofile updateresource = new dbdbprofile(); updateresource.name = resource.name; updateresource.interpretquery = resource.interpretquery; updateresource.stickiness = resource.stickiness; updateresource.kcdaccount = resource.kcdaccount; updateresource.conmultiplex = resource.conmultiplex; return updateresource.update_resource(client); }
java
{ "resource": "" }
q10439
dbdbprofile.update
train
public static base_responses update(nitro_service client, dbdbprofile resources[]) throws Exception { base_responses result = null; if (resources != null && resources.length > 0) { dbdbprofile updateresources[] = new dbdbprofile[resources.length]; for (int i=0;i<resources.length;i++){ updateresources[i] = new dbdbprofile(); updateresources[i].name = resources[i].name; updateresources[i].interpretquery = resources[i].interpretquery; updateresources[i].stickiness = resources[i].stickiness; updateresources[i].kcdaccount = resources[i].kcdaccount; updateresources[i].conmultiplex = resources[i].conmultiplex; } result = update_bulk_request(client, updateresources); } return result; }
java
{ "resource": "" }
q10440
dbdbprofile.get
train
public static dbdbprofile[] get(nitro_service service) throws Exception{ dbdbprofile obj = new dbdbprofile(); dbdbprofile[] response = (dbdbprofile[])obj.get_resources(service); return response; }
java
{ "resource": "" }
q10441
dbdbprofile.get
train
public static dbdbprofile get(nitro_service service, String name) throws Exception{ dbdbprofile obj = new dbdbprofile(); obj.set_name(name); dbdbprofile response = (dbdbprofile) obj.get_resource(service); return response; }
java
{ "resource": "" }
q10442
dbdbprofile.get_filtered
train
public static dbdbprofile[] get_filtered(nitro_service service, filtervalue[] filter) throws Exception{ dbdbprofile obj = new dbdbprofile(); options option = new options(); option.set_filter(filter); dbdbprofile[] response = (dbdbprofile[]) obj.getfiltered(service, option); return response; }
java
{ "resource": "" }
q10443
MtasPosition.checkType
train
public Boolean checkType(String type) { if (mtasPositionType == null) { return false; } else { return mtasPositionType.equals(type); } }
java
{ "resource": "" }
q10444
MtasPosition.getEnd
train
public Integer getEnd() { if (mtasPositionType.equals(POSITION_RANGE) || mtasPositionType.equals(POSITION_SET)) { return mtasPositionEnd; } else if (mtasPositionType.equals(POSITION_SINGLE)) { return mtasPositionStart; } else { return null; } }
java
{ "resource": "" }
q10445
wisite_farmname_binding.get
train
public static wisite_farmname_binding[] get(nitro_service service, String sitepath) throws Exception{ wisite_farmname_binding obj = new wisite_farmname_binding(); obj.set_sitepath(sitepath); wisite_farmname_binding response[] = (wisite_farmname_binding[]) obj.get_resources(service); return response; }
java
{ "resource": "" }
q10446
cachepolicylabel.add
train
public static base_response add(nitro_service client, cachepolicylabel resource) throws Exception { cachepolicylabel addresource = new cachepolicylabel(); addresource.labelname = resource.labelname; addresource.evaluates = resource.evaluates; return addresource.add_resource(client); }
java
{ "resource": "" }
q10447
cachepolicylabel.add
train
public static base_responses add(nitro_service client, cachepolicylabel resources[]) throws Exception { base_responses result = null; if (resources != null && resources.length > 0) { cachepolicylabel addresources[] = new cachepolicylabel[resources.length]; for (int i=0;i<resources.length;i++){ addresources[i] = new cachepolicylabel(); addresources[i].labelname = resources[i].labelname; addresources[i].evaluates = resources[i].evaluates; } result = add_bulk_request(client, addresources); } return result; }
java
{ "resource": "" }
q10448
cachepolicylabel.get
train
public static cachepolicylabel[] get(nitro_service service) throws Exception{ cachepolicylabel obj = new cachepolicylabel(); cachepolicylabel[] response = (cachepolicylabel[])obj.get_resources(service); return response; }
java
{ "resource": "" }
q10449
cachepolicylabel.get
train
public static cachepolicylabel get(nitro_service service, String labelname) throws Exception{ cachepolicylabel obj = new cachepolicylabel(); obj.set_labelname(labelname); cachepolicylabel response = (cachepolicylabel) obj.get_resource(service); return response; }
java
{ "resource": "" }
q10450
authenticationldappolicy_authenticationvserver_binding.get
train
public static authenticationldappolicy_authenticationvserver_binding[] get(nitro_service service, String name) throws Exception{ authenticationldappolicy_authenticationvserver_binding obj = new authenticationldappolicy_authenticationvserver_binding(); obj.set_name(name); authenticationldappolicy_authenticationvserver_binding response[] = (authenticationldappolicy_authenticationvserver_binding[]) obj.get_resources(service); return response; }
java
{ "resource": "" }
q10451
dnszone_domain_binding.get
train
public static dnszone_domain_binding[] get(nitro_service service, String zonename) throws Exception{ dnszone_domain_binding obj = new dnszone_domain_binding(); obj.set_zonename(zonename); dnszone_domain_binding response[] = (dnszone_domain_binding[]) obj.get_resources(service); return response; }
java
{ "resource": "" }
q10452
dnszone_domain_binding.count
train
public static long count(nitro_service service, String zonename) throws Exception{ dnszone_domain_binding obj = new dnszone_domain_binding(); obj.set_zonename(zonename); options option = new options(); option.set_count(true); dnszone_domain_binding response[] = (dnszone_domain_binding[]) obj.get_resources(service,option); if (response != null) { return response[0].__count; } return 0; }
java
{ "resource": "" }
q10453
lbvserver_rewritepolicy_binding.get
train
public static lbvserver_rewritepolicy_binding[] get(nitro_service service, String name) throws Exception{ lbvserver_rewritepolicy_binding obj = new lbvserver_rewritepolicy_binding(); obj.set_name(name); lbvserver_rewritepolicy_binding response[] = (lbvserver_rewritepolicy_binding[]) obj.get_resources(service); return response; }
java
{ "resource": "" }
q10454
PTBTokenizer.ptb2Text
train
public static String ptb2Text(String ptbText) { StringBuilder sb = new StringBuilder(ptbText.length()); // probably an overestimate PTB2TextLexer lexer = new PTB2TextLexer(new StringReader(ptbText)); try { for (String token; (token = lexer.next()) != null; ) { sb.append(token); } } catch (IOException e) { e.printStackTrace(); } return sb.toString(); }
java
{ "resource": "" }
q10455
PTBTokenizer.ptb2Text
train
public static int ptb2Text(Reader ptbText, Writer w) throws IOException { int numTokens = 0; PTB2TextLexer lexer = new PTB2TextLexer(ptbText); for (String token; (token = lexer.next()) != null; ) { numTokens++; w.write(token); } return numTokens; }
java
{ "resource": "" }
q10456
PTBTokenizer.factory
train
public static <T extends HasWord> TokenizerFactory<T> factory(LexedTokenFactory<T> factory, String options) { return new PTBTokenizerFactory<T>(factory, options); }
java
{ "resource": "" }
q10457
cmppolicylabel.add
train
public static base_response add(nitro_service client, cmppolicylabel resource) throws Exception { cmppolicylabel addresource = new cmppolicylabel(); addresource.labelname = resource.labelname; addresource.type = resource.type; return addresource.add_resource(client); }
java
{ "resource": "" }
q10458
cmppolicylabel.add
train
public static base_responses add(nitro_service client, cmppolicylabel resources[]) throws Exception { base_responses result = null; if (resources != null && resources.length > 0) { cmppolicylabel addresources[] = new cmppolicylabel[resources.length]; for (int i=0;i<resources.length;i++){ addresources[i] = new cmppolicylabel(); addresources[i].labelname = resources[i].labelname; addresources[i].type = resources[i].type; } result = add_bulk_request(client, addresources); } return result; }
java
{ "resource": "" }
q10459
cmppolicylabel.rename
train
public static base_response rename(nitro_service client, cmppolicylabel resource, String new_labelname) throws Exception { cmppolicylabel renameresource = new cmppolicylabel(); renameresource.labelname = resource.labelname; return renameresource.rename_resource(client,new_labelname); }
java
{ "resource": "" }
q10460
cmppolicylabel.get
train
public static cmppolicylabel[] get(nitro_service service) throws Exception{ cmppolicylabel obj = new cmppolicylabel(); cmppolicylabel[] response = (cmppolicylabel[])obj.get_resources(service); return response; }
java
{ "resource": "" }
q10461
cmppolicylabel.get
train
public static cmppolicylabel get(nitro_service service, String labelname) throws Exception{ cmppolicylabel obj = new cmppolicylabel(); obj.set_labelname(labelname); cmppolicylabel response = (cmppolicylabel) obj.get_resource(service); return response; }
java
{ "resource": "" }
q10462
vpnvserver_vpnnexthopserver_binding.get
train
public static vpnvserver_vpnnexthopserver_binding[] get(nitro_service service, String name) throws Exception{ vpnvserver_vpnnexthopserver_binding obj = new vpnvserver_vpnnexthopserver_binding(); obj.set_name(name); vpnvserver_vpnnexthopserver_binding response[] = (vpnvserver_vpnnexthopserver_binding[]) obj.get_resources(service); return response; }
java
{ "resource": "" }
q10463
cacheobject.expire
train
public static base_response expire(nitro_service client, cacheobject resource) throws Exception { cacheobject expireresource = new cacheobject(); expireresource.locator = resource.locator; expireresource.url = resource.url; expireresource.host = resource.host; expireresource.port = resource.port; expireresource.groupname = resource.groupname; expireresource.httpmethod = resource.httpmethod; return expireresource.perform_operation(client,"expire"); }
java
{ "resource": "" }
q10464
cacheobject.expire
train
public static base_responses expire(nitro_service client, cacheobject resources[]) throws Exception { base_responses result = null; if (resources != null && resources.length > 0) { cacheobject expireresources[] = new cacheobject[resources.length]; for (int i=0;i<resources.length;i++){ expireresources[i] = new cacheobject(); expireresources[i].locator = resources[i].locator; expireresources[i].url = resources[i].url; expireresources[i].host = resources[i].host; expireresources[i].port = resources[i].port; expireresources[i].groupname = resources[i].groupname; expireresources[i].httpmethod = resources[i].httpmethod; } result = perform_operation_bulk_request(client, expireresources,"expire"); } return result; }
java
{ "resource": "" }
q10465
cacheobject.flush
train
public static base_response flush(nitro_service client, cacheobject resource) throws Exception { cacheobject flushresource = new cacheobject(); flushresource.locator = resource.locator; flushresource.url = resource.url; flushresource.host = resource.host; flushresource.port = resource.port; flushresource.groupname = resource.groupname; flushresource.httpmethod = resource.httpmethod; flushresource.force = resource.force; return flushresource.perform_operation(client,"flush"); }
java
{ "resource": "" }
q10466
cacheobject.flush
train
public static base_responses flush(nitro_service client, cacheobject resources[]) throws Exception { base_responses result = null; if (resources != null && resources.length > 0) { cacheobject flushresources[] = new cacheobject[resources.length]; for (int i=0;i<resources.length;i++){ flushresources[i] = new cacheobject(); flushresources[i].locator = resources[i].locator; flushresources[i].url = resources[i].url; flushresources[i].host = resources[i].host; flushresources[i].port = resources[i].port; flushresources[i].groupname = resources[i].groupname; flushresources[i].httpmethod = resources[i].httpmethod; flushresources[i].force = resources[i].force; } result = perform_operation_bulk_request(client, flushresources,"flush"); } return result; }
java
{ "resource": "" }
q10467
cacheobject.save
train
public static base_response save(nitro_service client, cacheobject resource) throws Exception { cacheobject saveresource = new cacheobject(); saveresource.locator = resource.locator; return saveresource.perform_operation(client,"save"); }
java
{ "resource": "" }
q10468
cacheobject.save
train
public static base_responses save(nitro_service client, cacheobject resources[]) throws Exception { base_responses result = null; if (resources != null && resources.length > 0) { cacheobject saveresources[] = new cacheobject[resources.length]; for (int i=0;i<resources.length;i++){ saveresources[i] = new cacheobject(); saveresources[i].locator = resources[i].locator; } result = perform_operation_bulk_request(client, saveresources,"save"); } return result; }
java
{ "resource": "" }
q10469
cacheobject.get
train
public static cacheobject[] get(nitro_service service) throws Exception{ cacheobject obj = new cacheobject(); cacheobject[] response = (cacheobject[])obj.get_resources(service); return response; }
java
{ "resource": "" }
q10470
cacheobject.get
train
public static cacheobject[] get(nitro_service service, cacheobject_args args) throws Exception{ cacheobject obj = new cacheobject(); options option = new options(); option.set_args(nitro_util.object_to_string_withoutquotes(args)); cacheobject[] response = (cacheobject[])obj.get_resources(service, option); return response; }
java
{ "resource": "" }
q10471
sslpolicy_lbvserver_binding.get
train
public static sslpolicy_lbvserver_binding[] get(nitro_service service, String name) throws Exception{ sslpolicy_lbvserver_binding obj = new sslpolicy_lbvserver_binding(); obj.set_name(name); sslpolicy_lbvserver_binding response[] = (sslpolicy_lbvserver_binding[]) obj.get_resources(service); return response; }
java
{ "resource": "" }
q10472
cmppolicy_stats.get
train
public static cmppolicy_stats[] get(nitro_service service) throws Exception{ cmppolicy_stats obj = new cmppolicy_stats(); cmppolicy_stats[] response = (cmppolicy_stats[])obj.stat_resources(service); return response; }
java
{ "resource": "" }
q10473
cmppolicy_stats.get
train
public static cmppolicy_stats get(nitro_service service, String name) throws Exception{ cmppolicy_stats obj = new cmppolicy_stats(); obj.set_name(name); cmppolicy_stats response = (cmppolicy_stats) obj.stat_resource(service); return response; }
java
{ "resource": "" }
q10474
appfwpolicylabel_stats.get
train
public static appfwpolicylabel_stats[] get(nitro_service service) throws Exception{ appfwpolicylabel_stats obj = new appfwpolicylabel_stats(); appfwpolicylabel_stats[] response = (appfwpolicylabel_stats[])obj.stat_resources(service); return response; }
java
{ "resource": "" }
q10475
appfwpolicylabel_stats.get
train
public static appfwpolicylabel_stats get(nitro_service service, String labelname) throws Exception{ appfwpolicylabel_stats obj = new appfwpolicylabel_stats(); obj.set_labelname(labelname); appfwpolicylabel_stats response = (appfwpolicylabel_stats) obj.stat_resource(service); return response; }
java
{ "resource": "" }
q10476
nsfeature.enable
train
public static base_response enable(nitro_service client, nsfeature resource) throws Exception { nsfeature enableresource = new nsfeature(); enableresource.feature = resource.feature; return enableresource.perform_operation(client,"enable"); }
java
{ "resource": "" }
q10477
nsfeature.disable
train
public static base_response disable(nitro_service client, nsfeature resource) throws Exception { nsfeature disableresource = new nsfeature(); disableresource.feature = resource.feature; return disableresource.perform_operation(client,"disable"); }
java
{ "resource": "" }
q10478
nsfeature.get
train
public static nsfeature get(nitro_service service) throws Exception{ nsfeature obj = new nsfeature(); nsfeature[] response = (nsfeature[])obj.get_resources(service); return response[0]; }
java
{ "resource": "" }
q10479
nsrpcnode.update
train
public static base_response update(nitro_service client, nsrpcnode resource) throws Exception { nsrpcnode updateresource = new nsrpcnode(); updateresource.ipaddress = resource.ipaddress; updateresource.password = resource.password; updateresource.srcip = resource.srcip; updateresource.secure = resource.secure; return updateresource.update_resource(client); }
java
{ "resource": "" }
q10480
nsrpcnode.update
train
public static base_responses update(nitro_service client, nsrpcnode resources[]) throws Exception { base_responses result = null; if (resources != null && resources.length > 0) { nsrpcnode updateresources[] = new nsrpcnode[resources.length]; for (int i=0;i<resources.length;i++){ updateresources[i] = new nsrpcnode(); updateresources[i].ipaddress = resources[i].ipaddress; updateresources[i].password = resources[i].password; updateresources[i].srcip = resources[i].srcip; updateresources[i].secure = resources[i].secure; } result = update_bulk_request(client, updateresources); } return result; }
java
{ "resource": "" }
q10481
nsrpcnode.unset
train
public static base_response unset(nitro_service client, nsrpcnode resource, String[] args) throws Exception{ nsrpcnode unsetresource = new nsrpcnode(); unsetresource.ipaddress = resource.ipaddress; return unsetresource.unset_resource(client,args); }
java
{ "resource": "" }
q10482
nsrpcnode.unset
train
public static base_responses unset(nitro_service client, String ipaddress[], String args[]) throws Exception { base_responses result = null; if (ipaddress != null && ipaddress.length > 0) { nsrpcnode unsetresources[] = new nsrpcnode[ipaddress.length]; for (int i=0;i<ipaddress.length;i++){ unsetresources[i] = new nsrpcnode(); unsetresources[i].ipaddress = ipaddress[i]; } result = unset_bulk_request(client, unsetresources,args); } return result; }
java
{ "resource": "" }
q10483
nsrpcnode.get
train
public static nsrpcnode[] get(nitro_service service) throws Exception{ nsrpcnode obj = new nsrpcnode(); nsrpcnode[] response = (nsrpcnode[])obj.get_resources(service); return response; }
java
{ "resource": "" }
q10484
nsrpcnode.get
train
public static nsrpcnode get(nitro_service service, String ipaddress) throws Exception{ nsrpcnode obj = new nsrpcnode(); obj.set_ipaddress(ipaddress); nsrpcnode response = (nsrpcnode) obj.get_resource(service); return response; }
java
{ "resource": "" }
q10485
nsrpcnode.get
train
public static nsrpcnode[] get(nitro_service service, String ipaddress[]) throws Exception{ if (ipaddress !=null && ipaddress.length>0) { nsrpcnode response[] = new nsrpcnode[ipaddress.length]; nsrpcnode obj[] = new nsrpcnode[ipaddress.length]; for (int i=0;i<ipaddress.length;i++) { obj[i] = new nsrpcnode(); obj[i].set_ipaddress(ipaddress[i]); response[i] = (nsrpcnode) obj[i].get_resource(service); } return response; } return null; }
java
{ "resource": "" }
q10486
GeneralizedCounter.totalCount
train
public double totalCount() { if (depth() == 1) { return total; // I think this one is always OK. Not very principled here, though. } else { double result = 0.0; for (K o: topLevelKeySet()) { result += conditionalizeOnce(o).totalCount(); } return result; } }
java
{ "resource": "" }
q10487
GeneralizedCounter.printKeySet
train
private void printKeySet() { Set<?> keys = keySet(); System.out.println("printing keyset:"); for (Object o: keys) { //System.out.println(Arrays.asList((Object[]) i.next())); System.out.println(o); } }
java
{ "resource": "" }
q10488
autoscalepolicy_binding.get
train
public static autoscalepolicy_binding get(nitro_service service, String name) throws Exception{ autoscalepolicy_binding obj = new autoscalepolicy_binding(); obj.set_name(name); autoscalepolicy_binding response = (autoscalepolicy_binding) obj.get_resource(service); return response; }
java
{ "resource": "" }
q10489
AbstractTreebankLanguagePack.isLabelAnnotationIntroducingCharacter
train
public boolean isLabelAnnotationIntroducingCharacter(char ch) { char[] cutChars = labelAnnotationIntroducingCharacters(); for (char cutChar : cutChars) { if (ch == cutChar) { return true; } } return false; }
java
{ "resource": "" }
q10490
MtasExtendedTermSpans.getPositions
train
public int[] getPositions() { int[] list; if (assumeSinglePosition) { list = new int[1]; list[0] = super.startPosition(); return list; } else { try { processEncodedPayload(); list = mtasPosition.getPositions(); if (list != null) { return mtasPosition.getPositions(); } } catch (IOException e) { log.debug(e); // do nothing } int start = super.startPosition(); int end = super.endPosition(); list = new int[end - start]; for (int i = start; i < end; i++) list[i - start] = i; return list; } }
java
{ "resource": "" }
q10491
MtasExtendedTermSpans.processEncodedPayload
train
private void processEncodedPayload() throws IOException { if (!readPayload) { payloadSpanCollector.reset(); collect(payloadSpanCollector); Collection<byte[]> originalPayloadCollection = payloadSpanCollector .getPayloads(); if (originalPayloadCollection.iterator().hasNext()) { byte[] payload = originalPayloadCollection.iterator().next(); if (payload == null) { throw new IOException("no payload"); } MtasPayloadDecoder payloadDecoder = new MtasPayloadDecoder(); payloadDecoder.init(startPosition(), payload); mtasPosition = payloadDecoder.getMtasPosition(); } else { throw new IOException("no payload"); } } }
java
{ "resource": "" }
q10492
CRFBiasedClassifier.main
train
public static void main(String[] args) throws Exception { System.err.println("CRFBiasedClassifier invoked at " + new Date() + " with arguments:"); for (String arg : args) { System.err.print(" " + arg); } System.err.println(); Properties props = StringUtils.argsToProperties(args); CRFBiasedClassifier crf = new CRFBiasedClassifier(props); String testFile = crf.flags.testFile; String loadPath = crf.flags.loadClassifier; if (loadPath != null) { crf.loadClassifierNoExceptions(loadPath, props); } else if (crf.flags.loadJarClassifier != null) { crf.loadJarClassifier(crf.flags.loadJarClassifier, props); } else { crf.loadDefaultClassifier(); } if(crf.flags.classBias != null) { StringTokenizer biases = new java.util.StringTokenizer(crf.flags.classBias,","); while (biases.hasMoreTokens()) { StringTokenizer bias = new java.util.StringTokenizer(biases.nextToken(),":"); String cname = bias.nextToken(); double w = Double.parseDouble(bias.nextToken()); crf.setBiasWeight(cname,w); System.err.println("Setting bias for class "+cname+" to "+w); } } if (testFile != null) { DocumentReaderAndWriter readerAndWriter = crf.makeReaderAndWriter(); if (crf.flags.printFirstOrderProbs) { crf.printFirstOrderProbs(testFile, readerAndWriter); } else if (crf.flags.printProbs) { crf.printProbs(testFile, readerAndWriter); } else if (crf.flags.useKBest) { int k = crf.flags.kBest; crf.classifyAndWriteAnswersKBest(testFile, k, readerAndWriter); } else { crf.classifyAndWriteAnswers(testFile, readerAndWriter); } } }
java
{ "resource": "" }
q10493
dnspolicy_dnsglobal_binding.get
train
public static dnspolicy_dnsglobal_binding[] get(nitro_service service, String name) throws Exception{ dnspolicy_dnsglobal_binding obj = new dnspolicy_dnsglobal_binding(); obj.set_name(name); dnspolicy_dnsglobal_binding response[] = (dnspolicy_dnsglobal_binding[]) obj.get_resources(service); return response; }
java
{ "resource": "" }
q10494
snmpuser.add
train
public static base_response add(nitro_service client, snmpuser resource) throws Exception { snmpuser addresource = new snmpuser(); addresource.name = resource.name; addresource.group = resource.group; addresource.authtype = resource.authtype; addresource.authpasswd = resource.authpasswd; addresource.privtype = resource.privtype; addresource.privpasswd = resource.privpasswd; return addresource.add_resource(client); }
java
{ "resource": "" }
q10495
snmpuser.add
train
public static base_responses add(nitro_service client, snmpuser resources[]) throws Exception { base_responses result = null; if (resources != null && resources.length > 0) { snmpuser addresources[] = new snmpuser[resources.length]; for (int i=0;i<resources.length;i++){ addresources[i] = new snmpuser(); addresources[i].name = resources[i].name; addresources[i].group = resources[i].group; addresources[i].authtype = resources[i].authtype; addresources[i].authpasswd = resources[i].authpasswd; addresources[i].privtype = resources[i].privtype; addresources[i].privpasswd = resources[i].privpasswd; } result = add_bulk_request(client, addresources); } return result; }
java
{ "resource": "" }
q10496
snmpuser.update
train
public static base_response update(nitro_service client, snmpuser resource) throws Exception { snmpuser updateresource = new snmpuser(); updateresource.name = resource.name; updateresource.group = resource.group; updateresource.authtype = resource.authtype; updateresource.authpasswd = resource.authpasswd; updateresource.privtype = resource.privtype; updateresource.privpasswd = resource.privpasswd; return updateresource.update_resource(client); }
java
{ "resource": "" }
q10497
snmpuser.update
train
public static base_responses update(nitro_service client, snmpuser resources[]) throws Exception { base_responses result = null; if (resources != null && resources.length > 0) { snmpuser updateresources[] = new snmpuser[resources.length]; for (int i=0;i<resources.length;i++){ updateresources[i] = new snmpuser(); updateresources[i].name = resources[i].name; updateresources[i].group = resources[i].group; updateresources[i].authtype = resources[i].authtype; updateresources[i].authpasswd = resources[i].authpasswd; updateresources[i].privtype = resources[i].privtype; updateresources[i].privpasswd = resources[i].privpasswd; } result = update_bulk_request(client, updateresources); } return result; }
java
{ "resource": "" }
q10498
snmpuser.get
train
public static snmpuser[] get(nitro_service service, options option) throws Exception{ snmpuser obj = new snmpuser(); snmpuser[] response = (snmpuser[])obj.get_resources(service,option); return response; }
java
{ "resource": "" }
q10499
snmpuser.get
train
public static snmpuser get(nitro_service service, String name) throws Exception{ snmpuser obj = new snmpuser(); obj.set_name(name); snmpuser response = (snmpuser) obj.get_resource(service); return response; }
java
{ "resource": "" }