query stringlengths 8 1.54M | document stringlengths 9 312k | negatives listlengths 19 20 | metadata dict |
|---|---|---|---|
loads the theme as a thread based on SharedPreferences, used before onCreate() doesn't work if used after | public void loadTheme() {
runOnUiThread(new Runnable() {
public void run() {
try {
//inspired by:https://stackoverflow.com/questions/15025369/changing-the-theme-of-an-android-app-using-preferences
SharedPreferences data = getSharedPreferences("... | [
"public void loadTheme() {\n runOnUiThread(new Runnable() {\n public void run() {\n try {\n //inspired by:https://stackoverflow.com/questions/15025369/changing-the-theme-of-an-android-app-using-preferences\n prefTheme = getSharedPreferences(\"Th... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
$ANTLR end "ruleOpMultiAssign" $ANTLR start "entryRuleXOrExpression" ../de.nie.fin.ui/srcgen/de/nie/fin/ui/contentassist/antlr/internal/InternalFin.g:429:1: entryRuleXOrExpression : ruleXOrExpression EOF ; | public final void entryRuleXOrExpression() throws RecognitionException {
try {
// ../de.nie.fin.ui/src-gen/de/nie/fin/ui/contentassist/antlr/internal/InternalFin.g:430:1: ( ruleXOrExpression EOF )
// ../de.nie.fin.ui/src-gen/de/nie/fin/ui/contentassist/antlr/internal/InternalFin.g:431... | [
"public final void entryRuleXOrExpression() throws RecognitionException {\r\n try {\r\n // ../org.xtext.example.rmodp.ui/src-gen/org/xtext/example/rmodp/ui/contentassist/antlr/internal/InternalRmOdp.g:1970:1: ( ruleXOrExpression EOF )\r\n // ../org.xtext.example.rmodp.ui/src-gen/org/xte... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Constructs a PlayException with the given message | public PlayException(String message) {
super(message);
} | [
"public EkudException(String message) {\n super(message);\n this.message = message;\n }",
"public InvalidPlayExcepcion(String msg) {\n super(msg);\n }",
"public notHumanBeingException(String message){// Message parameted created\n super(message);\n \n }",
"public Ga... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
This method sets the type of parent container. The parent container determines whether sibling (for folders) or child nodes (for document/section/tasks) are used to further partition a document. | public void setParentContainerType(IPartitionType type)
{
this.parentContainerType = (PartitionType) type;
} | [
"public void setParent(Container container);",
"public void setParentType(String type) {\n this.parentType = type;\n }",
"public void setParentType(java.lang.Object parentType) {\n this.parentType = parentType;\n }",
"void setParentContainer(IComponentNodeContainerModel parentContainer);",
"pu... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Perform a validation in the add method | private void performValidateAdd() {
if (topic == null) {
addActionError(getText("topic.input.validation.required"));
}
// verifies if the title is empty
if (!StringUtils.hasText(topic.getTitle())) {
addActionError(getText("topic.input.validation.title"));
... | [
"@Override\n \tpublic void validate() {\n \t}",
"public void tryAdd() {\r\n\t\tif (isDataModified()) {\r\n\t\t\tscrollToMe();\r\n if (getValidator().getUseAlertsForErrors()) {\r\n addConfirmScript(_okToAddQuestion, _okToAddValue);\r\n }\r\n else {\r\n ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Compiles a given Simple Pascal string into an ILOC program. | public Program compile(String text) throws ParseException {
return compile(parse(text));
} | [
"public String compile(byte[] code);",
"C compile( String expression, C compiled );",
"public Program loadCodes() {\r\n\r\n Program program = new Program();\r\n ArrayList<String> args = new ArrayList<String>();\r\n\r\n ByteCode code;\r\n\r\n try {\r\n String line = byteSou... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
setAutoCommit Set AutoCommit for Window | public static void setAutoCommit (Properties ctx, int WindowNo, boolean autoCommit)
{
if (ctx == null)
return;
ctx.setProperty(WindowNo+"|AutoCommit", autoCommit ? "Y" : "N");
} | [
"public void setAutoCommit(boolean flag) {\n // TODO Auto-generated method stub\n }",
"public void setAutoCommit(boolean flag) {\n }",
"public void setAutoCommit (int value) {\n this.autoCommit = value;\n }",
"void setDefaultAutoCommit(boolean defaultAutoCommit);",
"public void setAutoCommitM... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Adds a bound for the given skolem relation to this.bounds, and returns the expression that should replace skolemDecl.variable in the final formula. | private Expression skolemExpr(Decl skolemDecl, Relation skolem) {
final int depth = nonSkolems.size();
final int arity = depth + skolemDecl.variable().arity();
Expression skolemExpr = skolem;
Environment<BooleanMatrix,Expression> skolemEnv = Environment.empty();
for (DeclInfo info : nonSkolems) {
if (inf... | [
"public LinearConstraint putVariable(Object var, Double value) {\n constraints.put(var, value);\n return this;\n }",
"@Override\n BooleanExpression boundVar(String name, boolean fresh);",
"boolean isBoundVariable(Formula f);",
"Binding newBinding(Variable var, AST ast, EvalVisitor ev);",
"... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Sets the value of the numCoresPerSocketVm property. | public void setNumCoresPerSocketVm(int value) {
this.numCoresPerSocketVm = value;
} | [
"public int getNumCoresPerSocketVm() {\r\n return numCoresPerSocketVm;\r\n }",
"public void setNumCores(int numCores_) {\n this.numCores = numCores_;\n }",
"public void setNumCpuCores(int value) {\r\n this.numCpuCores = value;\r\n }",
"@Public\n @Evolving\n public abstract void... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Create a classification composite stage. | public ClassificationCompositeStage(final Configuration configuration) throws ConfigurationException {
/** Instantiate configurable objects/properties for stages */
/**
* Create Clock. Default value of -1 was selected because the method getLongProperty states
* it will return "null" i... | [
"public static Classification composition(Classification stage1, Classification stage2, ClassificationModel model) {\n Classification composedClassification = ClassificationFactory.eINSTANCE.createClassification();\n\n List<ClassifiedFeature> allClassifiedFeaturesOfStage1 = getAllClassifiedFeaturesOfView(... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
true if item is in the inventory | boolean isInInventory(IEquipableItem item); | [
"public boolean isInInventory(String item) {\n return this.inventory.isItemInInventory(item);\n }",
"boolean isEquipped(Item item);",
"public boolean containItem(String name) {\r\n for (Item i : inventoryItems) {\r\n if (i.getName() == name) {\r\n return true;\r\n }\r\n }\r\n ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Match this filter against an Intent's action. If the filter does not specify any actions, the match will always fail. | public final boolean matchAction(String action) {
return hasAction(action);
} | [
"private boolean matchesIntent(PrismObject<ShadowType> shadow) {\n return intent == null || intent.equals(ShadowUtil.getIntent(shadow));\n }",
"@Test\n public void makeAppModeIntentFilter() {\n int nbrActions = 0;\n ArrayList<String> actionList = getAppModeActions();\n\n IntentFi... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
remove WhiteSpace from MIME containing encoded Base64 data. e.g. " sdffferererrereresfsdfsdfsdff\n\r iiiiiiiiierejrlkwjerklwjerwerwr==\n\r" | public static synchronized byte[] removeWhiteSpace( byte[] data ) {
if (data == null)
return null;
int newSize = 0;
int len = data.length;
int i =0;
for (; i<len; i++) {
if (!isWhiteSpace( data[i] ))
newSize++;
}
if (n... | [
"public String cleanBody (String body){\n if (!body.startsWith(\"message=\")){\n return body.strip();\n }\n\n /**\n * the body we get is in the format message=something\n * we do not need the message= string, so we remove that over here\n */\n LOGGER.in... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Returns a Set of Abilities with the given ID. | public Set<Modifier> getModifierSet(String id) {
return getModifierSet(id, null, null);
} | [
"public Set<Ability> getAbilitySet(String id) {\n return getAbilitySet(id, null, null);\n }",
"public Set<Ability> getAbilitySet(String id, FreeColGameObjectType objectType) {\n return getAbilitySet(id, objectType, null);\n }",
"public Set<Ability> getAbilitySet(String id, FreeColGameObj... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Retrieve all HeartRateSamples stored in the database. | @SuppressWarnings("unchecked")
public List<HeartRateSample> getHeartRateSamples() {
LOG.info("get all heart rate samples");
return this.session.createQuery("FROM HeartRateSample").getResultList();
} | [
"public int deleteAllHeartRateSamples() {\r\n LOG.info(\"delete all heart rate samples\");\r\n return this.session.createQuery(\"DELETE FROM HeartRateSample\").executeUpdate();\r\n }",
"@SuppressWarnings(\"unchecked\")\r\n public List<CC2650HumiditySample> getCC2650HumiditySamples() {\r\n LOG.info(\"ge... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Gets the find by id data set schema. | DataSetSchema getfindByIdDataSetSchema(@DatasetId Long datasetId, ObjectId datasetSchemaId)
throws EEAException; | [
"DocumentSet findDocumentSet(String id);",
"public DataSet findDataSet(Long id) {\n EntityManager em = getEntityManager();\n try {\n return em.find(DataSet.class, id);\n } finally {\n em.close();\n }\n }",
"public <R extends SqlNode<R>>R findById(String id){\... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
function bodyToString join all parts of body and return one string | public static String bodyToString(String[] arr){
StringBuilder value = new StringBuilder("");
for(int i = 0 ; i < arr.length ; i++) {
value.append(arr[i]).append(" ");
}
return value.toString();
} | [
"public String getBodyAsText() {\n\t\tInputStream inputStream = exchange.getRequestBody();\n\n\t\tString text = new BufferedReader(\n\t\t\t\tnew InputStreamReader(inputStream, StandardCharsets.UTF_8))\n\t\t\t\t.lines()\n\t\t\t\t.collect(Collectors.joining(\"\\n\"));\n\n\t\treturn text;\n\t}",
"public String encod... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
If the clear view height, i.e. without top/bottom padding, is greater than the drawable height the drawable should be centered vertically by adding additional vertical top/bottom padding. | private void calculateDrawableBounds(int height, @NonNull Drawable drawable)
{
int clearHeight = height - getPaddingTop() - getPaddingBottom();
int vPad = 0;
if (clearHeight > drawable.getIntrinsicHeight())
vPad = (clearHeight - drawable.getIntrinsicHeight()) / 2;
mDrawableBounds.set(getPaddingL... | [
"public void alignBorderEveryTime() {\n ViewGroup.LayoutParams params = getMainUpView().getLayoutParams();\n if (params.width != mFinalWidth || params.height != mFinalHeight) {\n params.width = mFinalWidth;\n params.height = mFinalHeight;\n getMainUpView().requestLayou... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
This is for System>go rally project delete Go to project rally edit page | public String doRallyDelete(){
try {
projectRallyQuix = projectService.getProjectRallyQuixById(rallyNameIdAry[0]);
projectRallyQuix.setIsValid(1);
projectId = projectRallyQuix.getProjectId();
projectService.doProjectAddRally(projectRallyQuix);
} catch (BaseException e) {
e.printStackTrace();
}
se... | [
"public void deleteCurrentProject();",
"public void deleteProject(Project p);",
"public void deleteProject(ActionRequest actionRequest,ActionResponse actionResponse) throws SystemException\n\t{\n\t\t long projectId = ParamUtil.getLong(actionRequest, \"projectId\");\n\t\t \n\t\t \n\t\t //to delete project we nee... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Defines the outstring (outstr) (if the actual number can be divided by 3 outstr equals to "fizz" if it can be divided by 5 its value is "buzz" if it can be divided by both of these numbers it equals to "fizzbuzz". In other cases its value is the number in string type). These values are added to the result list. | private void procNum(){
if (act_num%15==0){
//System.out.println(fizz+buzz);
outstr="fizzbuzz";
}
else if (act_num%3==0){
//System.out.println(fizz);
outstr="fizz";
}
else if (act_num%5==0){
//System.out.println(buzz);
outstr="buzz";
}
else{ //System.out.println(act_num);
//String act... | [
"public static String getValue(int input) {\n\n if (input < 1 || input >100)\n throw new RuntimeException(\"Range must be greater than 1 \" + \" less than or equal 100\");\n String result = \"\";\n if (input % 3 == 0) ;\n result += \"Fizz\";\n if (input % 5 == 0)\n ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
method to process the steps buffer | public synchronized void processStepBuffer(){
Step s;
Unit u = null;
if((step_pos+1) < steps.size() || finalInvPos != -1){
if(this.crash) return;
if(finalInvPos == -1)
step_pos++;
if(step_pos+1 > steps.size()) step_pos = steps.size() - 1;
if(step_pos < 0) step_pos = 0;
s = steps.... | [
"@Override\n public void run() {\n if (_delayMs == 0) ConsoleWriteLine(\"SINGLE STEP MODE - PRESS ENTER TO PROGRESS\\r\\n\");\n\n int counter = 0;\n int totalPlanes = _display.GetPlanes().size();\n\n //position of all trains is held in the display instance (grid view)\n String... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
newBook Method sets the attributes for the book. | private void newBook(){
this.id=BookManager.books.size();
setName(askName());
setAuthor(askAuthor());
} | [
"public void setAttributes(Book book) {\n this.setLINECOUNTFIELD(book);\n this.setWORDCOUNTFIELD(book);\n this.setWordArea(book);\n }",
"public Book createBook(Book newBook) {\n\t\treturn this.sRepo.save(newBook);\n\t}",
"public void setBook(Book book) {\n setBook(book, false, fal... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
/ Create stream handler. | public StreamHandler createStreamHandler (OutputStream outStream) {
StreamHandler streamHandler = null;
try {
streamHandler = new StreamHandler(outStream, new SimpleFormatter());
} catch (SecurityException e) {
e.printStackTrace();
}
return streamHan... | [
"Handler createHandler();",
"public interface IStreamHandler<T> {\n\t\n\t@FunctionalInterface\n\tpublic static interface Writer<T> {\n\t\tpublic void write(OutputStream os, T obj) throws IOException;\n\t}\n\t\n\t@FunctionalInterface\n\tpublic static interface Reader<T> {\n\t\tpublic T read(InputStream is) throws ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
This method was generated by MyBatis Generator. This method sets the value of the database column report.trade_success | public void setTradeSuccess(Integer tradeSuccess) {
this.tradeSuccess = tradeSuccess;
} | [
"public Integer getTradeSuccess() {\n return tradeSuccess;\n }",
"public void setSuccess(Boolean success) {\n \tthis.success = success;\n }",
"public void setSuccess(boolean success)\n {\n synchronized (monitor())\n {\n check_orphaned();\n org.apache.xmlbea... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Use the variance (V) to tune the entropy of the hot object set H See Peter's paper: "Characterizing, Modeling, and Generating Workload Spikes for Stateful Services, in SOCC '10: Symposium on Cloud Computing, ACM, 2010" for more details. | @SuppressWarnings("unused")
public static void main( String[] args )
{
ArrayList<Double> alpha = new ArrayList<Double>();
int N = 200; // 100 hot objects
double low_variance = 1e-10; // All hot objects equally popular (entropy ~1)
double mid_variance = 0.0045; // Some skew
double high_variance = 0.5; // ... | [
"StateVector filter(Vec H, double V) {\n // H = prediction matrix (5-vector)\n // V = hit variance (1/sigma^2)\n\n StateVector aPrime = copy();\n aPrime.kUp = kLow;\n\n double denom = V + H.dot(H.leftMultiply(C));\n Vec K = H.leftMultiply(C).scale(1.0 / denom); // Kalman ga... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Gets the "posList" element | public net.opengis.gml.x32.DirectPositionListType getPosList()
{
synchronized (monitor())
{
check_orphaned();
net.opengis.gml.x32.DirectPositionListType target = null;
target = (net.opengis.gml.x32.DirectPositionListType)get_store().find_el... | [
"DirectPositionListType getPosList();",
"java.util.List<ru.chuprikov.search.datatypes.Datatypes.Posting.Position> \n getPositionsList();",
"@NotNull\n @SubTag(\"Positions\")\n\tGenericDomValue<String> getPositions();",
"public List<Double> getXPosList()\n\t{\n\t\treturn this.xPosList;\n\t}",
"publ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
$ANTLR end "rule__EDataType__Group__1__Impl" $ANTLR start "rule__EDataType__Group__2" InternalAADMParser.g:6451:1: rule__EDataType__Group__2 : rule__EDataType__Group__2__Impl rule__EDataType__Group__3 ; | public final void rule__EDataType__Group__2() throws RecognitionException {
int stackSize = keepStackSize();
try {
// InternalAADMParser.g:6455:1: ( rule__EDataType__Group__2__Impl rule__EDataType__Group__3 )
// InternalAADMParser.g:6456:2: rule__EDataType__Group__2_... | [
"public final void rule__EMAP__Group__2__Impl() throws RecognitionException {\n\n \t\tint stackSize = keepStackSize();\n \t\n try {\n // InternalAADMParser.g:19644:1: ( ( RULE_END ) )\n // InternalAADMParser.g:19645:1: ( RULE_END )\n {\n // InternalAA... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Returns the email reminder ID of this email reminder. | @Override
public long getEmailReminderId() {
return _emailReminder.getEmailReminderId();
} | [
"public long getEmailReminderId();",
"public String getReminderId() {\n return reminderId;\n }",
"public native String getId() /*-{\n\t\treturn this.@com.pmt.wrap.titanium.android.calendar.Reminder::handler.id;\n\t}-*/;",
"@Override\n\tpublic int getReminderNumber() {\n\t\treturn _emailReminder.getR... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Liefert true, wenn die Mainloop beendet werden soll, weil keine Clients mehr da sind. | private boolean checkClientsLeft() {
// Noch Clients da?
if (hadClients) {
if (Server.game.clients.isEmpty()) {
System.out.println("No clients left, shutting server down.");
return true;
}
} else {
// Jetzt welche da?
... | [
"public boolean alwaysRun() {\n return false;\n }",
"@Override\n public boolean isRunning() {\n if (lumenClient == null || spine == null || !spine.isRunning()) {\n return false;\n } else {\n return true;\n }\n }",
"@Override\n\tpublic boolean isClient()... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
3. Write a static method called charArraySorted. This method takes in an array of characters and it returns a boolean. The method returns true if the character array is in alphabetical order and false otherwise (You can compare characters just like integers) | static boolean charArraySorted(char[] characters) {
boolean alphabetical = true;
for(int i = 0;i<characters.length-1;i++) {
if(characters[i] < characters[i+1]) {
continue;
}
else {
alphabetical = false;
break;
}
}
return alphabetical;
} | [
"static boolean charArraySorted(char[] charArray) {\n\t\tfor (int i = 0; i < charArray.length - 1; i++) {\n\t\t\tc = charArray[i];\n//\t\t\tif (charArray[i + 1] < k) {\n//\t\t\t\treturn false;\n//\t\t\t}\n\t\t}\n\t\treturn true;\n\t}",
"static boolean charArraySorted(char[] carray) {\n\t\tfor (int i = 0; i + 1 < ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Asynchronously scans the classpath for matching files, and if runAsynchronously is true, also calls any MatchProcessors if a match is identified. | private Future<ScanResult> scanAsync(final ExecutorService executorService, final int numParallelTasks,
final boolean isAsyncScan, final boolean runMatchProcessorsOnWorkerThread) {
return launchAsyncScan(executorService, numParallelTasks, isAsyncScan,
runMatchProcessorsOnWorkerThread... | [
"public ArrayList<String> call() {\n\t\t\treturn grepMultiThreadExecute(file, pattern, start, end);\n\t\t}",
"public FastClasspathScanner matchAllClasses(final ClassMatchProcessor classMatchProcessor) {\n getScanSpec().matchAllClasses(classMatchProcessor);\n return this;\n }",
"private Future<S... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
This method was generated by MyBatis Generator. This method returns the value of the database column T_SB_ZWYC_ZSZHHGQ.SSDS | public String getSsds() {
return ssds;
} | [
"public Long getDlsbsdsj() {\n return dlsbsdsj;\n }",
"public String getSskxxd() {\n return sskxxd;\n }",
"public String getSsdsmc() {\n return ssdsmc;\n }",
"public java.lang.String getSds() {\r\n return sds;\r\n }",
"@Column(name = \"EIN_SS\")\n\tpublic String getEinSs... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Gets the value of the setRegisterValue property. | public byte[] getSetRegisterValue() {
return setRegisterValue;
} | [
"public String getRegister() {\n return register;\n }",
"public int getRegister() {\n return register;\n }",
"public String getRegistryValue() {\n return registryValue;\n }",
"public String getIsRegister() {\n return isRegister;\n }",
"public String getRegisterId() {\... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
$ANTLR end "entryRuleDomainSpec" $ANTLR start "ruleDomainSpec" InternalSymboleoide.g:87:1: ruleDomainSpec : ( ( rule__DomainSpec__Group__0 ) ) ; | public final void ruleDomainSpec() throws RecognitionException {
int stackSize = keepStackSize();
try {
// InternalSymboleoide.g:91:2: ( ( ( rule__DomainSpec__Group__0 ) ) )
// InternalSymboleoide.g:92:2: ( ( rule__DomainSpec__Group__0 ) )
{
/... | [
"public final void rule__DomainSpec__Group__0__Impl() throws RecognitionException {\n\n \t\tint stackSize = keepStackSize();\n \t\n try {\n // InternalSymboleoide.g:2069:1: ( ( 'Domain' ) )\n // InternalSymboleoide.g:2070:1: ( 'Domain' )\n {\n // Inte... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
takes a specific customer and moves them outside the store | public void exitCustomer(int i)
{
customers.add(inStore.get(i));
inStore.remove(i);
} | [
"public void checkout(Customer customer, Order order){\n final int cost = order.getCost();\n if(customer.charge(cost)){\n inventory.remove(order.size());\n }\n }",
"private void giveFoodToCustomer(MyCustomer customer) {\n\tDo(\"Giving finished order of \" + customer.choice +\" t... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Test of getType method, of class org.netbeans.modules.vmd.api.model.PropertyValue. | public void testGetType() {
System.out.println("getType"); // NOI18N
TypeID expResult;
TypeID result;
String value = "Test value"; // NOI18N
TypeID type = new TypeID(TypeID.Kind.PRIMITIVE, "javacode");// NOI18N
result = PropertyValue.createValue(primitve... | [
"public void test_getType() {\n assertEquals(\"'type' value should be properly retrieved.\", type, instance.getType());\n }",
"public String getPropertyType();",
"io.prodrink.catalog.generated.domain.PropertyType getPropertyType();",
"Class<?> getPropertyType();",
"PropertyType getType();",
"pub... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Returns the information for the staff with given Id This function is for getting the staff record for a given record_id | public static Staff viewStaff(Integer id){
try {
Connection conn = DatabaseConnection.getConnection();
Statement st = conn.createStatement();
ResultSet rs = st.executeQuery("SELECT * FROM Staff WHERE staff_id =" + id);
Staff s = new Staff();
while(rs.next()) {
s.setAddress(rs.getStr... | [
"public Staff getStaffByID(String StaffID);",
"public String getStaffId() {\n return staffId;\n }",
"public Map<String, String> getStaffRowById(int id) {\n String rowIndex = String.valueOf(getRowIndexById(id));\n String xpathRow = xpathTableCell.replace(\"*row*\", rowIndex);\n ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Is a page available before the current page?. | public boolean isPreviousPageAvailable(); | [
"public boolean hasRequestedPage() {\n return getPageIdx() < getPageList().size();\n }",
"public boolean isPageLoaded(){\n String currentURL = \"search\";\n String currentTitle = \"Google\";\n return isPageLoaded(currentURL, currentTitle, number2PageBottomBold);\n }",
"public boolean... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Internal functions Allocate and initialize marginal arrays and variables. Assumes that n_vars and n_values are already set up. Note: Variables and array elements that contain a maximum are initialized to Double.MAX_VALUE; those that contain a sum are initialized to 0.0; and those that contain an index are initialized t... | private void alloc_marginal () {
peak_probability = -Double.MAX_VALUE;
peak_indexes = new int[n_vars];
for (int n = 0; n < n_vars; ++n) {
peak_indexes[n] = -1;
}
total_probability = 0.0;
marginal_probability = new double[n_vars][];
for (int n = 0; n < n_vars; ++n) {
marginal_probability[n] = ne... | [
"private void finish_marginal () {\n\n\t\t// Calculate the modes\n\n\t\tfor (int n = 0; n < n_vars; ++n) {\n\t\t\tint[] j = new int[1];\n\t\t\tOEArraysCalc.find_array_max (marginal_probability[n], j);\n\t\t\tmarginal_mode_index[n] = j[0];\n\t\t}\n\n\t\t// Calculate the 2D modes\n\n\t\tfor (int n1 = 0; n1 < n_vars; ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
$ANTLR end "ruleSystem" $ANTLR start "entryRuleNode" InternalSPDSL.g:160:1: entryRuleNode returns [EObject current=null] : iv_ruleNode= ruleNode EOF ; | public final EObject entryRuleNode() throws RecognitionException {
EObject current = null;
EObject iv_ruleNode = null;
try {
// InternalSPDSL.g:160:45: (iv_ruleNode= ruleNode EOF )
// InternalSPDSL.g:161:2: iv_ruleNode= ruleNode EOF
{
newCompos... | [
"public final EObject entryRuleNode() throws RecognitionException {\n EObject current = null;\n\n EObject iv_ruleNode = null;\n\n\n try {\n // InternalDasl.g:412:45: (iv_ruleNode= ruleNode EOF )\n // InternalDasl.g:413:2: iv_ruleNode= ruleNode EOF\n {\n ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Sets the secondaries value for this FaultTolerancePrimaryConfigInfo. | public void setSecondaries(
com.vmware.vim25.ManagedObjectReference[] secondaries) {
this.secondaries = secondaries;
} | [
"public void setSecondary(String secondary) {\n this.secondary = check(secondary);\n }",
"public void setSecondary(boolean secondary)\r\n\t{\tthis.secondary = secondary;\t}",
"public void setPrimaryOrSecondary(String primaryOrSecondary) {\n\t\tthis.primaryOrSecondary = primaryOrSecondary;\n\t}",
"pu... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
This is a method to add a card to the end of storage cards | public void addCard(Card cardToAdd) {
storageCards.add(cardToAdd);
} | [
"public void addCard() {\n\t\tCard newCard = new Card();\n\t\teditCard(newCard);\n\t}",
"public void addCard(Card card){\r\n hand.add(card);\r\n }",
"public void addCard(Card card) {\r\n hand.addCard(card);\r\n }",
"public void addCard(Card card){\n theHand.add(card)... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Gets the list of Effect objects. | @Override
public List<Effect> getEffect() {
return new ArrayList<Effect>(effects);
} | [
"public List<Effect> getEffects() {\n\t\treturn (List<Effect>) Collections.unmodifiableCollection(this.effect);\n\t}",
"public final List<Effect> getEffects()\n {\n return Collections.unmodifiableList(this.effects);\n }",
"public List<Effect> getEffects()\n {\n List<Effect> effectsClone =... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Returns null instead of chosenScaMethod when switching from Embedded to Decoupled approach during SCA method selection as this value should not be provided in the response body according to the specification | @Override
public Xs2aAuthenticationObject getChosenScaMethodForPsd2Response() {
return null;
} | [
"@PostMapping(path=\"/{scaId}/authorisation/{authorisationId}/methods/{methodId}\")\n\t@ApiOperation(value = \"Selects the SCA Method for use.\", authorizations = @Authorization(value = \"apiKey\"))\n\tResponseEntity<AuthorizeResponse> selectMethod(\n\t\t\t@PathVariable(\"scaId\") String scaId,\n\t\t\t@PathVariable... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Removes all the tai khoan doi ungs where taiKhoanDoiUngChaId = &63; and hoatDong = &63; from the database. | @Override
public void removeByTaiKhoanDoiUngChaId_HoatDong(
long taiKhoanDoiUngChaId, Boolean hoatDong) {
for (TaiKhoanDoiUng taiKhoanDoiUng :
findByTaiKhoanDoiUngChaId_HoatDong(
taiKhoanDoiUngChaId, hoatDong, QueryUtil.ALL_POS,
QueryUtil.ALL_POS, null)) {
remove(taiKhoanDoiUng);
}
} | [
"@Override\n\tpublic void removeByHoatDong(Boolean hoatDong) {\n\t\tfor (TaiKhoanDoiUng taiKhoanDoiUng :\n\t\t\t\tfindByHoatDong(\n\t\t\t\t\thoatDong, QueryUtil.ALL_POS, QueryUtil.ALL_POS, null)) {\n\n\t\t\tremove(taiKhoanDoiUng);\n\t\t}\n\t}",
"@Override\n\tpublic void removeByLoaiTaiKhoan_HoatDong(\n\t\tint loa... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
System.out.println(String.format("Setter : %s : %s : %s", columnName, getPropertyUpper(), getPropertyName())); | @JsonIgnore
public String getSetterName() {
return String.format("set%s", getPropertyUpper());
} | [
"@Test\n public void testSetColumnName() {\n writeBanner(getMethodName());\n }",
"public String getSetter() {\n return \"set\" + getCapName();\n }",
"private String findSetterMethodName(String fieldName)\n {\n return \"set\"\n + fieldName.substring(0, 1).toUpperCase(Loc... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Updates the default value of the column in the table with the given tableId. | @Override
public void setColumnDefaultValue(UUID tableId, UUID columnId, Object newDefaultValue) {
if (columnId == null || tableId == null) {
throw new DomainException("Cannot update a column default value with a null id.");
}
Table table = getTable(tableId);
if (table != null) {
table.updateColumnDefaul... | [
"private static void updateTableColumnWithDefaultValue(String tableName, MetaItemField columnMetaInfo) throws DatabaseWrapperOperationException {\t\t\n \t\tString sqlString = \" UPDATE \" + tableName + \n \t\t\t\t\t\t \" SET \" + DatabaseStringUtilities.encloseNameWithQuotes(columnMetaInfo.getName()) + \"=?\";\n ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Creates a list of requests. Only those global options are included that can be sent to server (q, Q, l, t, r, n). To be added to the request list sent to the server. | public List createRequestList() {
List requestList = new LinkedList();
if (variables.size() > 0) {
Iterator it = variables.iterator();
while (it.hasNext()) {
String keyValue = it.next().toString();
requestList.add(new SetRequest(keyValue));
... | [
"public List<RequestInfo> getAllRequests();",
"private void setRequestList()\n {\n try\n {\n requestList = database.loadRequest();\n }\n catch (SQLException e)\n {\n e.printStackTrace();\n }\n\n }",
"RequestsList getRequestsList();",
"Collection<Request> getAl... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
B U S I N E S S M E T H O D S P E R S I S T E N C E M E T H O D S Adds a new planMedioMes to the database. | @TransactionAttribute(TransactionAttributeType.REQUIRED)
public com.spirit.medios.entity.PlanMedioMesIf addPlanMedioMes(com.spirit.medios.entity.PlanMedioMesIf model)
throws com.spirit.exception.GenericBusinessException
{
PlanMedioMesEJB value = new PlanMedioMesEJB();
try {
value.set... | [
"@TransactionAttribute(TransactionAttributeType.REQUIRED)\r\n public void savePlanMedioMes(com.spirit.medios.entity.PlanMedioMesIf model)\r\n throws com.spirit.exception.GenericBusinessException \r\n {\r\n \r\n try\r\n {\r\n PlanMedioMesEJB data = new PlanMedioMesEJB();\r\n data.setI... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Inserts the given Object associated with the given HyperBoundingBox object into the RTree. | public boolean insert( Object obj, HyperBoundingBox box )
throws RTreeException {
try {
Node[] newNodes = new Node[] { null, null };
//Find position for new record
LeafNode node;
node = chooseLeaf( file.readNode( 0 ), box );
... | [
"private void insert (\n Node object,\n Bounds objectBounds,\n double centerX,\n double centerY,\n double centerZ\n ) {\n\n if (this.bounds.contains (centerX, centerY, centerZ))\n insertFirstClass (object, objectBounds, centerX, centerY, centerZ);\n else if (this.bounds.intersects (object... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
se valore da aggiungere all'attuale valore del dado il vecchio prototipo da allineare a tutti quelli troppo lunghi era public MoreThanSimple (String player, int cardIndex, boolean addUp, int iDie) Costruttore che raccoglie i dati singolarmente. | public MoreThanSimple (String player, int cardIndex, boolean addUp, int whichDie){
super(player,cardIndex);
this.die=whichDie;
this.decision=addUp;
} | [
"private void addThreeMoreCards()\n {\n\n }",
"public void createGreedyBag(final Player player) {\r\n List<Goods> greedyLegalGoods = new ArrayList<>();\r\n List<Goods> greedyIllegalGoods = new ArrayList<>();\r\n GoodsComparator goodsComparator = new GoodsComparator();\r\n Colle... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Provides the read "marked row". The closest row is provided if it is not displayed | private MessageRow getReadMarkerMessageRow(MessageRow newMessageRow) {
final String currentReadMarkerEventId = mRoom.getReadMarkerEventId();
MessageRow currentReadMarkerRow = mAdapter.getMessageRow(currentReadMarkerEventId);
if (null == currentReadMarkerRow) {
Event readMarkedEvent ... | [
"long getCellRow();",
"public int getRow()\n\t{\n\t\treturn alligatorRow;\n\t}",
"public abstract int getTopmostRow();",
"public int getRow ()\r\n {\r\n return row;\r\n }",
"public int getMinRow();",
"public int getRow(){\n\t\treturn this.row;\n\t}",
"int getStartRow();",
"public int getF... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
The model is the main component of Choco Solver | public static void main(String[] args) {
Model model = new Model("Graph Antymagic Labeling with Choco Solver");
// Creating new graph
Graph g = new Graph();
List<Vertex> vertices_list = new ArrayList<>();
for (int i = 0; i < 5; i++) {
vertices_list.add(new Vertex(i... | [
"com.google.ortools.linearsolver.MPModelProto getModel();",
"private static void solveModel() {\r\n\t\ttry {\r\n\t\t\t// Solve the model\r\n\t\t\tif (cplex.solve()) {\r\n\t\t\t\t// Print the result\r\n\t\t\t\tSystem.out.println(\"Solution status: \" + cplex.getStatus());\r\n\t\t\t\tSystem.out.println(\"----------... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Method to collect missing arguments from the user in CLI mode. | public void collectMissingArguments(Map inputMap) {
//If no other instructions are to be received, return.
if(inputMap.containsKey(UpgradeConstants.CLI_OPTION_NOPROMPT))
return;
List domainList = commonInfo.getDomainList();
// Following are Invalid Inpu... | [
"protected abstract String[] getCommandLineArguments();",
"private static void checkArgs() throws CmdLineException {\n\t\t// Check argument\n\t\tif (Graph2GraphConfiguration.HELP) {\n\t\t\tthrow new CmdLineException(\"\");\n\t\t}\n\n\t\tboolean isPrintUsage = false;\n\n\t\tif (Graph2GraphConfiguration.INPUT_FILE ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
//this is the link to start the cellHTS2 page main logic | public Object onActionFromStartCellHTS2() {
//TODO:show any errors ajax style
errorNextLink=false;
nextLinkErrorMsg = "";
//all checks befor were no mandantory checks so we will do this now again and more stringent
//step1 check
if (isDualChannel && (channelLabe... | [
"void createPage0() {\n\n\t}",
"@Override\r\n public void run() {\n ax.browserPane.setTitleAt(0,ax.browser.getTitle());\r\n String stringToken1 = null; \r\n try {\r\n stringToken1 = (\"<Navigate Home>::\" + getHome());\r\n } catch (IOException ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Dumps the children of a container box. | public static void dumpBox(Container box) {
log.debug("Dump box: {}", box);
for (Box bx : box.getBoxes()) {
log.debug("{} child: {}", box, bx.getType());
}
} | [
"public void dumpChildren ()\r\n {\r\n dumpChildren(0);\r\n }",
"public Container[] findChildren();",
"public void printChildren(){\n int iteration = 1;\n for(Node node: children){\n System.out.println(iteration + \": Key:\" + node.getValue() + \" Payload: \" + node.getPay... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
GET /companytypes : get all the companyTypes. | @GetMapping("/company-types")
@Timed
public List<CompanyType> getAllCompanyTypes() {
log.debug("REST request to get all CompanyTypes");
List<CompanyType> companyTypes = companyTypeRepository.findAll();
return companyTypes;
} | [
"@ModelAttribute(\"companyTypesList\")\n\tpublic List<CompanyType> companyTypesList() {\n\t\treturn companyService.findAllCompanyType();\n\t}",
"@GetMapping(\"/company-types\")\n @Timed\n public ResponseEntity<List<CompanyType>> getAllCompanyTypes(Pageable pageable) {\n log.debug(\"REST request to ge... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
returns the instance of the PreprocessPanel being used in this instance of the Explorer | public PreprocessPanel getPreprocessPanel() {
return m_PreprocessPanel;
} | [
"public TapProcPanel getProcPanel()\n {\n return procPanel;\n }",
"private JButton getPreProcessButton() {\n\t\tif (preProcessButton == null) {\n\t\t\tpreProcessButton = new JButton();\n\t\t\tpreProcessButton.setBounds(new Rectangle(10, 225, 151, 26));\n\t\t\tpreProcessButton.setText(\"Preprocess\");... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
sets the given constant in the student's classes to the given value, if that value is positive, else sets to the given default value; if no such constant is found, prints an error to the message log | protected void constSetMaybe(String name, double value, Object defaultValue) {
if (value > 0) {
constSet(name, value);
} else {
constSet(name, defaultValue);
}
} | [
"protected void constSetMaybe(String name, int value, Object defaultValue) {\r\n\t\tif (value >= 0) {\r\n\t\t\tconstSet(name, value);\r\n\t\t} else {\r\n\t\t\tconstSet(name, defaultValue);\r\n\t\t}\r\n\t}",
"protected void constSet(String name, Object value) {\r\n\t\tname = name.intern();\r\n\t\tif (ReflectionUti... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Function that tests if the user clicks on adding a cool plant after reading the description. | public boolean whenUserClicksOnAdd(){
// Creating a new AddCool object and calling the appropriate function to test.
AddCool testingButtonFromDescription = new AddCool();
testingButtonFromDescription.callOnCreate();
return testingButtonFromDescription.getAddButtonPressedFlag();
} | [
"public boolean whenUserClickToAddPlant(){\n // Creating a new MainMenuActivity object and calling the appropriate function to test.\n MainMenuActivity testingAddPlantButton = new MainMenuActivity();\n testingAddPlantButton.callOnCreate();\n return testingAddPlantButton.getAddPlantFlag()... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
method used to obtain the system type of the file | public String getType() {
if(isDirectory())
return "File Folder";
else if(extractExtension().compareTo("") == 0)
return "File";
else {
try {
@SuppressWarnings("static-access")
File file = File.createTempFile(this.FILE_NAME, "."+extractExtension());
String type = FileSystemView.getF... | [
"FileType getType();",
"public TrimString getFileSystemType() {\n\t\treturn(_type);\n\t}",
"public String getFileSystemType() {\n return this.fileSystemType;\n }",
"public String getFILE_TYPE() {\r\n return FILE_TYPE;\r\n }",
"String getDefaultFiletype();",
"public String getFileTyp() ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Return the namenode's identifier | public String getNamenode() {
//return namenode.toString();
return "<namenode>";
} | [
"public String getNamenodeId() {\n return this.namenodeId;\n }",
"java.lang.String getNodeId();",
"public String getNodeId(String fname) throws PortalException;",
"public UUID getNameNodeId() {\r\n if (nameNode == null) {\r\n return null;\r\n }\r\n return nameNode.getId();\... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
/CriteriaBuilder cb = currentSession().getCriteriaBuilder(); CriteriaQuery criteria = cb.createQuery( Personn.class ); Root personnRoot = criteria.from( Personn.class ); criteria.where( cb.equal( personnRoot.get( PersonnDAOImpl.id), idCustomer ) ); EntityManagerFactory entityManagerFactory = currentSession().getEntityM... | @Override
public Personn findById(Integer idCustomer) {
return manager.find(Personn.class,idCustomer );
//return findByCriteria(criteria);
} | [
"private Criteria createFindByEntity(int type, int id) {\n return null;\t\n }",
"public Criteria createCriteria(String entityName);",
"public Criteria createCriteria(Class persistentClass);",
"public void newCriteria(){\r\n this.criteria = EasyCriteriaFactory.createQueryCriteria(em, classe);\r\n ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
$ANTLR end "rule__PrimaryExpression__Group_3__1" $ANTLR start "rule__PrimaryExpression__Group_3__1__Impl" InternalReflex.g:7723:1: rule__PrimaryExpression__Group_3__1__Impl : ( ( rule__PrimaryExpression__BoolAssignment_3_1 ) ) ; | public final void rule__PrimaryExpression__Group_3__1__Impl() throws RecognitionException {
int stackSize = keepStackSize();
try {
// InternalReflex.g:7727:1: ( ( ( rule__PrimaryExpression__BoolAssignment_3_1 ) ) )
// InternalReflex.g:7728:1: ( ( rule__PrimaryExpress... | [
"public final void rule__BoolExpr__Group__1() throws RecognitionException {\n\n \t\tint stackSize = keepStackSize();\n \t\n try {\n // InternalMGPL.g:3581:1: ( rule__BoolExpr__Group__1__Impl )\n // InternalMGPL.g:3582:2: rule__BoolExpr__Group__1__Impl\n {\n ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Deactivate the variable view to show execution termination. | public void deactivateVarView() {
this.varView.getVarTree().setBackground(new Color(this.varView.getDisplay(), 231, 231, 231));
this.varView.getVarTree().setForeground(new Color(this.varView.getDisplay(), 151, 151, 151));
} | [
"@Override\n\t\tpublic void deactivate() {\n\t\t\tthis.context.showStatusText(\"\");\n\t\t}",
"public void deactivate(){\n state = State.invisible;\n active = false;\n }",
"public void deactivate() {\n this.active = false;\n }",
"public void deactivateTfod() {\n tfod.deactiva... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Constructs IntegerStorageChange with given paramteres. | public IntegerStorageChange(IntegerStorage istorage, int oldValue, int newValue) {
super();
this.istorage = istorage;
this.oldValue = oldValue;
this.newValue = newValue;
} | [
"public IntegerStorageChange(IntegerStorage iStorage, int oldValue, int newValue) {\n\t\tthis.iStorage = iStorage;\n\t\tthis.oldValue = oldValue;\n\t\tthis.newValue = newValue;\n\t}",
"IntegerVariable createIntegerVariable();",
"IntegerValue createIntegerValue();",
"public Value(int i) {\n integer = i;... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Test to see if containsMessageType will return true for an interface | @Test
@Ignore //FIXME - is it worth fixing this?
public void testContainsMessageTypeInterface() {
messages.add(waterDepth);
assertTrue(messages.containsMessageType(QuantitativeMessage.class));
} | [
"boolean isInterface();",
"public boolean containsService(Class serviceInterface);",
"public boolean isInterface();",
"boolean isMessage();",
"boolean hasMessageAnnotation();",
"public abstract boolean isInterface();",
"public abstract boolean isMessageCompatible(AisMessage msg);",
"@Test\n @Ignore... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Return the longest feature in the dataset for the given chromosome. This is needed when computing summary data for a region. TODO This default implementaiton is crude and should be overriden by subclasses. | @Override
public int getLongestFeature(String chr) {
return 1;
} | [
"public String getLongestName(){\n int max = 0;\n int length;\n String result = null;\n String name;\n for (DataSeries series : this) {\n name = series.getName();\n if( (length=name.length())>max){\n max = length;\n result = name... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Recalculate the area of the polygon. | public void recalculatePolygon() {
polygon.reset();
for (Point point : this.points) {
polygon.addPoint(point.x, point.y);
}
polygonArea = new Area(polygon);
} | [
"public void calculateArea() {\n\t\tdouble area = 0;\n\t\tshapes.clear();\n\t\t\n\t\tassignAllPoints();\n\t\t\n\t\tfor(Polygon p : shapes) {\n\t\t\tif(p.isTruePolygon()) {\n\t\t\t\tarea += p.getArea();\n\t\t\t}else {\n\t\t\t\tp.calculateAngles();\n\t\t\t}\n\t\t}\n\t\t\n\t\tareaText.setText(\"Area: \" + area);\n\t}"... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Uses the data from EditText to add a Flight to the main flightDatabase. Then saves it using the public managers | public void addFlight(View view) {
String flightNumber = ((EditText) findViewById(R.id.flight_number)).getText().toString();
String departureDateTime = ((EditText) findViewById(R.id.departure_date_time)).getText()
.toString();
String arrivalDateTime = ((EditText) findViewB... | [
"public void editFlight(View v){\n TextView status = (TextView) findViewById(R.id.textView_status);\n Flight newFlight =\n FlightSystem.getInstance().searchOneFlight(this.oldFlight);\n\n //In case of an error\n if(newFlight == null){\n status.setText(R.string.fl... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Required height for this IA schedule. | public int requiredHeight() {
int requiredHeight = 0;
for (List<List<String>> c : weekACells) {
int max = 0;
for (List<String> cell : c) {
max = Math.max(max, cell.size());
}
requiredHeight += 30 + 20 * max;
}
for (List<List<String>> c : weekBCells) {
int max = 0;
for (List<String> cell : ... | [
"public double getHeight() {\n\t\t\treturn height.get();\n\t\t}",
"public int getHeight() {\n return (roomHeight);\n }",
"public int getHeight() {\n\t\t\tif (assignedH == null)\n\t\t\t\treturn prefH;\n\t\t\treturn assignedH;\n\t\t}",
"public double getHeight() {\n return height;\n }",
"pub... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Checks the options of the brams voting | public void onValidateFromBramsForm()
{
System.out.println("Brams vale: "+brams);
showErrorBrams=false;
showRepeatedBrams=false;
if(bramsOp1==null || bramsOp2==null || bramsOp3==null || bramsOp4==null || bramsOp5==null || bramsOp6==null || bramsOp7==null)
{
showErrorBrams=true;
}
switch(numO... | [
"private synchronized void getVoteOptions() {\n Token token;\n try {\n // Get vote options and decide randomly which to vote for\n token = tokeniser.getToken(coordIn.readLine());\n if (token instanceof VoteOptionsToken) {\n System.out.println(\"Received ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Set the SWITCH_MODE_STATUS parameter Default: automatic selection is activated | public boolean setSwitchModeStatus(boolean activate) throws IOException, CoronisException {
int[] pData = {(activate) ? 0x01 : 0x00};
return setInternalParameter(SWITCH_MODE_STATUS, pData);
} | [
"public void setSwitchingMode(int value) {\r\n this.switchingMode = value;\r\n }",
"SwitchStatus createSwitchStatus();",
"public void setModeDriver()\n {\n this.setLEDMode(LEDMode.OFF);\n this.setCamMode(CamMode.DRIVER);\n }",
"public String getSWITCH_STATUS() {\r\n return SWITCH_STAT... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Encrypts the input text using the given key | public String encrypt(String text) {
//If key is shorter than the text, repeat keyword along length of text
if(key.length() < text.length()) {
repeatKey(text);
}
text = text.toLowerCase();
StringBuilder sb = new StringBuilder();
for(int i = 0 ; i < text.length(); i++) {
char textLetter = te... | [
"String encrypt(String text);",
"public static String encipher(String plaintext, String key) {\n plaintext = plaintext.toLowerCase();\n key = key.toLowerCase();\n \n StringBuilder sb = new StringBuilder();\n int len = key.length();\n int j = 0;\n for (int i = 0; i <... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
$ANTLR end "ruleOrExpr" $ANTLR start "entryRuleBoolExpr" InternalMGPL.g:604:1: entryRuleBoolExpr : ruleBoolExpr EOF ; | public final void entryRuleBoolExpr() throws RecognitionException {
try {
// InternalMGPL.g:605:1: ( ruleBoolExpr EOF )
// InternalMGPL.g:606:1: ruleBoolExpr EOF
{
if ( state.backtracking==0 ) {
before(grammarAccess.getBoolExprRule());
... | [
"public final void rule__OrExpr__Group__0__Impl() throws RecognitionException {\n\n \t\tint stackSize = keepStackSize();\n \t\n try {\n // InternalMGPL.g:3431:1: ( ( ruleBoolExpr ) )\n // InternalMGPL.g:3432:1: ( ruleBoolExpr )\n {\n // InternalMGPL.g... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
display saved value for theme | public void displaySavedValueTheme(int theme) {
// set the spinner to this theme
// Log.v(LOGGING_TAG, "SettingsActivity in displaySavedValueTheme: " + theme);
// set correct spinner item to be the selected one (based on value in storage)
spinnerTheme.setSelection(theme);
} | [
"public void displaySavedValues() {\n // Log.v(LOGGING_TAG, \"SettingsActivity in displaySavedValues\");\n\n displaySavedValueTheme(getSavedValueTheme());\n displaySavedValueDifficulty(getSavedValueDifficulty());\n displaySavedValueGridSize(getSavedValueGridSize());\n displaySaved... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Contexts: Reculer returns Reculer Mouvement returns Reculer CommandeBasique returns Reculer AR returns Reculer Constraint: (duree=SecondeExp vitesse=PourcentExp) | protected void sequence_Reculer(ISerializationContext context, Reculer semanticObject) {
if (errorAcceptor != null) {
if (transientValues.isValueTransient(semanticObject, DroneDSLLibPackage.Literals.RECULER__DUREE) == ValueTransient.YES)
errorAcceptor.accept(diagnosticProvider.createFeatureValueMissing(semanti... | [
"public final Arbre requete() throws RecognitionException {\n\t\tArbre req_arbre = new Arbre(\"\");\n\n\n\t\tArbre ps =null;\n\t\tArbre psAnnee =null;\n\t\tArbre annee1 =null;\n\t\tArbre annee2 =null;\n\n\t\tArbre ps_arbre;\n\t\ttry {\n\t\t\t// C:\\\\Users\\\\JeanV\\\\Documents\\\\ETUDES\\\\GI05\\\\LO17\\\\projet\... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Retrieves the top ColorImage version within the current ColorImage Stack. | public ColorImage getCurrentImage() {
try {
return currentImage.peek();
} catch (EmptyStackException e) {
return null;
}
} | [
"public Stack<ColorImage> getCurrentImageHistory() {\n return currentImage;\n }",
"public String getTopColor() {\r\n\t\treturn topColor;\r\n\t}",
"public String getInternalTopImg() {\n return internalTopImg;\n }",
"public IntValuePixel pop()\r\n\t\t{\r\n\t\t\tfinal int l = availablePixels.... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Return the resource locator for this item provider's resources. | public ResourceLocator getResourceLocator() {
return DiscoveryEditPlugin.INSTANCE;
} | [
"ResourceProvider getResourceProvider();",
"public ResourceLocator getResourceLocator() {\r\n\t\treturn SimapaEditPlugin.INSTANCE;\r\n\t}",
"public ResourceLocator getResourceLocator() {\r\n\t\treturn MqEditPlugin.INSTANCE;\r\n\t}",
"public static URI getProvider(){\n\t\treturn providers.peek();\n\t}",
"@Ov... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Gets the firstEscCuid value for this GroupDataResponse. | public java.lang.String getFirstEscCuid() {
return firstEscCuid;
} | [
"public java.lang.String getSecondEscCuid() {\n return secondEscCuid;\n }",
"public void setFirstEscCuid(java.lang.String firstEscCuid) {\n this.firstEscCuid = firstEscCuid;\n }",
"public java.lang.String getFirstEscName() {\n return firstEscName;\n }",
"public Integer getcFirst(... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
/ CONSTRUCTORS Constructor: initializes a new LString object, represents empty character sequence | public LString(){
_head = null;
} | [
"public FastString() {\n this(\"\");\n }",
"public LLabel() {\n this(\"\");\n }",
"public EcgString() {\n }",
"public StringDNAStrand() {\n this(\"\");\n }",
"public MyStringBuilder()\n\t{\n\n firstC = null;\n lastC = null;\n length =... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Create a new DefaultScene with the specified origin. | public DefaultScene(final Origin origin) {
this(origin, Platform.getService(AdapterManager.class));
} | [
"public DefaultScene() {\n\t\tthis(Origin.TOP, Platform.getService(AdapterManager.class));\n\t}",
"public Scene createMainScene() throws IOException {\n\t\treturn new Scene(loadMainPane());\n\t}",
"public WorldScene makeScene() {\n // WorldCanvas c = new WorldCanvas(300, 300);\n WorldScene s = new WorldSc... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
$ANTLR end "rule__XCasePart__Group__3__Impl" $ANTLR start "rule__XCasePart__Group_1__0" ../org.xtext.mongobeans.ui/srcgen/org/xtext/mongobeans/ui/contentassist/antlr/internal/InternalMongoBeans.g:10481:1: rule__XCasePart__Group_1__0 : rule__XCasePart__Group_1__0__Impl rule__XCasePart__Group_1__1 ; | public final void rule__XCasePart__Group_1__0() throws RecognitionException {
int stackSize = keepStackSize();
try {
// ../org.xtext.mongobeans.ui/src-gen/org/xtext/mongobeans/ui/contentassist/antlr/internal/InternalMongoBeans.g:10485:1: ( rule__XCasePart__Group_1__0__Impl ru... | [
"public final void rule__XCasePart__Group__0() throws RecognitionException {\n\n \t\tint stackSize = keepStackSize();\n \n try {\n // ../org.xtext.mongobeans.ui/src-gen/org/xtext/mongobeans/ui/contentassist/antlr/internal/InternalMongoBeans.g:10360:1: ( rule__XCasePart__Group__0_... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Constructor specifying a Bspline's degree, number of control points, mode, and a set of Y values and their standard deviations for given X values. The number of X,Y data points must be larger than the number of control points. | public BSpline(int degree, int n, org.bzdev.math.BSpline.Mode mode,
double[] x, double[] y, double[] sigma)
{
bspline = new org.bzdev.math.BSpline(degree, n, mode, x, y, sigma);
fit = bspline.getLSF();
super.setParameters(fit.getParametersArray());
setChiSquare(fit.getChiSquare());
se... | [
"public BSpline(int degree, int n, org.bzdev.math.BSpline.Mode mode,\n\t\t double[] x, double[] y, double sigma)\n\t{\n\t bspline = new org.bzdev.math.BSpline(degree, n, mode, x, y, sigma);\n\t fit = bspline.getLSF();\n\t super.setParameters(fit.getParametersArray());\n\t setChiSquare(fit.getChiS... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Return the value associated with the column: teamCode. | String getTeamCode(); | [
"void setTeamCode(final String teamCode);",
"public int getTeam(){\n\t\treturn team;\n\t}",
"public String getUserTeamno() {\r\n return userTeamno;\r\n }",
"public static String getTeamCode(Context context){\n SharedPreferences pref = context.getSharedPreferences(\"teamPref\", MODE_PRIVATE);\... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Returns the result of interpreting the object as an instance of 'PTuple'. This implementation returns null; returning a nonnull result will terminate the switch. | public T casePTuple(PTuple object) {
return null;
} | [
"public T caseTuple(Tuple object)\n {\n return null;\n }",
"PTuple createPTuple();",
"public T caseTuple1(Tuple1 object)\n {\n return null;\n }",
"public T caseTuple4(Tuple4 object)\n {\n return null;\n }",
"public T caseTuple3(Tuple3 object)\n {\n return null;\n }",
"public T caseTupl... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Add motion stream to sensor \param[in] sensor the software sensor \param[in] video_stream all the stream components \param[out] error if nonnull, receives any error that occurs during this call, otherwise, errors are ignored Original signature : rs2_stream_profile rs2_software_sensor_add_motion_stream(rs2_sensor, rs2_m... | PointerByReference rs2_software_sensor_add_motion_stream(PointerByReference sensor, Realsense2Library.rs2_motion_stream.ByValue motion_stream, PointerByReference error); | [
"PointerByReference rs2_software_sensor_add_video_stream(PointerByReference sensor, Realsense2Library.rs2_video_stream.ByValue video_stream, PointerByReference error);",
"PointerByReference rs2_software_sensor_add_pose_stream(PointerByReference sensor, Realsense2Library.rs2_pose_stream.ByValue pose_stream, Pointe... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Reads the file and generates one input file per entry in our directory. Use movieIDs as file names Splits the given content file into individual files based on the movie id for a later use for the word vector tool | public static Set<String> runFileSplitter(String contentDirectory, String contentFileName, String outputDirectory) throws Exception{
System.out.println("OUTPUTDIR = " + outputDirectory);
// We know where the file is:
String inputFile = contentDirectory + contentFileName;
System.out.println("Splitting t... | [
"private static void processFile(String filename) {\n ArrayList<String> contents = getFileContents(filename); //returned file contents\n HashSet<String> unique = new HashSet<>(); //tracks unique vertices\n ArrayList<String[]> processed = new ArrayList<>(); //stores each split line\n\n ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Gets the option to log all data. | public boolean getDataLogging () {
return dataLogging;
} | [
"public LogOptions get_log_options(){return logOptions;}",
"go.micro.runtime.RuntimeOuterClass.LogsOptions getOptions();",
"public java.util.Map<String, LogPublishingOption> getLogPublishingOptions() {\n return logPublishingOptions;\n }",
"ArrayList<ArrayList<String>> getAllLogs() {\r\n retur... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Remove custom smart device with given ID. | public int removeCustomDevice(String id); | [
"public void removeDevice(ConnectDevice device);",
"IDeviceCommand deleteDeviceCommand(UUID id) throws SiteWhereException;",
"void removeHMCDevice() ;",
"IDeviceType deleteDeviceType(UUID id) throws SiteWhereException;",
"public void removeDeviceServiceLink();",
"public SmartHomeDevice getCustomDevice(Str... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
To fill the graph with data, having a MKP sight, all data will be processed and temporary put on the "perfect" node, then the algorithm will keep the best arrangement for each node and loop until no collection is overweight. | public void placeData() {
// get a user stream to manipulate users of the graph
User[] users = this.getUsers();
List<SystemNode> nodes = this.getSystemNodes().collect(Collectors.toList());
// retrieve data of each user
List<Data> dataList = this.getData(users);
do {
... | [
"private void fillMap() {\n\t\tlong seed = System.nanoTime();\n\t\tList<Node> closestNode = new ArrayList<>();\n\t\tDouble newHieght;\n\n\t\t//Create the primeNodes\n\t\tgetPrimeNode();\n\n\t\t//Create all the nodes with no height and shuffle for random access\n\t\tList<Node> flatNodes = createNodes();\n\t\tCollect... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Gets the component type. The component type is textual type of the component. This is included in the UIDL as component tag attribute. If the component type is null (default), the component tag is not included in the UIDL at all. | public String getComponentType() {
return componentType;
} | [
"public String getComponentType() {\n return this.componentType;\n }",
"ComponentType getType();",
"public Type getComponentType() {\n return componentType;\n }",
"SPComponentType getType();",
"public ComponentType getComponentType()\n {\n return this.componentType;\n }",
... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
setEnumerationType True if the attribute is of Enumeration type, false otherwise. | public boolean isEnumerationType() {
return type == Enumeration;
} | [
"public void setEnumerationType() {\r\n type = Enumeration;\r\n }",
"public final void setAttributeTypeEnum(mxmodelreflection.proxies.PrimitiveTypes attributetypeenum)\n\t{\n\t\tsetAttributeTypeEnum(getContext(), attributetypeenum);\n\t}",
"public final void setAttributeTypeEnum(com.mendix.systemwideinte... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Sets an OnClickListener that when clicked, performs the action given as param. Also, sets an OnTouchListener that changes the color of the TextView when it's touched to simulate the feel of an object that can be interacted with. | public static void bindActionToTextView(TextView textView, final Action action) {
textView.setOnTouchListener(new TextViewChangeColourOnTouchListener(Color.GRAY,
textView.getCurrentTextColor()));
textView.setOnClickListener(new View.OnClickListener() {
@Override
p... | [
"void onViewTap(View view, float x, float y);",
"private void setOnClickListener() {\n listener = new adviceActivityAdapter.RecyclerViewClickListener() {\n @Override\n public void onClick(View v, int pos) {\n Log.v(TAG, \"Item in Rview Clicked!\");\n Clic... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
This method was generated by MyBatis Generator. This method sets the value of the database column HF_hy_01.t1_rf_1_s2 | public void setT1Rf1S2(Float t1Rf1S2) {
this.t1Rf1S2 = t1Rf1S2;
} | [
"public void setR2(String r2) {\r\n this.r2 = r2;\r\n }",
"public void setR1(String r1) {\r\n this.r1 = r1;\r\n }",
"@Override\n public void setField1(java.lang.String Field1) {\n _entity1.setField1(Field1);\n }",
"public void setF2(Integer f2) {\r\n this.f2 = f2;\r\n ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
$ANTLR end "rule__Option__Group_8__2" $ANTLR start "rule__Option__Group_8__2__Impl" InternalMyDsl.g:4283:1: rule__Option__Group_8__2__Impl : ( ( rule__Option__UrlComponentAssignment_8_2 ) ) ; | public final void rule__Option__Group_8__2__Impl() throws RecognitionException {
int stackSize = keepStackSize();
try {
// InternalMyDsl.g:4287:1: ( ( ( rule__Option__UrlComponentAssignment_8_2 ) ) )
// InternalMyDsl.g:4288:1: ( ( rule__Option__UrlComponentAssignment... | [
"public final void rule__Option__Group_8__0__Impl() throws RecognitionException {\n\n \t\tint stackSize = keepStackSize();\n \t\n try {\n // InternalMyDsl.g:4233:1: ( ( 'urlComponent' ) )\n // InternalMyDsl.g:4234:1: ( 'urlComponent' )\n {\n // Intern... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Method used to generate an animal ID. | public void generateId() {
tf_animalID.clear();
String breed = tf_breed.getText();
String petName = tf_petName.getText();
Random rdmNumber = new Random();
String animalId = String.format("%04d", rdmNumber.nextInt(1000));
tf_animalID.appendText(breed.substring(0, 3).... | [
"String generateID() {\n long idNumber = Math.abs(theRandom.nextLong());\n return myActorIDBase + \"-\" + idNumber;\n }",
"default String generateId() {\n\t\treturn \"ier-\" + A3ServiceUtil.generateRandonAlphaNumberic(15, 15, \"\");\n\t}",
"private String generateId() {\n\t\tStringBuilder final... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Get Study Form Context. | public StudyFormContext getStudyFormContext(Long containerId) throws BizLogicException
{
List<StudyFormContext> sfcList = this.retrieve(StudyFormContext.class.getName(),
"containerId", containerId);
if(sfcList != null && !sfcList.isEmpty())
{
return sfcList.get(0);
}
else
{
return null;... | [
"FormContextEvaluator formContextEvaluator();",
"public Form getForm() {\n return form;\n }",
"public FormDefinition getForm();",
"public ResourcesMetadata getForm()\n\t\t{\n\t\t\treturn m_form;\n\t\t}",
"public Object getContext()\n {\n return context;\n }",
"public Form getCurrent... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Spring Data repository for the DeviceProducer entity. | @SuppressWarnings("unused")
@Repository
public interface DeviceProducerRepository extends JpaRepository<DeviceProducer, Long> {
} | [
"public interface ProducerRepository extends JpaRepository<Producer, Integer> {\n List<Producer> findByCountry(String country);\n}",
"@RequestMapping(value = \"/producers/{id}\",\n method = RequestMethod.GET,\n produces = MediaType.APPLICATION_JSON_VALUE)\n @Timed\n public ResponseEntity<Pr... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
This method resets the list of scanned item and lets the customer to scan again | public void resetMachine() {
// Called after checkout and payment is completed
this.currently_scanning = true;
this.scanListener.resetList(); // Clear items from scanner listener
this.cart.clear();
} | [
"public void reset()\n {\n items = null;\n index = 0;\n itemsPerPage = DEFAULT_ITEMS_PER_PAGE;\n }",
"public void reset()\n {\n setLastItem(NOTHING_HANDLED);\n for (int i = 0; i < counters.length; i++)\n {\n counters[i] = 0;\n }\n for (in... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |