query stringlengths 8 1.54M | document stringlengths 9 312k | negatives listlengths 19 20 | metadata dict |
|---|---|---|---|
Retrieves whether the parameter is default group. | public boolean isDefaultGroup(AbstractGroupNode group); | [
"public boolean isUseGroupDefault() {\r\n return useGroupDefault;\r\n }",
"public void setDefaultGroup(boolean defaultGroup);",
"public abstract String getDefaultGroup();",
"public void setUseGroupDefault(boolean useGroupDefault) {\r\n this.useGroupDefault = useGroupDefault;\r\n }",
"boo... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Similarity function for two equivalence classes. This interface abstracts from the function as well as the representation of equivalence classes. Therefore, equivalence classes are referenced by their unique identifier. | public interface EQSimilarity {
/**
* Compute similarity between two equivalence classes. The equivalence
* classes are referenced by their unique identifier.
*
* @param eq1
* @param eq2
* @return
*/
public SimilarityScore sim(int eq1, int eq2);
} | [
"public abstract double similarity(Instance instance1, Instance instance2) throws Exception;",
"@Override\n public double similarity(\n final Integer value1, final Integer value2) {\n\n // The value of nodes is an integer...\n return 1.0 / (1.0 + Math.ab... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Check to see if water level is near either of the limits. | public boolean nearMaxMin() {
double water = this.levelMessage.getDoubleParameter();
double no = (this.configuration.getMaximalLimitLevel()
- this.configuration.getMaximalNormalLevel()) / 4;
if (water > this.configuration.getMaximalLimitLevel()
|| water > this.con... | [
"public boolean nearMaxRescue() {\n double water = this.waterLevel;\n double no = (this.configuration.getMaximalLimitLevel()\n - this.configuration.getMaximalNormalLevel()) / 2;\n if (water > this.configuration.getMaximalLimitLevel()\n || water > this.configuration... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
WRITETESTLINES WRITES TEST LINES THAT ARE IN ADDLINES AND TAKES IN THE STRINGS ONE AT A TIME PRINTING THEM. | private void writeTestLines() {
for (String L : testLines) {
pages.write(L);
}
} | [
"private void printLines() {\n for (String L: testLines) {\n print.write(L);\n }\n }",
"@Test\n\tpublic void writeLines() throws IOException {\n\t\tString[] lines = new String[]{\n\t\t\t\t\"Output line1\",\n\t\t\t\t\"Output line2\",\n\t\t\t\t\"Output line3\"\n\t\t};\n\t\tfor (String li... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Set the value of traiteDroit | public void setTraiteDroit(boolean traiteDroit) {
this.traiteDroit = traiteDroit;
} | [
"public boolean gettraiteDroit() {\r\n return traiteDroit;\r\n }",
"public void setLydoTraVe(String lydoTraVe);",
"public void setTrazo(int trazo) {\n this.trazo = trazo;\n }",
"public void setTridroit(Triangle tridroit) {\r\n this.tridroit = tridroit;\r\n }",
"public void setT... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Test case number: 16 / 239 covered goals: Goal 1. org.apache.commons.math3.complex.Complex.divide(Lorg/apache/commons/math3/complex/Complex;)Lorg/apache/commons/math3/complex/Complex;: Line 256 Goal 2. org.apache.commons.math3.complex.Complex.abs()D: Line 129 Goal 3. org.apache.commons.math3.complex.Complex.getReal()D:... | @Test
public void test16() throws Throwable {
Complex complex0 = new Complex(0.0, 0.0);
Complex complex1 = complex0.log();
Complex complex2 = complex1.divide(complex0);
Complex complex3 = complex1.sin();
Complex complex4 = complex3.add(complex0);
double double0 = complex1.getImag... | [
"@Test\n public void test35() throws Throwable {\n Complex complex0 = new Complex(2.3049492079013518E-7);\n Complex complex1 = complex0.pow((-163.49720578664198));\n Complex complex2 = complex0.add((-163.49720578664198));\n String string0 = complex1.toString();\n Complex complex3 = compl... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Records that a user navigation instructed the NativePageFactory to create a native page for the NTP. This may occur if the user has NTP URLs in a tab's navigation history. | public void recordNativeNewTabPageShown() {
RecordUserAction.record("Android.ChromeHome.NativeNTPShown");
} | [
"private void createPostNativeAndPoliciesPageSequence() {\n assert !mPostNativeAndPolicyPagesCreated;\n assert areNativeAndPoliciesInitialized();\n\n // Initialize SigninChecker, to kick off sign-in for child accounts as early as possible.\n //\n // TODO(b/245912657): explicitly s... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
This method is used to update the Candidate's Drug Test Panel details with a completion date | public static boolean updateApplicantDrugTestOrderDAO20(String employmentApplicantID_DT, int employmentRequisitionNumber_DT, long DTEST_ORD_NBR_DT) throws QueryException
{
logger.debug(String.format("Entering updateApplicantDrugTestOrderDAO20(), employmentApplicantID_DT: %1$s, employmentRequisitionNumber_DT: %2$s, D... | [
"void setEstimatedCompletionDate(Date p_estimatedCompletionDate);",
"public void setDate (Date newDate) {\r\n this.dateAttempt = newDate;\r\n }",
"public void setCompleteDate(Date completeDate) {\r\n this.completeDate = completeDate;\r\n }",
"public static void updateDept() {\n\t}",
"Imp... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Expires the item after received seconds. | public void expiresAfter(int seconds){
Calendar calendar = Calendar.getInstance();
calendar.add(Calendar.SECOND, seconds);
Date expiry = calendar.getTime();
this.expiresAt = expiry;
} | [
"void setExpiresAt(long expiresAt);",
"java.lang.String getItemExpiration();",
"public final int getExpiresAfter() {\n return 0;\n }",
"void setExpiration(long time)\n {\n expiration = time;\n }",
"public long getExpiresIn() {\n return expiresIn;\n }",
"long g... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
For the setter associated with topSpeed make sure the values are between 0 and 70 Print "Invalid Speed" if it is not within these values and leave the speed unchanged. | public void setTopSpeed(int topSpeed) {
if (topSpeed >= 0 && topSpeed <= 70) {
this.topSpeed = topSpeed;
}
else {
System.out.println("Invalid Speed");
}
} | [
"public void setSpeed(float val) {speed = val;}",
"@Test \n\tpublic void setTooHighSpeedLimit() {\n\t\tmovingShip1.setSpeedLimit(2000000);\n\t\tassertEquals(300000, movingShip1.getSpeedLimit(), Util.EPSILON);\n\t}",
"public void setSpeed(float newSpeed){\n speed = newSpeed;\n }",
"public void setCur... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Sets the fare_median value for this AirlineInsightStruct. | public void setFare_median(java.lang.String fare_median) {
this.fare_median = fare_median;
} | [
"public java.lang.String getFare_median() {\n return fare_median;\n }",
"public void setFare(double fare) {\n this.fare = fare;\n }",
"void setCurrentFare(double fare) {\n this.currentFare = fare;\n }",
"public void setMedianIntensities(boolean areMedians);",
"public void setMe... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
If any image views are used within the view holder, clear any pending async img requests by using Glide.clear(ImageView) or Glide.with(context).clear(view) if using Glide v4.0 | @Override
public void onViewRecycled() {
Glide.with(getContext()).clear(binding.seriesImage);
binding.reviewVote.onViewRecycled();
binding.unbind();
} | [
"@Override\r\n public void onViewRecycled(DirectoryAdapterViewHolder holder) {\r\n super.onViewRecycled(holder);\r\n Glide.clear(holder.directoryIcon);\r\n }",
"public static void cleanupCache() {\n for (SoftReference<FastBitmapDrawable> reference : sArtCache.values()) {\n fi... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Distributes the money into chips of different value | public void getChipsFromMoney() {
int value = this.getMoney();
int remainderHundred = value % (int) (Chips.BLACK.getValue());
int numHundred = (value - remainderHundred) / (int) (Chips.BLACK.getValue());
value = value - (int) (Chips.BLACK.getValue() * numHundred);
this.chips[4] ... | [
"private CSExpandBlockByMoney() {}",
"Pair<Integer, Double> totalClipCardPrice();",
"public void returnDollarType() {\n\t\tint dollars[] = { 1, 5, 10, 20, 50, 100 };\n\n\t\t// Calculate the change amount\n\t\tdollarAmountBased = (int) (amountTendered - itemPrice);\n\t\tcheckNeedOf100_Bills = 0;\n\t\tcheckNeedOf... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Creates an ATM GUI | public static void main(String[] args) {
MyATMPanel atm1 = new MyATMPanel();
atm1.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
atm1.setTitle("ATM #1");
atm1.pack();
atm1.setVisible(true);
// Creates an ATM GUI
MyATMPanel atm2 = new MyATMPanel();
at... | [
"public ATM(){\n\t\tgui = new ATM_GUI(\n\t\t\t\tnew ActionListener(){\n\t\t\t\t\tpublic void actionPerformed(ActionEvent e) {\n\t\t\t\t\t\t\thandleButton(e.getActionCommand());\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t);\n\t\tgui.run();\n\t\tloginMenu();\n\t}",
"public ATM_GUI(){\n\t\tsetSize(screenSize);\n\t\taccountDatab... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Returns the map of archetype names to sprite constructors. | public Map<String, SpriteConstructor> getSpriteConstructorMap() {
return spriteFactoryMap;
} | [
"private final Map<String, String> initializeSchemes() {\n\t\tMap<String, String> schemes = new HashMap<String, String>();\n\t\tschemes.put(ClassType.ANNOTATION.name(), M3Constants.INTERFACE_SCHEME);\n\t\tschemes.put(ClassType.CLASS.name(), M3Constants.CLASS_SCHEME);\n\t\tschemes.put(ClassType.ENUM.name(), M3Consta... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
/ returns true if given event is before this event | public Boolean before(Event event) {
int result = this.compareTo(event);
if (result < 0) return true;
return false;
} | [
"public boolean before (Event other)\n\t{\n\t\t//call compareTo. If this < that -> -1; if this > that -> 1\n\t\tint comp = this.compareTo(other); \n\t\tif(comp < 0) //if comp is negative\n\t\t{\n\t\t\treturn true; //because this comes before that \n\t\t}\n\t\t\n\t\telse \n\t\t{\n\t\t\treturn false; \n\t\t}\n\t}",
... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
This method extract the completed sufix from the word. | private String extractCompletedSuffix(String word, String prefix) {
if (word.startsWith(prefix)) {
return word.substring(prefix.length());
} else {
throw new RuntimeException("Invalid prefix (word: " + word +
" prefix:" + prefix + ")");
}
} | [
"private String[] getCorrection(String word){\n\t\t//First we check the word in the common list of corrections\n\t\t//Then we look for the lowercase, just to be certain\n\t\tif(word.length() == 0) return null;\n\t\tCorrection c = this.typos.get(word);\n\t\tif(c != null) return c.getCorrection();\n\t\tc = this.typos... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Convierte de Euro a Dolar | public double conversorEuroDolar(double euro) throws RemoteException; | [
"public double conversorEuroLibra(double euro) throws RemoteException;",
"public double conversorDolarEuro(double dolar) throws RemoteException;",
"public double conversorEuroPeseta(double euro) throws RemoteException;",
"public Fenetre_resultat_coaxial(float longueur, float largeur, float hauteur, float debi... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Returns the result of interpreting the object as an instance of 'Device Metric Category'. This implementation returns null; returning a nonnull result will terminate the switch. | public T caseDeviceMetricCategory(DeviceMetricCategory object) {
return null;
} | [
"public T caseDeviceMetric(DeviceMetric object) {\n\t\treturn null;\n\t}",
"public String meterCategory() {\n return this.innerProperties() == null ? null : this.innerProperties().meterCategory();\n }",
"public T caseDeviceMetricColor(DeviceMetricColor object) {\n\t\treturn null;\n\t}",
"public prot... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Sets the value of field 'RDS_MDT_maturityDate'. | public void setRDS_MDT_maturityDate(
final java.lang.String RDS_MDT_maturityDate) {
this._RDS_MDT_maturityDate = RDS_MDT_maturityDate;
} | [
"public java.lang.String getRDS_MDT_maturityDate(\n ) {\n return this._RDS_MDT_maturityDate;\n }",
"public void setMaturityDate(ZonedDateTime maturityDate) {\n JodaBeanUtils.notNull(maturityDate, \"maturityDate\");\n this._maturityDate = maturityDate;\n }",
"public void setMaturityDate(Local... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Regex for the kind of files this analyzer wants to see. | public String getInputFileRegex() {
return "\\d\\d\\d\\d-\\d\\d\\-month-doi.csv-chunks";
} | [
"Pattern getFileNamePattern();",
"String[] getFileTypes();",
"protected String buildKnownGlobFilter() {\n StringBuilder sb = new StringBuilder();\n sb.append(\"regex:\");\n sb.append(\"([^\\\\s]+(\\\\.(?i)(\");\n final StringBuilder separator = new StringBuilder();\n Defaults.FILE_EXTENSIONS.forE... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Returns the orientation of the Separator | public EJSeparatorOrientation getSeparatorOrientation(); | [
"String getOrientation();",
"int getSeparatorPos();",
"public String orientation()\n {\n int height = cat.getWidth();\n int width = cat.getHeight();\n\n if (height >= width)\n {\n return \"landscape\";\n }\n else \n {\n return \"portrait\... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Checks whether the specified user has the specified requisite permissions. | public boolean userHasPermissions(final String userId, final Set<String> requisitePermissions) {
try {
final JSONObject user = userRepository.get(userId);
final String roleId = user.optString(User.USER_ROLE);
final Set<String> permissions = getPermissions(roleId);
... | [
"private static boolean hasPermission(String username, Permission requiredPermission) throws IOException, SQLException {\n ArrayList<Boolean> userPermissions = retrieveUserPermissionsFromDb(username);\n switch (requiredPermission) {\n case CreateBillboard:\n if (u... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Get the YouTube autoplay next song from the provided link | public static String getYouTubeAutoPlay(String link) throws IOException {
Document doc = Jsoup.connect(link).timeout(0).get();
String next = doc.select("#body-container>#page-container>#page>#content>#watch7-container>#watch7-main-container>#watch7-main")
.select("#watch7-sidebar>#watch7... | [
"private int nextSong() {\n if (playListAdapter != null) {\n playListAdapter.clickPreviousNext(2);\n }\n serviceBound = false;\n player.stopMedia();\n int size = audioList.size();\n if (currentSong < size) {\n currentSong++;\n } else {\n ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Returns true if the player's turn is over, or false | public boolean isPlayerTurnOver() {
return ge.isPlayerTurnOver();
} | [
"public boolean isGameOver() {\n if (!isFirstTurn) {\n if (state.score().totalPoints(TeamId.TEAM_1)>=Jass.WINNING_POINTS||state.score().totalPoints(TeamId.TEAM_2)>=Jass.WINNING_POINTS) {\n return true;\n }\n else {\n return false;\n }\... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
$ANTLR end "rule__LogicalSequence__Group_1__0" $ANTLR start "rule__LogicalSequence__Group_1__0__Impl" ../org.gemoc.gel.xtext.ui/srcgen/org/gemoc/gel/ui/contentassist/antlr/internal/InternalGEL.g:3833:1: rule__LogicalSequence__Group_1__0__Impl : ( () ) ; | public final void rule__LogicalSequence__Group_1__0__Impl() throws RecognitionException {
int stackSize = keepStackSize();
try {
// ../org.gemoc.gel.xtext.ui/src-gen/org/gemoc/gel/ui/contentassist/antlr/internal/InternalGEL.g:3837:1: ( ( () ) )
// ../org.gemoc.gel... | [
"public final void rule__LogicalSequence__Group__0() throws RecognitionException {\n\n \t\tint stackSize = keepStackSize();\n \n try {\n // ../org.gemoc.gel.xtext.ui/src-gen/org/gemoc/gel/ui/contentassist/antlr/internal/InternalGEL.g:3764:1: ( rule__LogicalSequence__Group__0__Imp... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
place all the imageViews into an array | private ImageView[] initImg(int[] ids, View view){
ImageView[] collection = new ImageView[ids.length];
for(int i=0; i<ids.length; i++){
ImageView currentImageView = view.findViewById(ids[i]);
collection[i]=currentImageView;
}
return collection;
} | [
"private void setAllImageViews(){\n try{\n imageView[LEFT_EYEBROW] = FaceFragment.ffv.findViewById(R.id.left_eyebrow);\n imageView[RIGHT_EYEBROW] = FaceFragment.ffv.findViewById(R.id.right_eyebrow);\n imageView[LEFT_EYE] = FaceFragment.ffv.findViewById(R.id.left_eye);\n ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Sets the text color of the CommandView to textColor | public CommandViewBuilder setTextColor(Color textColor)
{
this.textColor = textColor;
return this;
} | [
"public void setTextColor(String textColor);",
"public void setTextColor( Color txtColor ) {\r\n textColor = txtColor;\r\n }",
"public void setTextColor(String color)\n {}",
"public void setTextColor(Color aColor) { _textStyle = aColor; }",
"public void setTextSelectionColor(Color color);",
... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Marks the leaf "nsresetretry" with operation "merge". | public void markNsResetRetryMerge() throws JNCException {
markLeafMerge("nsResetRetry");
} | [
"public void markNsBlockRetriesMerge() throws JNCException {\n markLeafMerge(\"nsBlockRetries\");\n }",
"public void markNsUnblockRetriesMerge() throws JNCException {\n markLeafMerge(\"nsUnblockRetries\");\n }",
"public void markNsResetTimerMerge() throws JNCException {\n markLeafMerg... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Find all Usable Template, calling controller from coupontemplate | @RequestMapping(value = "/coupon-template/template/sdk/all",
method = RequestMethod.GET)
CommonResponse<List<CouponTemplateSDK>> findAllUsableTemplate(); | [
"private void getTemplates(){\n homeTemplateBuffer =ioManager.getTextResource(\"template.html\");\n //homeTemplateBuffer =ioManager.getTextResource(\"template_home.html\");\n templateBuffer=ioManager.getTextResource(\"template_page.html\");\n folderTemplateBuffer=ioManager.getTextResourc... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
read the specified DNS | @HTTP(
method = "GET",
path = "/apis/config.openshift.io/v1/dnses/{name}"
)
@Headers({
"Accept: */*"
})
KubernetesCall<DNS> readDNS(
@Path("name") String name); | [
"@HTTP(\n method = \"GET\",\n path = \"/apis/config.openshift.io/v1/dnses/{name}\"\n )\n @Headers({ \n \"Accept: */*\"\n })\n KubernetesCall<DNS> readDNS(\n @Path(\"name\") String name, \n @QueryMap ReadDNS queryParameters);",
"java.lang.String getDns();",
"DNSService dns();",
"public void ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Gets list of all planets | public static List<Planet> getPlanets() {
return planets;
} | [
"List<Planet> listAllPlanet();",
"public List<Planet> getPlanets() {\n return planetList;\n }",
"public List<Planet> getPlanets() {\n return planet;\n }",
"public Planet[] getPlanets() {\n return this.planets;\n }",
"public List<Planet> getPlanetsInSolarSystem() {\n List<Plane... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
on avatar long pressed | void onAvatarLongClick(String username); | [
"@Override\n public void onAvatarLongClick(String username) {\n\n }",
"public void onLongPress();",
"@Override\n public void onLongPress(View v) {\n }",
"public void onLongClick(View v, Photo photo);",
"public void onLongPress(PressID p);",
"public void onLongRe... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Try to go to one direction. If there is an exit, enter the new room, otherwise print an error message. If we go to a new room, update previous room and previous room stack. | private void goRoom(Command command)
{
if(!command.hasSecondWord()) {
// if there is no second word, we don't know where to go...
System.out.println("Go where?");
return;
}
String direction = command.getSecondWord();
// Try to leave current room... | [
"private void goRoom(Command command) {\n\t\tif (!command.hasSecondWord()) {\n\t\t\t// if there is no second word, we don't know where to go...\n\t\t\tSystem.out.println(\"Go where?\");\n\t\t\treturn;\n\t\t}\n\n\t\tString direction = command.getSecondWord();\n\n\t\t// Try to leave current room.\n\t\tRoom nextRoom =... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Method: generateWorld Purpose: creates a 2 dimensional chunk array. | private static void generateWorld(){
for(int i = 0; i < SIZE*SIZE; i++){
new Chunk();
}
} | [
"public TestArrayWorld nextGeneration() {\n TestArrayWorld new_world = new TestArrayWorld(this);\n int height = new_world.getHeight();\n int width = new_world.getWidth();\n\n //TODO: Use for loops with \"setCell\" and \"computeCell\" to populate \"world\"\n for (int row = 0; row < height; r... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Method to test searchElement() method of MultiDimensionalarray class for invalid inputs | @Test(expected = EmptyInputException.class)
public void testSearchElementWhenMatrixIsEmpty() throws EmptyInputException {
int[][] matrix = {};
MultiDimensionalArray.searchElement(matrix, 100);
} | [
"@Test\n\tpublic void testSearchElementInMultiDimensionalArray() throws EmptyInputException {\n\t\tassertEquals(true, MultiDimensionalArray.searchElement(matrix, 40));\n\t}",
"@Test\n\tpublic void testWhenElementNotInArray() {\n\t\tint[] input = {1, 6, 9, 12, 15, 17, 23, 89};\n\t\t\n\t\tAssert.assertEquals(8, sea... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Create a new ZipEntryHandler. | public ZipEntryHandler(ZipEntryContext context, AbstractVirtualFileHandler parent, String name, boolean isLeaf) throws IOException
{
super(context, parent, name);
this.isLeaf = isLeaf;
if(parent != null)
{
context.addChild(parent, this);
}
} | [
"public void newZipEntry(ZipEntry zipEntry, InputStream inputStream);",
"WZipEntry() {\n\t}",
"public ZipArchiveEntry(final java.util.zip.ZipEntry entry) throws ZipException {\n super(entry);\n setName(entry.getName());\n final byte[] extra = entry.getExtra();\n if (extra != null) {\... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Sets the value of the 'DELETED_IND' field. | public org.LNDCDC_NCS_TCS.SHOWS.apache.nifi.LNDCDC_NCS_TCS_SHOWS.Builder setDELETEDIND(java.lang.CharSequence value) {
validate(fields()[37], value);
this.DELETED_IND = value;
fieldSetFlags()[37] = true;
return this;
} | [
"public void setDeletedInd(String value) {\n setAttributeInternal(DELETEDIND, value);\n }",
"public void setDELETEDIND(java.lang.CharSequence value) {\n this.DELETED_IND = value;\n }",
"public java.lang.CharSequence getDELETEDIND() {\n return DELETED_IND;\n }",
"public java.lang.CharSequence g... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
/ AutoUpdateConfigChangeListener autoUpdateConfigChangeListener = new AutoUpdateConfigChangeListener( environment, beanFactory); AutoUpdateThreadPoolConfigChangeListener utl=new AutoUpdateThreadPoolConfigChangeListener(beanFactory,environment); | private void initializeAutoUpdatePropertiesFeature(ConfigurableListableBeanFactory beanFactory) {
List<ConfigPropertySource> configPropertySources = configPropertySourceFactory.getAllConfigPropertySources();
for (ConfigPropertySource configPropertySource : configPropertySources) {
//添加热更新监听... | [
"void onConfigChanged(ConfigUpdate update);",
"interface ConfigWatcher {\n\n /**\n * Called when receiving an update on virtual host configurations.\n */\n void onConfigChanged(ConfigUpdate update);\n\n void onError(Status error);\n }",
"public void onConfigChange(List<HelixProperty> configs, ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
$ANTLR end "ruleBooleanBinaryExpression" $ANTLR start "entryRuleIntegerVariable" InternalActivityDiagram.g:564:1: entryRuleIntegerVariable : ruleIntegerVariable EOF ; | public final void entryRuleIntegerVariable() throws RecognitionException {
try {
// InternalActivityDiagram.g:565:1: ( ruleIntegerVariable EOF )
// InternalActivityDiagram.g:566:1: ruleIntegerVariable EOF
{
before(grammarAccess.getIntegerVariableRule());
... | [
"public final void entryRuleBooleanVariable() throws RecognitionException {\n try {\n // InternalActivityDiagram.g:593:1: ( ruleBooleanVariable EOF )\n // InternalActivityDiagram.g:594:1: ruleBooleanVariable EOF\n {\n before(grammarAccess.getBooleanVariableRule())... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Sets both the value and note for a given element in this record | public void setElementValueAndNote(String elementName, String value, String note)
{
assert(elementName != null);
Integer elementSort = Integer.valueOf(elementName);
if (elementSort.compareTo(29) < 0)
{
if (elementSort.compareTo(15) < 0)
{
if (elementSort.compareTo(8) < 0)
{
if (elementSor... | [
"public void setElement(T newvalue);",
"public void setNote(String note);",
"public void setNotes(java.lang.String notes)\n {\n synchronized (monitor())\n {\n check_orphaned();\n org.apache.xmlbeans.SimpleValue target = null;\n target = (org.apache.xmlbeans.Simp... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Sets the cardTypeName value for this Card. | public void setCardTypeName(java.lang.String cardTypeName) {
this.cardTypeName = cardTypeName;
} | [
"public java.lang.String getCardTypeName() {\r\n return cardTypeName;\r\n }",
"public void setCardType(java.lang.String cardType) {\r\n this.cardType = cardType;\r\n }",
"public void setTypeName(java.lang.String value);",
"public void setTypeName(String typeName);",
"public void setTypeN... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Gets the resource ID of the accessibility string describing the drawer open event. | public int getDrawerOpenDesc() {
return mDrawerOpenAccessibilityDescription;
} | [
"public int drawerID() {\n return this.drawerID;\n }",
"public int getDrawerCloseDesc() {\n\t\treturn mDrawerCloseAccessibilityDescription;\n\t}",
"public long getEventIdentifier() {\n\t\treturn super.getProperty(\"EventIdentifier\", long.class);\n\t}",
"int getAsicIdentifier();",
"String getATDoc... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
This method was generated by MyBatis Generator. This method returns the value of the database column ku8_proj_service_inst.PROJECT_INSTANCE_ID | public Integer getProjectInstanceId() {
return projectInstanceId;
} | [
"public Integer getProjectid() {\n\t\tif (projectid == null) {\n\t\t\tProjectDetails projectDetails = projectsClient.getProjectDetailsBySlug(getProjectslug());\n\t\t\tprojectid = projectDetails.getId();\n\t\t}\n\t\treturn projectid;\n\t}",
"public Long getProjectID() {\r\n RemoteCustomFieldValue[] values =... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Ajout Type Type AES | public void ajouttypeaes(String nom) {
TypeAES T = new TypeAES();
T.setNom(nom);
em.persist(T);
} | [
"public TypeAES rechercheTypeaes(String Num) {\n\t\tint Numero = Integer.parseInt(Num);\n\t\tTypeAES T = em.find(TypeAES.class, Numero);\n\t\treturn T;\n\t}",
"public abstract void setEncryptMode();",
"public void CreateCipher() {\n String key = \"IWantToPassTAP12\"; // 128 bit key\n aesKey = new... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Evaluate a usewhen attribute | public boolean evaluateUseWhen(String expression, int locationId) throws XPathException {
UseWhenStaticContext staticContext = new UseWhenStaticContext(getConfiguration(), startTag, staticVariables);
LocationProvider lp = getPipelineConfiguration().getLocationProvider();
// TODO: The followin... | [
"java.lang.String getUseWhen();",
"When createWhen();",
"public interface When {\r\n \t/** Returns the condition. In a \"when x then a\" clause\r\n * the condition is \"x\".\r\n \t */\r\n public Object getCondition();\r\n /** Returns the value. In a \"when x then a\" clause\r\n ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Create new Access IP Address | @Test
public void accessIPAddressCreateTest() throws ApiException {
//AccessIPAddressPOST accessIPAddressPOST = null;
//AccessIPAddressResponseSchema response = api.accessIPAddressCreate(accessIPAddressPOST);
// TODO: test validations
} | [
"Address createAddress();",
"void createAvailableIp(K8sIpam ipam);",
"public void markIpAddressCreate() throws JNCException {\n markLeafCreate(\"ipAddress\");\n }",
"IpAddress allocateIp(IpPrefix cidr);",
"void createAllocatedIp(K8sIpam ipam);",
"public void markIpAddress1Create() throws JNCExce... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
sets the global variables selectedIndex_ and selectedQID_ | public void setSelectedQuestionInfo(int ind, String qid) {
selectedIndex_ = ind;
selectedQID_ = qid;
} | [
"public native void setSelectedIndex(int index);",
"static int getIndexSelected() {\n return indexSelected;\n }",
"public void setSelectedKBAQuestionId1(int value) {\n this.selectedKBAQuestionId1 = value;\n }",
"public void setSelIndex(int anIndex) { _tview.setSelIndex(anIndex); }... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Gets the value of the 'field482' field | public java.lang.CharSequence getField482() {
return field482;
} | [
"public java.lang.CharSequence getField482() {\n return field482;\n }",
"public void setField482(java.lang.CharSequence value) {\n this.field482 = value;\n }",
"public java.lang.CharSequence getField483() {\n return field483;\n }",
"public java.lang.CharSequence getField483() {\n return field... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Purpose: Default constructor for Theatre parameters. | public Theatre(String title, String location, ArrayList<String> times, double price, TheatreGenre genre, ArrayList<String> directors, ArrayList<String> cast) {
super(title, location, times, price);
this.genre = genre;
this.directors = directors;
this.cast = cast;
} | [
"public Artikel(String naam, int prijs)\n {\n // initialise instance variables\n naam = naam;\n prijs = prijs;\n }",
"public Rennwagen() {\n\t}",
"public TalentShow () {\r\n\t\tsuper();\r\n\t}",
"public GenreMovie() {\n\t\tthis(\"Genre_Movie\", null);\n\t}",
"public Manatee(String n... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Returns the robot of this insubrange condition. | @Basic
public Robot getRobot()
{
return this.robot;
} | [
"public BasicRobot getRobot() {\n\t\treturn robot;\n\t}",
"private Robot getRobot() {\n\t\treturn robot;\n\t}",
"public Robot getRobot(){\n\n return this.robotBuilder.getRobot();\n\n }",
"public Robot getRobot();",
"public Ellipse2D getTowerRangeCircle() {\n return towerRangeCircle;\n }"... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Set extra information used by station obs datasets. Use stnIdVName or stnIndexVName. | public void setStationInfo(String stnIdVName, String stnDescVName, String stnIndexVName,
StationHelper stationHelper) {
this.stnIdVName = stnIdVName;
this.stnDescVName = stnDescVName;
this.stnIndexVName = stnIndexVName;
this.stationHelper = stationHelper;
if (stnIdVName != null) {
Varia... | [
"private void sensorInformation(){\n\t\tthis.name = this.paramName;\n\t\tthis.version = this.paramVersion;\n\t\tthis.author = this.paramVersion;\n\t}",
"public void setSdetVobservation(String sdetVobservation) {\n\t this.sdetVobservation = sdetVobservation;\n\t }",
"public void setStationIdx(int idx) {\n ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Initialises a frame to display the output as text. | private void initialiseTextFrame() {
textFrame = new TextFrame();
textFrame.getTextArea().setFont(new Font(Font.MONOSPACED, Font.PLAIN, 12));
textFrame.setLocation(parentFrame.getX() + parentFrame.getWidth() + 10, parentFrame.getY());
} | [
"public TextFrame() {\n \n super();\n init(null, Toolkit.getDefaultToolkit().getSystemClipboard());\n }",
"public OutputConsole() {\n initComponents();\n setSize (1520, 750);\n }",
"private void createFrame() {\n System.out.println(\"Assembling \" + name + \" fram... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Create an aliased stroom.annotation_data_link table reference | public AnnotationDataLink(String alias) {
this(DSL.name(alias), ANNOTATION_DATA_LINK);
} | [
"public AnnotationDataLink(Name alias) {\n this(alias, ANNOTATION_DATA_LINK);\n }",
"public AnnotationDataLink() {\n this(DSL.name(\"annotation_data_link\"), null);\n }",
"private static TableRef createAliasedTableRef( final TableMeta table,\n ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
[set] user_t by my user_id, named 'userT'. | public void setUserT(OptionalEntity<UserT> userT) {
_userT = userT;
} | [
"public void setIdUser(int value) {\n this.idUser = value;\n }",
"public void setIdUser(String idUser) {\n this.idUser = idUser;\n }",
"public void setIdUser(int idUser) {\n this.idUser = idUser;\n }",
"public void setAsDataUser (int tident)\t\t{\n\t\tdataUser[tident]=true;\n\t}",
... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Minimizes the application to the taskbar | public void minimizeApp() {
frame.setState(JFrame.ICONIFIED);
} | [
"public void minimize()\n {\n this.setExtendedState(JFrame.ICONIFIED);\n }",
"void beforeMinimized();",
"void onMinimized();",
"public void windowIconified(WindowEvent arg0) {\n //textArea1.append(\"Window is minimized\");\n\n }",
"private void jb_MinimizeActionPerformed(java.awt.even... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Use the given key to get the corresponding SaleAssociate instance | public SaleAssociate getSaleAssociate(PersistenceManager pm, Long key, boolean useCache) throws InvalidIdentifierException {
if (key == null || key == 0L) {
throw new InvalidIdentifierException("Invalid key; cannot retrieve the SaleAssociate instance");
}
// Try to get a copy from th... | [
"public SaleAssociate getSaleAssociate(Long key) throws InvalidIdentifierException{\n PersistenceManager pm = getPersistenceManager();\n try {\n return getSaleAssociate(pm, key);\n }\n finally {\n pm.close();\n }\n }",
"public SaleAssociate getSaleAssoci... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Method to set the executed filtering rules information | public void setExecutedFilteringRuleInfoList(Set<ExecutedRuleInfo> executedFilteringRuleInfoList) {
this.executedFilteringRuleInfoList = executedFilteringRuleInfoList;
} | [
"private void setFilter(){\n\t\tplainSelect.setWhere(null);\n\t\t\n\t\t// add joins as filters\n\t\tSet<Expression> filtersToAdd = new HashSet<Expression>(this.filters); \n//\t\t\t\tfor(TermMap left : joins.keySet()){\n//\t\t\t\t\tfor(TermMap right: joins.get(left)){\n//\t\t\t\t\t\tTermMap joinCond = filterUtil.com... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
$ANTLR end "rule__BitOrExpression__Group__0__Impl" $ANTLR start "rule__BitOrExpression__Group__1" InternalReflex.g:9008:1: rule__BitOrExpression__Group__1 : rule__BitOrExpression__Group__1__Impl ; | public final void rule__BitOrExpression__Group__1() throws RecognitionException {
int stackSize = keepStackSize();
try {
// InternalReflex.g:9012:1: ( rule__BitOrExpression__Group__1__Impl )
// InternalReflex.g:9013:2: rule__BitOrExpression__Group__1__Impl
... | [
"public final void rule__BitOrExpression__Group_1__2() throws RecognitionException {\n\n \t\tint stackSize = keepStackSize();\n \t\n try {\n // InternalReflex.g:9093:1: ( rule__BitOrExpression__Group_1__2__Impl )\n // InternalReflex.g:9094:2: rule__BitOrExpression__Group_1... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Returns a list of schedules by event limited to a page. | List<EventDate> findEventDates(long eventId, Page page) throws DaoException; | [
"public Page<Event> findAllProcessEvents(int processNumber , Pageable pageable);",
"public Page<Event> findEventsByEventTypeId(Long typeId , Pageable pageable);",
"List<LocalDate> findEventDatesQuest(long eventId, Page page) throws DaoException;",
"public Page<Event> findEventsByAppModuleId(Long moduleId , P... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
get available initial users. | List<PublicUserModel> getAvailableInitialUsers(String servProvCode, Long proxyUserSeqNbr) throws AAException; | [
"PlatformUser[] getPlatformUsers();",
"public ArrayList<UserDetail> gettingAllAvailableUsers() throws Exception;",
"public List<User> getUsers(Boolean enabled, Date startDate, Date endDate, int offset, int length) throws UserManagementException;",
"public List<UserStatus> getAllAvailableUsers() {\n Lis... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
$ANTLR end "ruleCollections" $ANTLR start "entryRuleSelectAllCheckboxes" ../org.xtext.example.browser/srcgen/org/xtext/example/browser/parser/antlr/internal/InternalBrowser.g:2097:1: entryRuleSelectAllCheckboxes returns [String current=null] : iv_ruleSelectAllCheckboxes= ruleSelectAllCheckboxes EOF ; | public final String entryRuleSelectAllCheckboxes() throws RecognitionException {
String current = null;
AntlrDatatypeRuleToken iv_ruleSelectAllCheckboxes = null;
try {
// ../org.xtext.example.browser/src-gen/org/xtext/example/browser/parser/antlr/internal/InternalBrowser.g:2098:2:... | [
"public final EObject ruleCollections() throws RecognitionException {\n EObject current = null;\n\n AntlrDatatypeRuleToken lv_s_0_0 = null;\n\n AntlrDatatypeRuleToken lv_c_1_0 = null;\n\n EObject lv_f_2_0 = null;\n\n AntlrDatatypeRuleToken lv_g_3_0 = null;\n\n\n enterRule(... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Creates a new instance of the XmlHttpProxyServlet | public XmlHttpProxyServlet() {
if (rDebug) {
logger = getLogger();
}
} | [
"private HttpProxyCacheServer newProxy() {\n return new HttpProxyCacheServer(this);\n }",
"public WebProxy(URIResolver uriResolver) {\n setURIResolver(uriResolver);\n int portno = Settings.getInt(CommonSettings.HTTP_PORT_NUMBER);\n jettyServer = new Server(portno);\n jettySer... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Removes a value of property EndedAtTime given as an instance of java.util.Calendar | public void removeEndedAtTime(java.util.Calendar value) {
Base.remove(this.model, this.getResource(), ENDEDATTIME, value);
} | [
"public void removeCalendar(org.semanticwb.model.Calendar value);",
"public void removeStartedAtTime(java.util.Calendar value) {\r\n\t\tBase.remove(this.model, this.getResource(), STARTEDATTIME, value);\r\n\t}",
"public void removeTime() {\n\n if (!isDayOnly()) {\n\n List<PropertyParameter> pa... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Returns the name of the parent Region. | String getParentRegion(); | [
"public java.lang.String getParentAccountRegion() {\n return parentAccountRegion;\n }",
"public long getParentRegion() {\n return _region.getParentRegion();\n }",
"public String getParentName() {\n return parentName;\n }",
"public String getParentName() {\n return parentName;\... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Move to the right | protected void moveRight() {
right = true;
left = false;
} | [
"public void right(){\n\t\tmoveX=1;\n\t\tmoveY=0;\n\t}",
"public void moveRight() {\n locX = locX + 1;\n }",
"public void moveRight()\n {\n x += moveSpeed;\n if(x > screenWidth)\n x = 0;\n past = x + bigWidth - screenWidth;\n }",
"protected void reverseRight(){\... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Helper method which checks if the currently generated token is of the specified type. | private boolean tokenIsType(TokenType type) {
return lexer.getToken().getTokenType() == type;
} | [
"private boolean isTokenOfType(ShellTokenType type) {\n\t\treturn lexer.getToken().getType() == type;\n\t}",
"private boolean check(TokenType tokType) {\r\n if(tokens.get(position).returnType() != tokType) {\r\n return false;\r\n }\r\n return true;\r\n }",
"public boolean isTo... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Amazon Resource Name (ARN) of the license. | public String getLicenseArn() {
return this.licenseArn;
} | [
"public String getLicense() {\n return (String) getAttributeInternal(LICENSE);\n }",
"public String getLicenseName(String licenseString);",
"String getArn();",
"public String getLicense();",
"public String getArn() {\n return this.arn;\n }",
"@Override\n\tpublic java.lang.String getLic... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Reverses the transition. If the transition is running, updates the start time so the reverse duration is the same as the current elapsed time. | public void reverse() {
if (isRunning()) {
long repeatDuration = currentTime - startTime;
long endTime = currentTime + repeatDuration;
startTime = endTime - duration;
}
setReversed(!isReversed());
} | [
"public void startReverse() {\n startHelper(f_startDirection.getOppositeDirection(), \"startReverse()\");\n }",
"public void reverseDirection() {\n\t\tif (movingForward) {\n\t\t\tsetBack(40000);\n\t\t\tmovingForward = false;\n\t\t} else {\n\t\t\tsetAhead(40000);\n\t\t\tmovingForward = true;\n\t\t}\n\t}",
"p... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Get the list of Connectathon Participants attending on SOCIAL EVENT, depending on the logged in user (admin or vendor) | @Override
public List<ConnectathonParticipant> getPeopleAttendingOnSocialEvent() {
if (LOG.isDebugEnabled()) {
LOG.debug("getPeopleAttendingOnSocialEvent");
}
renderAddPanel = false;
if (Role.isLoggedUserAdmin() || Role.isLoggedUserProjectManager() || Role.isLoggedUserM... | [
"@Override\n public List<ConnectathonParticipant> getPeopleAttendingOnTuesday() {\n if (LOG.isDebugEnabled()) {\n LOG.debug(\"getPeopleAttendingOnTuesday\");\n }\n\n renderAddPanel = false;\n\n if (Role.isLoggedUserAdmin() || Role.isLoggedUserProjectManager() || Role.isLogg... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Process userTags string, prepares a Tag List and set in Question. | private void assembleTags(Question question, String userTags) {
if (userTags != null && !userTags.isEmpty()) {
String[] tagNames = userTags.split(Constants.COMMA_DELIMITER);
if (tagNames.length > 0) {
List<Tag> tags = new ArrayList<Tag>();
for (String tagName : tagNames) {
Tag tag = new Tag();
... | [
"private void addTagsToUser(JSONObject userJSON, User newUser){\n\t\tfor (Object obj : userJSON.getJSONArray(\"tags\")) {\n\t\t\tUserTag tag = new UserTag();\n\t\t\tJSONObject ob = (JSONObject) obj;\n\t\t\ttag.setUsertagName(ob.getString(\"tagname\"));\n\t\t\ttry {\n\t\t\t\ttag.setUserTid(ob.getInt(\"tid\"));\n\t\t... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Initializes objects used for testing. These objects include an Inventory and Product object. | @Before
public void init() {
inventory = new Inventory();
product = (new Product("banana", 188, 1.99)); //Create products
product1 = (new Product("doritos", 189, 3.99));
product2 = (new Product("mango", 190, 0.99));
inventory.getInventory().put(product.getId(), 6); ... | [
"public void init() {\n inventory.init();\n }",
"public static void initializeInventory() {\n // Reads the predefined values in arrays INITIAL_DESCRIPTION, INITIAL_PRICE, and INITIAL_UNITS_ON_HAND,\n // adds them to objects that are created, and adds those objects to the allItemObjects arr... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
The list of subnet mappings associated with the nlb. | @Required
public List<SubnetMappings> getSubnetMapping() {
if (subnetMapping == null) {
subnetMapping = new ArrayList<>();
}
return subnetMapping;
} | [
"List<InboundNatRulePortMapping> inboundNatRulePortMappings();",
"public abstract List<AttrMapping> getMappings();",
"Collection<String> getMappingPrefixes();",
"public ArrayList<Mapping> getMappings() { return new ArrayList<Mapping>(mappings); }",
"public List<Subnets> getSubnets() {\n\tList<Map<String,Ob... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Returns the status if revealed, or null if the radar has not revealed that tile. | @Nullable
public SeaStatus getSeaStatus(Point tile) {
if (mGrid[tile.y][tile.x] == RadarStatus.REVEALED) {
return mSea.getStatus(tile);
} else {
return null;
}
} | [
"private void updateRevealedStatus(Hand h){\n for(Meld m : Arrays.asList(h.meld1, h.meld2, h.meld3, h.meld4)){\n\n Tile calledTile = m.getCalledTile();\n if( calledTile!=null && calledTile.winningTile ) {\n continue;\n }\n\n Tile.RevealedState newSta... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Returns a new object of class 'Exception Type'. | ExceptionType createExceptionType(); | [
"ExceptionDef createExceptionDef();",
"public TypeException() {\n }",
"Exception createException();",
"public final Class getExceptionType() {\n return $exceptionType;\n }",
"public ExceptionBase( ExceptionType exceptionType ) {\n\t\tsuper();\n\t\texceptionsCatching( exceptionType );\n\t}",
"Class<... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Calculate which pie slice is under the pointer, and set the current item field accordingly. | private void calcCurrentItem() {
int pointerAngle;
// calculate the correct pointer angle, depending on clockwise drawing or not
if(mOpenClockwise) {
pointerAngle = (mIndicatorAngle + 360 - mPieRotation) % 360;
}
else {
pointerAngle = (mIndicatorAngle + 1... | [
"@Override\n protected void onDataChanged() {\n super.onDataChanged();\n\n int currentAngle = 0;\n int index = 0;\n int size = mPieData.size();\n\n for (PieModel model : mPieData) {\n int endAngle = (int) (currentAngle + model.getValue() * 360.f / mTotalValue);\n ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Deletes a review record from the database. It can only be accessed by a system administrator. | boolean deleteReview(int reviewId); | [
"public void deleteReview() throws ServletException, IOException {\r\n\t\tInteger reviewId = Integer.parseInt(request.getParameter(\"id\"));\r\n\t\tif (reviewDAO.get(reviewId) != null) {\r\n\t\t\treviewDAO.delete(reviewId);\r\n\t\t\t\r\n\t\t\tString message = \"The review has been deleted successfully.\";\r\n\t\t\t... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Find the size of string s in the font of the Graphics context "page" | public static int getStringHeight(Graphics page, Font f, String s) {
FontMetrics fm = page.getFontMetrics(f);
java.awt.geom.Rectangle2D rect = fm.getStringBounds(s, page);
return (int)Math.round(rect.getHeight());
} | [
"Size measureText(String text, double availWidth, double availHeight);",
"public static float textHeight(BitmapFont fntIn, String sIn){\n return new GlyphLayout(fntIn,sIn).height;\n }",
"public int getFontSize();",
"public int getFontSize ()\r\n {\r\n return font.getSize();\r\n }",
"p... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
implements javax.slee.resource.ResourceAdaptor Please refer to JSLEE v1.1 Specification Page 302 for further information. The SLEE calls this method to signify to the resource adaptor that a service has been installed and is interested in a specific set of events. The SLEE passes an event filter which identifies a set ... | public void serviceInstalled(String serviceID, int[] eventIDs,
String[] resourceOptions) {
eventIDFilter.serviceInstalled(serviceID, eventIDs);
} | [
"void onInstallerEvent(String eventName, Object... args);",
"protected abstract boolean setupEventService();",
"void onEntry(FilterContext ctx) throws SoaException;",
"public interface OnServiceAListener\n {\n /**\n * onServiceResponse\n *\n * Called when confirm signal arrives for a request.\... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Get the stats of the yaxis (min, max, difference) | public double[] getyStats() {
return yStats;
} | [
"public void calculateYAxis()\n\t{\n\t\tyAxisValues = new int [5];\n\t\tfor (int i = 0; i < yAxisValues.length; i++)\n\t\t\tyAxisValues[i] = (int)(i*numericalVerticalSpacing);\n\t}",
"public String getYAxisInfo();",
"public static NumberAxis calcAxisY() {\n double minY = Math.round(\n Coll... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
This method decides whether to search for fetchFollowersOfUser or who the user is following | private static String queryToFetchWhoFollowsUser (boolean fetchFollowersOfUser){
return (fetchFollowersOfUser) ? Query.FETCH_USERS_FOLLOWERS : Query.FETCH_WHO_USER_FOLLOWS;
} | [
"void getFollowersAndFollowing() {\n final ParseUser currUser = ParseUser.getCurrentUser();\n\n // QUERY FOLLOWERS\n final ParseQuery<ParseObject> query = ParseQuery.getQuery(Configs.FOLLOW_CLASS_NAME);\n query.whereEqualTo(Configs.FOLLOW_IS_FOLLOWING, userObj);\n query.orderByDes... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
/ UML: +register(flyable : Flyable) : void | public void register(Flyable flyable) {
ensureNotNull(flyable);
observers.add(flyable);
} | [
"@Override\n public void register(Flyable flyable) {\n super.register(flyable);\n\n if (flyable instanceof Aircraft) {\n this.log(((Aircraft)flyable).getFullName() + \" registered to weather tower.\");\n }\n }",
"public void register(){\n }",
"protected void __register()... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
creates the search button | public JButton createSearchButton() {
searchButton = new JButton("Search");
searchButton.addActionListener(new ActionListener() {
public void actionPerformed(ActionEvent e) {
String s= "";
s = titleField.getText().replaceAll("^ +| +$|( )+", "$1");
// if the name is not valid , display error message... | [
"private void setUpSearchButton()\n {\n searchButton.setCaption(\"Go\");\n searchButton.addClickListener(new Button.ClickListener() {\n public void buttonClick(Button.ClickEvent event)\n {\n //Grab the data from the database base on the search text\n ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Get method for struct member 'simplify_subsurf_render'. | public short getSimplify_subsurf_render() throws IOException
{
if ((__io__pointersize == 8)) {
return __io__block.readShort(__io__address + 2436);
} else {
return __io__block.readShort(__io__address + 2412);
}
} | [
"public void setSimplify_subsurf_render(short simplify_subsurf_render) throws IOException\n\t{\n\t\tif ((__io__pointersize == 8)) {\n\t\t\t__io__block.writeShort(__io__address + 2436, simplify_subsurf_render);\n\t\t} else {\n\t\t\t__io__block.writeShort(__io__address + 2412, simplify_subsurf_render);\n\t\t}\n\t}",
... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
get the candidate category details. | public List<CndtCtg> getCandidateCategory(); | [
"public com.huazhu.hvip.thirdparty.entity.axis.reservation.CustomerCategory getCategoryInfo() {\n return categoryInfo;\n }",
"public String getCategory() {\n return fullPhoto.getCategory();\n }",
"public EntityCategory getCategory ( ) {\n\t\treturn extract ( handle -> handle.getCategory ( ) ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
//////////////////// SimpleConsensus ProgressIndex Assigner ////////////////////// | public void assignSimpleProgressIndexIfNeeded(TsFileResource tsFileResource) {
simpleConsensusProgressIndexAssigner.assignIfNeeded(tsFileResource);
} | [
"InstAssignIndex createInstAssignIndex();",
"int getProgress(int index);",
"com.google.spanner.admin.database.v1.OperationProgress getProgress(int index);",
"@NlsContexts.ProgressText\n String getIndexingProgressText();",
"@Test\n public void testPartialCheckpointNewIndexRows() throws Exception {\n ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Set the given properties in the device. | private final FutureVoid setDeviceProperties(final String... keyValues) {
return deviceInstance.setUserProperties(keyValues);
} | [
"public void setDevice(String name, Property p) throws SmartSystemException {\n hub.setDevice(name, p);\n }",
"public void setProperty(String property, String value);",
"public static void setProperties(Properties properties)\r\n {\r\n //todo should I fire events here? who knows...\r\n ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
/ Have the function TimeConvert(num) take the num parameter being passed and return the number of hours and minutes the parameter converts to (ie. if num = 63 then the output should be 1:3). Separate the number of hours and minutes with a colon. | public static String TimeConvert(int num) {
int hours;
int minutes;
if (num < 60){
return "0:" + num;
}
else {
hours = num / 60;
minutes = num % 60;
return hours + ":" + minutes;
}
} | [
"private String formatTime(int time) {\n String timeTxt;\n\n if (time >= 60) {\n int minutes = time / 60;\n int seconds = time % 60;\n if (seconds < 10) { timeTxt = minutes + \":0\" + seconds; }\n else { timeTxt = minutes + \":\" + seconds; }\n }\n ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Creates a new SaveException. | public SaveException() {
this.message = "Generic Save Exception";
} | [
"public MalformedSaveException() {\n super();\n }",
"Exception createException();",
"public SaveException(String message) {\n\t\tthis.message = message;\n\t}",
"public StoreException() {\r\n super();\r\n }",
"public PersistenceException()\n {\n super();\n }",
"Exce... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
It displays all the teachers by invoking the TeacherService class method. It sends the list of the teachers to the JSP Page by using ModelAndView object | @RequestMapping(value = "/displayTeachers", method=RequestMethod.GET)
public ModelAndView displayTeachers() {
try {
return new ModelAndView("RetrieveTeachers","teachers", teacherService.getTeachers()); ... | [
"@RequestMapping(value = \"/displayTeacher\", method=RequestMethod.GET) \n public ModelAndView displayTeacher(@RequestParam(\"teacherId\") int teacherId) { \n ModelAndView modelView = new ModelAndView(); \n modelView.setViewName(\"DisplayTeacher\");\n try {\n modelV... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
This method was generated by MyBatis Generator. This method corresponds to the database table news_honour_tbl | NewsHonour selectByPrimaryKey(Integer id); | [
"@Select({\n \"select\",\n \"NEWS_ID, TITLE, BODY, IMG_URL, URL, CREATE_TIME\",\n \"from NEWS\",\n \"where NEWS_ID = #{newsId,jdbcType=INTEGER}\"\n })\n @Results({\n @Result(column=\"NEWS_ID\", property=\"newsId\", jdbcType=JdbcType.INTEGER, id=true),\n @Result(column... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
optional double c3 = 4; &47; &92;brief Angle offset factor | public double getC3() {
return c3_;
} | [
"double getC3();",
"public double getAngle3() {\n return angle3;\n }",
"float getO3();",
"public double getAngleC()\n\t{\n\t\treturn Math.toDegrees(Math.acos((getSideCA() * getSideCA() + getSideBC() * getSideBC() - getSideAB() * getSideAB()) / (2 * getSideBC() * getSideCA())));\n\t}",
"double getF... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Constructor for the TaskViewHolders. | public TaskViewHolder(View itemView) {
super(itemView);
taskDescriptionView = (TextView) itemView.findViewById(R.id.taskDescription);
priorityView = (TextView) itemView.findViewById(R.id.priorityTextView);
} | [
"public TaskList(){}",
"public TaskAdapter(Context context, ArrayList<Task> tasks) {\n\t taskList = tasks;\n\t mInflater = LayoutInflater.from(context);\n\t }",
"public TaskList() {\n tasks = new ArrayList<>();\n }",
"public TaskList() {\n tasks = new ArrayList<>();\n cachedTasks = n... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
$ANTLR end "rule__XForLoopExpression__Group__7" $ANTLR start "rule__XForLoopExpression__Group__7__Impl" ../org.xtext.example.helloxcore.ui/srcgen/org/xtext/example/helloxcore/ui/contentassist/antlr/internal/InternalHelloXcore.g:10059:1: rule__XForLoopExpression__Group__7__Impl : ( ( rule__XForLoopExpression__EachExpres... | public final void rule__XForLoopExpression__Group__7__Impl() throws RecognitionException {
int stackSize = keepStackSize();
try {
// ../org.xtext.example.helloxcore.ui/src-gen/org/xtext/example/helloxcore/ui/contentassist/antlr/internal/InternalHelloXcore.g:10063:1: ( ( ( rul... | [
"public final void rule__XForLoopExpression__Group__7() throws RecognitionException {\n\n \t\tint stackSize = keepStackSize();\n \n try {\n // ../org.xtext.example.helloxcore.ui/src-gen/org/xtext/example/helloxcore/ui/contentassist/antlr/internal/InternalHelloXcore.g:10052:1: ( r... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
replace the specified OAuth | @HTTP(
method = "PUT",
path = "/apis/config.openshift.io/v1/oauths/{name}",
hasBody = true
)
@Headers({
"Content-Type: application/json",
"Accept: */*"
})
KubernetesCall<OAuth> replaceOAuth(
@Path("name") String name,
@Body OAuth body); | [
"@HTTP(\n method = \"PUT\",\n path = \"/apis/config.openshift.io/v1/oauths/{name}\",\n hasBody = true\n )\n @Headers({ \n \"Content-Type: application/json\",\n \"Accept: */*\"\n })\n KubernetesCall<OAuth> replaceOAuth(\n @Path(\"name\") String name, \n @Body OAuth body, \n @QueryMap Repl... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Return the monthly report(monthly sum) of a farm in the give year. | public int[] getMonthlySumForFarm(String farmID, int year) {
ArrayList<Farm> listOfFactories = factory.getFarmList();
for (Farm f : listOfFactories) {
if (f.getFarmID().equals(farmID))
return f.monthlySum(year);
}
return null; // the farm with the specified identifier was not found
... | [
"public double[] getMonthlySumVec(int year) {\r\n int numberOfFarms = factory.getFactorySize();\r\n ArrayList<Farm> farmList = factory.getFarmList();\r\n double[] monthlySumVec = new double[12];\r\n for (int i = 0; i < numberOfFarms; i++) {\r\n double[] monthVec = intToDouble(farmList.get(i).monthl... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Methods Click on the Make An Appointment link to open the Sign in Fcc page | public KPAUISignOnFccPage clickAppointmentsLink(){
getMakeAnAppointmentLink().click();
return new KPAUISignOnFccPage(driver);
} | [
"public KatalonStartPage clickMakeAppointmentLink() {\n makeAppointment.click();\n return this;\n }",
"public KPAUIScheduleAppointmentPage openQuickLinksMakeAnAppointmentPage() {\n getFooterNavQuickLinksMakeAnAppointmentLink().click();\n return new KPAUIScheduleAppointmentPage(drive... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Actionevent for the button representing birth rule 4. Sets the rule state and button highlight state to opposite of what it was. | public void b4Event() {
if (birthRules.contains((byte) 4)) {
birthRules.remove(birthRules.indexOf((byte) 4));
b4Btn.setStyle("");
} else {
birthRules.add((byte) 4);
b4Btn.setStyle("-fx-background-color: " + highlightColor);
}
} | [
"public void b5Event() {\n\n if (birthRules.contains((byte) 5)) {\n\n birthRules.remove(birthRules.indexOf((byte) 5));\n b5Btn.setStyle(\"\");\n\n } else {\n\n birthRules.add((byte) 5);\n b5Btn.setStyle(\"-fx-background-color: \" + highlightColor);\n ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Get all values of property Edition as a ReactorResult of java.lang.String | public ReactorResult<java.lang.String> getAllbiboEdition_as() {
return Base.getAll_as(this.model, this.getResource(), EDITION, java.lang.String.class);
} | [
"public String getPropertiesForOutput()\n { //declare variable and assign its value\n String allPropertiesAppended = \"\";\n \n /*for loop to go through propertyList data \n and retrieving each element of propertyList \n assigning them to property variable*/\n for(Property property ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
verify the required parameter 'callNoteData' is set | @SuppressWarnings("rawtypes")
private com.squareup.okhttp.Call setCallNoteValidateBeforeCall(CallNoteData callNoteData, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
if (callNoteData == null) {
... | [
"public com.squareup.okhttp.Call setCallNoteAsync(CallNoteData callNoteData, final ApiCallback<ApiSuccessResponse> callback) throws ApiException {\n\n ProgressResponseBody.ProgressListener progressListener = null;\n ProgressRequestBody.ProgressRequestListener progressRequestListener = null;\n\n ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |