query stringlengths 8 1.54M | document stringlengths 9 312k | negatives listlengths 19 20 | metadata dict |
|---|---|---|---|
Crypto appendHMAC method calculates and appends HMAC to encrypted file Generates secret key using provided password. Then the HMAC is calculated using the encrypted file contents. Finally the HMAC is appended to the encrypted file. | private static void appendHMAC(File src, final char[] pass) throws AlertException
{
final byte[] salt = generateBytes(SALT_SIZE);
byte[] secret = keygen(pass, salt, HMAC_KEY_SIZE);
Arrays.fill(pass, (char) 0);
SecretKeySpec key = new SecretKeySpec(secret, HMAC_MODE);
Arrays.fill(secret, (byte) 0x00);
... | [
"public void appendHmac(Hmacs alg)\n\t{\n\t\tappendAlgorithm(hmacAlgs, alg);\n\t}",
"private synchronized byte[] createHmac(byte[] content) {\n\t\treturn hmac.doFinal(content);\n\t}",
"private String calculateHMAC(String hmacKey, String signingString) throws GeneralSecurityException, UnsupportedEncodingExceptio... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Returns true if XMLObject is a chapter. | public abstract boolean isChapter(XMLObject xml); | [
"public boolean equals(Chapter chapter){\r\n return this.title == chapter.title &&\r\n this.body == chapter.body;\r\n }",
"public abstract void parseChapter(XMLObject xml, Chapter chapter);",
"boolean isDocument(Object object);",
"boolean hasHadithChapterNo();",
"public boolean isAr... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
$ANTLR end "rule__NavigationOrAttributeCall__Group__0" $ANTLR start "rule__NavigationOrAttributeCall__Group__0__Impl" InternalOCLlite.g:6050:1: rule__NavigationOrAttributeCall__Group__0__Impl : ( () ) ; | public final void rule__NavigationOrAttributeCall__Group__0__Impl() throws RecognitionException {
int stackSize = keepStackSize();
try {
// InternalOCLlite.g:6054:1: ( ( () ) )
// InternalOCLlite.g:6055:1: ( () )
{
// InternalOCLlite.g:6055:1:... | [
"public final void rule__NavigationOrAttributeCall__Group__0() throws RecognitionException {\n\n \t\tint stackSize = keepStackSize();\n \t\n try {\n // InternalOCLlite.g:6042:1: ( rule__NavigationOrAttributeCall__Group__0__Impl rule__NavigationOrAttributeCall__Group__1 )\n ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
For top level Total with filter and dates and without filter and dates | public void getTotalVoucherRemaining(Map<String, List<String>> filterMap, List<String> yyyymm, Map<String, Double> ret) {
final String collectionName = Constants.VOUCHER_DETAILS_COLLECTION_NAME;
List<Bson> pipeLine = new ArrayList<>();
if(filterMap!=null) {
Bson q1QryMatch = common.formMatchClauseForLi... | [
"QueryBuilder getFilteredTotalQuery();",
"QueryBuilder getUnfilteredTotalQuery();",
"public Total getTotal();",
"List<TotalSaleOperator> getTotalOperatorSaleReportPerDate(Timestamp fromDate, Timestamp toDate);",
"TotalSaleOperator getTotalSaleReportPerDate (Timestamp fromDate, Timestamp toDate);",
"public... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Returns minimum value 2 problems: 1) no compiletime enforcing of arguments fails at runtime only 2) it's ugly | int min(int... args) {
if (args.length == 0) {
throw new IllegalArgumentException("too few arguments");
}
int min = args[0];
for (int arg : args) {
if (arg < min) {
min = arg;
}
}
return min;
} | [
"Number getMin();",
"int getMinimum_java_lang_Number_();",
"public abstract int getMinimumArguments();",
"private static final EvaluationAccessor min(EvaluationAccessor operand, EvaluationAccessor[] arguments) {\r\n EvaluationAccessor result = null;\r\n Value oVal = operand.getValue();\r\n ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Adds the specified buddy to your permit list. | public void addPermit(String buddy) throws JaimException {
if (loggedIn) {
try {
TocAddPermitCommand tap = new TocAddPermitCommand();
tap.addPermit(buddy);
sendTocCommand(tap);
}
catch (IOException e) {
throw new... | [
"public void addBlock(String buddy) throws JaimException {\n if (loggedIn) {\n try {\n TocAddDenyCommand tad = new TocAddDenyCommand();\n tad.addDeny(buddy);\n sendTocCommand(tad);\n }\n catch (IOException e) {\n thr... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
$ANTLR end "rule__DomainSpecificEventReferenceWithArguments__Group__4__Impl" $ANTLR start "rule__SingleArgument__Group__0" ../org.gemoc.gel.xtext.ui/srcgen/org/gemoc/gel/ui/contentassist/antlr/internal/InternalGEL.g:5023:1: rule__SingleArgument__Group__0 : rule__SingleArgument__Group__0__Impl rule__SingleArgument__Grou... | public final void rule__SingleArgument__Group__0() throws RecognitionException {
int stackSize = keepStackSize();
try {
// ../org.gemoc.gel.xtext.ui/src-gen/org/gemoc/gel/ui/contentassist/antlr/internal/InternalGEL.g:5027:1: ( rule__SingleArgument__Group__0__Impl rule__Single... | [
"public final void rule__SingleArgument__Group__0__Impl() 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:5039:1: ( ( () ) )\n // ../org... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Set the tierToArchive property: The function to tier blob snapshot to archive storage. Support blob snapshot currently at Hot or Cool tier. | public ManagementPolicySnapShot withTierToArchive(DateAfterCreation tierToArchive) {
this.tierToArchive = tierToArchive;
return this;
} | [
"public DateAfterCreation tierToArchive() {\n return this.tierToArchive;\n }",
"protected void setTier(int tier)\r\n\t{\tthis.tier = tier;\t}",
"public ManagementPolicySnapShot withTierToCool(DateAfterCreation tierToCool) {\n this.tierToCool = tierToCool;\n return this;\n }",
"publi... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Sets the pm 4411 BS. | public void setPm4411BS(Pm4411BS pm4411bs) {
pm4411BS = pm4411bs;
} | [
"public void setPm2411BS(Pm2411BS pm2411bs) {\r\n\t\tpm2411BS = pm2411bs;\r\n\t}",
"public Pm4411BS getPm4411BS() {\r\n\t\treturn pm4411BS;\r\n\t}",
"public void setPm3111BS(Pm3111BS pm3111bs) {\r\n\t\tpm3111BS = pm3111bs;\r\n\t}",
"public Pm2411BS getPm2411BS() {\r\n\t\treturn pm2411BS;\r\n\t}",
"public Pm... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Obtener un barrio de la base de datos | public Barrio getBarrio(String filtro, String orden) throws SQLException {
Barrio mBarrio = null;
Cursor cursorBarrio = crearCursor(CatalogosDBConstants.BARRIO_TABLE , filtro, null, orden);
if (cursorBarrio != null && cursorBarrio.getCount() > 0) {
cursorBarrio.moveToFirst();
mBarrio=BarrioHelper.crearBarri... | [
"@Override\n\tpublic List<Barrio> obtenerBarrios() {\n\t\treturn (List<Barrio>) barrioserviceImp.findAll();\n\t}",
"public List<BodaEntity> getBodas() {\n LOGGER.info(\"Inicia proceso de consultar todas las bodas\");\n // Note que, por medio de la inyección de dependencias se llama al método \"findA... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Creates a new Tuple4i instance. | public static Tuple4i newReadOnly(Tuple4i tuple) {
return (new Tuple4i(true, tuple));
} | [
"public Tuple4i() {\n\t\tthis(false, 0, 0, 0, 0);\n\t}",
"public Tuple4i(Tuple4i that) {\n\t\tthis(false, that);\n\t}",
"public static Tuple4i newReadOnly() {\n\t\treturn (new Tuple4i(true));\n\t}",
"public Tuple4i(int x, int y, int z, int w) {\n\t\tthis(false, x, y, z, w);\n\t}",
"protected Tuple4i(boolean... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
/verify run diagnostics page | public void verifyRunDiagnosticsPage(String university)
{
verifyHelpPageUrl(driver,university);
if(picture.isDisplayed())
{
System.out.println("run diagnostics page verified");
ATUReports.add(time +" run diagnostics page verified", LogAs.PASSED, null);
Assert.assertTrue(true);
}
el... | [
"void report(DiagnoseRun run);",
"public void verifyHelpPageUrl(WebDriver driver,String university)\r\n\t{\r\n\t \r\n\t \r\n\t\tString url=university+\"/#/diagnostic\";\r\n\t\tif(url.contains(driver.getCurrentUrl()))\r\n\t\t{\r\n\t\t\tSystem.out.println(\"run diagnostics url verified\");\r\n\t\t\tATUReports.... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
places two rectangles on the same vertical plane, but 10 horizontal units away from each other to show that they do not intersect | public void testRectangleHorizontal()
{
Rectangle left = new Rectangle("left", 20, 20, 40, 40);
Rectangle right = new Rectangle("right", 70, 20, 40, 40);
assertFalse(left.intersects(right));
assertFalse(right.intersects(left));
} | [
"public void testRectangleVertical()\r\n {\r\n Rectangle top = new Rectangle(\"top\", 20, 20, 40, 40);\r\n Rectangle bottom = new Rectangle(\"bottom\", 20, 70, 40, 40);\r\n assertFalse(top.intersects(bottom));\r\n assertFalse(bottom.intersects(top));\r\n }",
"public void testRect... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Sets (as xml) the "number" attribute | void xsetNumber(org.apache.xmlbeans.XmlString number); | [
"public void setNumber(int value) {\n this.number = value;\n }",
"public void setNumber(int number)\n {\n this.number = number;\n }",
"void setAsNumber(int asNumber);",
"public void xsetNum(org.apache.xmlbeans.XmlInteger num)\r\n {\r\n synchronized (monitor())\r\n ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
$ANTLR end "rule__XSwitchExpression__DefaultAssignment_5_2" $ANTLR start "rule__XCasePart__TypeGuardAssignment_0" ../org.xtext.mongobeans.ui/srcgen/org/xtext/mongobeans/ui/contentassist/antlr/internal/InternalMongoBeans.g:16951:1: rule__XCasePart__TypeGuardAssignment_0 : ( ruleJvmTypeReference ) ; | public final void rule__XCasePart__TypeGuardAssignment_0() throws RecognitionException {
int stackSize = keepStackSize();
try {
// ../org.xtext.mongobeans.ui/src-gen/org/xtext/mongobeans/ui/contentassist/antlr/internal/InternalMongoBeans.g:16955:1: ( ( ruleJvmTypeReference ) ... | [
"public final void rule__XCasePart__TypeGuardAssignment_0() throws RecognitionException {\n\n \t\tint stackSize = keepStackSize();\n \n try {\n // ../org.xtext.guicemodules.ui/src-gen/org/xtext/guicemodules/ui/contentassist/antlr/internal/InternalGuiceModules.g:17988:1: ( ( ruleJ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
This method was generated by Apache iBATIS ibator. This method returns the value of the database column EP_MAIL.ML_SALTERBY | public String getMlSalterby() {
return mlSalterby;
} | [
"public void setMlSalterby(String mlSalterby) {\n this.mlSalterby = mlSalterby;\n }",
"public String getModifyBy() {\r\n return (String) getAttributeInternal(MODIFYBY);\r\n }",
"public Date getMlSalterdate() {\n return mlSalterdate;\n }",
"public Long getModifyby() {\n ret... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Add to the graph an undirected edge from vertex v1 to vertex v2. | public void addUndirectedEdge(int v1, int v2) {
addUndirectedEdge(v1, v2, null);
} | [
"public void addUndirectedEdge(int v1, int v2) {\n addUndirectedEdge(v1, v2, null);\n }",
"public void addEdge(int v1, int v2) {\r\n addEdge(v1, v2, null);\r\n }",
"public void addEdge(int v1, int v2) {\n addEdge(v1, v2, null);\n }",
"public void addUndirectedEdge(int v1, int v2,... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Returns the first foo in the ordered set where uuid = &63;. | public Foo fetchByUuid_First(java.lang.String uuid,
com.liferay.portal.kernel.util.OrderByComparator<Foo> orderByComparator); | [
"@Override\n\tpublic Arret fetchByUuid_First(\n\t\tString uuid, OrderByComparator<Arret> orderByComparator) {\n\n\t\tList<Arret> list = findByUuid(uuid, 0, 1, orderByComparator);\n\n\t\tif (!list.isEmpty()) {\n\t\t\treturn list.get(0);\n\t\t}\n\n\t\treturn null;\n\t}",
"public Foo fetchByUuid_C_First(java.lang.St... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Appends and returns a new empty "pattern" element | public org.apache.geronimo.xbeans.geronimo.naming.GerPatternType addNewPattern()
{
synchronized (monitor())
{
check_orphaned();
org.apache.geronimo.xbeans.geronimo.naming.GerPatternType target = null;
target = (org.apache.geronimo.xbeans.geronimo.naming.GerPattern... | [
"public org.astrogrid.adql.v1_0.beans.AtomType addNewPattern()\n {\n synchronized (monitor())\n {\n check_orphaned();\n org.astrogrid.adql.v1_0.beans.AtomType target = null;\n target = (org.astrogrid.adql.v1_0.beans.AtomType)get_store().add_element_user(PATTERN$2);\... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
get relevant FDs from projection of FDList | public static ArrayList<PFD> getRelevantFDs(ArrayList<String> r, ArrayList<PFD> prj){
ArrayList<PFD> subProjection = new ArrayList<>();
for (PFD pfd: prj) {
if(r.containsAll(pfd.x) && r.containsAll(pfd.y))
subProjection.add(pfd);
}
return subProjection;
} | [
"protected List<String> getFofDbs() throws NotesException {\n\t\tNotesThread.sinitThread();\n\n\t\tList<String> ret = new ArrayList<String>();\n\t\ttry {\n\t\t\tSession sess = NotesFactory.createSession();\n\t\t\tDbDirectory dbDir = sess.getDbDirectory(null);\n\t\t\tDatabase currDb = dbDir.getFirstDatabase(DbDirect... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Returns the activity course ID of this activity course place. | @Override
public long getActivityCourseId() {
return _activityCoursePlace.getActivityCourseId();
} | [
"@Override\n\tpublic long getActivityCoursePlaceId() {\n\t\treturn _activityCoursePlace.getActivityCoursePlaceId();\n\t}",
"@Override\n\tpublic long getPrimaryKey() {\n\t\treturn _activityCoursePlace.getPrimaryKey();\n\t}",
"@Override\n\tpublic String getUuid() {\n\t\treturn _activityCoursePlace.getUuid();\n\t}... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Child class must create a search result area. | abstract GridPane createSearchResultArea(ResultSet result); | [
"public SearchResultPanel()\n\t{\n\t\tcreateComponents();\n\t\tdesignComponents();\n\t\taddComponents();\n\t}",
"Search createSearch();",
"TSearchResults createSearchResults(TSearchQuery searchQuery);",
"public DoSearch() {\r\n \r\n }",
"public SearchResults() {\n\t\tPageFactory.initElements(driver... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
True if has "transient" attribute | public boolean isSetTransient()
{
synchronized (monitor())
{
check_orphaned();
return get_store().find_attribute_user(TRANSIENT$8) != null;
}
} | [
"public boolean getTransient()\n {\n synchronized (monitor())\n {\n check_orphaned();\n org.apache.xmlbeans.SimpleValue target = null;\n target = (org.apache.xmlbeans.SimpleValue)get_store().find_attribute_user(TRANSIENT$8);\n if (target == null)\n ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
The email panel sets up the email confirmation in the exact same manner as the password fields. | public void setupEmailPanel() {
//Instantiate the labels
lblEInitial = new JLabel(INITIAL_EMAIL);
lblEConfirm = new JLabel(CONFIRM_EMAIL);
txtEmailInitial = new JTextField(PW_LENGTH);
txtEmailConfirm = new JTextField(PW_LENGTH);
pnlEmail = new JPanel(new BorderLayout());
pnlEmailInitial =... | [
"public void emailConfirmacao(){\n }",
"public void performForgotPassword() {\n\t\tfPassword.click();\n\t\temail.sendKeys(\"pt@test.com\");\n\t\tco.continueSubmitType.click();\n\t\tif(co.successMsg.isDisplayed()) {\n\t\t\tlog.info(co.successMsg.getText());\n\t\t} else if(co.errorMsg.isDisplayed()) {\n\t\t\tlog... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
/ sets classification of event | public void setClassification(String classification) {
this.classification = classification;
} | [
"public void setClassification(int classification)\n {\n this.classification = classification;\n }",
"@IcalProperty(pindex = PropertyInfoIndex.CLASS,\n eventProperty = true,\n todoProperty = true,\n journalProperty = true\n )\n public void ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Creates instance of ContextAwareService based on layer.xml attribute values | static AttachType createService(Map attrs) throws ClassNotFoundException {
String serviceName = (String) attrs.get(DebuggerProcessor.SERVICE_NAME);
String displayName = (String) attrs.get("displayName");
return new AttachType.ContextAware(serviceName, displayName);
} | [
"static ContextAwareService createService(Map attrs) throws ClassNotFoundException {\n String serviceName = (String) attrs.get(DebuggerProcessor.SERVICE_NAME);\n return new ContextAware(serviceName);\n }",
"public ServiceContext ensureServiceContext()\n {\n ServiceContex... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
CHECKS IF WONDER CAN BE BUILT | public boolean canBeBuilt() {
if (owner.hasTechnology(techRequired) && !(owner.hasTechnology(techObsoletionID)))
return true;
return false;
} | [
"public boolean canBuild( IModuleDescriptor descriptor );",
"public boolean canBeBuilt() {\n return getGoodsRequired().isEmpty() == false;\n }",
"boolean canBuild(SagaChunk sagaChunk, SagaPlayer sagaPlayer) {\n\n\t\t\n\t\t// True if player is a builder on the chunk:\n\t\t\treturn true;\n\t\t\n\t\t//... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Adds a value to property UserDefinedFrame as an RDF2Go node | public void addUserDefinedFrame( org.ontoware.rdf2go.model.node.Node value) {
Base.add(this.model, this.getResource(), USERDEFINEDFRAME, value);
} | [
"public void setUserDefinedFrame( org.ontoware.rdf2go.model.node.Node value) {\r\n\t\tBase.set(this.model, this.getResource(), USERDEFINEDFRAME, value);\r\n\t}",
"DefinedProperty nodeAddProperty( long nodeId, int propertyKey, Object value );",
"public void addUserDefinedFrame(UserDefinedFrame value) {\r\n\t\tBa... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Initializes a new instance of BasicTranscendentPath consisting of the specified names in the order of their appearance relative to the specified host name. The resulting path will be transcendent. If the last element is the empty string, the resulting path will refer to a directory. | public BasicTranscendentPath(final @NonNull String hostname, final String... names) {
this(hostname, Arrays.asList(names));
} | [
"public BasicTranscendentPath(final @NonNull String hostname, final List<String> names) {\n super(names);\n this.hostname = canonical(hostname);\n }",
"public BasicTranscendentPath(final @NonNull URI uri) {\n super(uri.getPath().replaceFirst(\"^/+\", \"\"));\n hostname = uri.getAuth... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
return the pixel downLeft to this | public Pixel downLeft() {
if (this.down == null) {
return null;
}
else {
return this.down.left;
}
} | [
"public Pixel topLeft() {\n if (this.up == null) {\n return null;\n }\n else {\n return this.up.left;\n }\n }",
"float getLeft();",
"public Point getdownRigth() {\n Point downRigth = new Point(this.upperLeft.getX() + this.getWidth(), this.upperLeft.getY() + this.getHeight());\n ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
return the location of the key | public Integer[] getKeyLocation() {
return this.keyLocation;
} | [
"final public native int keyLocation() /*-{\n return this.keyLocation;\n }-*/;",
"public int getIndexOfKey() {\n\t\treturn indexOfKey;\n\t}",
"public int searchLocation(GenericSlot key) {\n return keyLocation(key);\n }",
"public String getKeyProgLocation();",
"public int searchLocation(ListEnt... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
$ANTLR end "rulenullStatement" $ANTLR start "entryRuleassignStatement" InternalMASL.g:3435:1: entryRuleassignStatement returns [EObject current=null] : iv_ruleassignStatement= ruleassignStatement EOF ; | public final EObject entryRuleassignStatement() throws RecognitionException {
EObject current = null;
EObject iv_ruleassignStatement = null;
try {
// InternalMASL.g:3435:56: (iv_ruleassignStatement= ruleassignStatement EOF )
// InternalMASL.g:3436:2: iv_ruleassignState... | [
"public final EObject entryRuleAssignStatement() throws RecognitionException {\n EObject current = null;\n\n EObject iv_ruleAssignStatement = null;\n\n\n try {\n // InternalAgreeParser.g:3281:2: (iv_ruleAssignStatement= ruleAssignStatement EOF )\n // InternalAgreeParser.g:... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Describes a way to represent objects of type T as doubles. | public static interface DoubleAttribute<T> {
double get(final T object);
} | [
"public IPrimitiveType getDouble();",
"public Double getDoubleAttribute();",
"public DoubleType asDouble() { return null; }",
"Double getAsDouble();",
"EDataType getEDouble();",
"public boolean isDouble();",
"void visitDouble(DoubleValue d);",
"public DoubleTag(String name, double value) {\r\n ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Sets the value of the locationID property. | public void setLocationID(long value) {
this.locationID = value;
} | [
"public void setLocationID(int value) {\n this.locationID = value;\n }",
"public void setLocationId(String locationId);",
"public void setLocationID(long locationID) {\n this.locationID = locationID;\n }",
"public void setLocationId(int value) {\n this.locationId = value;\n }",
... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
The very first visitorId to be assigned to the end user | public String getInitialVisitorId() {
return initialVisitorId;
} | [
"int getVisitorid();",
"public int getVisitorid() {\n return visitorid_;\n }",
"String getVisitId();",
"public Long getVisitUserId() {\n return visitUserId;\n }",
"public static int genNextUserId() {\n return nextUserId++;\n }",
"public Integer getVisitId() {\n r... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Sets the minimum number of tool items to show in the cool item. If this number is less than the total tool items, a chevron will appear and the hidden tool items appear in a drop down menu. By default, all the tool items are shown in the cool item. | public void setMinimumItemsToShow(int minimumItemsToShow) {
this.minimumItemsToShow = minimumItemsToShow;
} | [
"public int getMinimumItemsToShow() {\n return minimumItemsToShow;\n }",
"@attribute(value = \"\", required = false, defaultValue=\"SWT default\")\r\n\tpublic void setVisibleItemCount(Integer count) {\r\n\t\tcombo.setVisibleItemCount(count);\r\n\t}",
"public void updateSize(boolean changeCurrentSize... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Getter method for this.donutType | public DonutType getDonutType() {
return donutType;
} | [
"public String getTypeOfDrink()\n {\n return typeOFDrink;\n }",
"public String getDiscountType() {\n\t\treturn (String) get_Value(\"DiscountType\");\n\t}",
"public String getdiseaseType(){\n \treturn this.diseaseType;\n }",
"public double getPrice() {\n return donutType.getPrice();\n ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Test of writeClienteToBinaryFile method, of class Paciente. | @Test
public void testWriteClienteToBinaryFile() throws Exception {
System.out.println("writeClienteToBinaryFile");
String path = "paciente.dat";
pac2.writeClienteToBinaryFile(path);
Paciente pac3 = Paciente.readClientefromBinaryFile("paciente.dat").get(0);
assertEquals... | [
"static void CrearArchivo(Vector productos, Vector clientes){ \r\n \ttry{ //iniciamos el try y si no funciona se hace el catch\r\n BufferedWriter bw = new BufferedWriter(\r\n \t\t//Iniciamos el archivo adentro de bw que es un objeto.\r\n new FileWriter(\"reporte.txt\") ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
optional int32 backendId = 4; | boolean hasBackendId(); | [
"private String backendId(){\n\n String backendIdUrl= \"http://\" + backendServiceUrl + \"/id\";\n RestTemplate restTemplate = new RestTemplate();\n return restTemplate.getForObject(backendIdUrl, String.class);\n }",
"public interface BSPRPCProtocolVersion extends VersionedProtocol {\n ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Send a the status of the town at the target coordinates to the player | public void showTownStatusAtCoord(Player player, TownyWorld world, Coord coord) throws TownyException {
if (!world.hasTownBlock(coord))
throw new TownyException("This area (" + coord + ") hasn't been claimed.");
Town town = world.getTownBlock(coord).getTown();
plugin.getTownyUniverse().sendMessage(player, plu... | [
"public void showTownStatusHere(Player player) {\n\t\ttry {\n\t\t\tTownyWorld world = plugin.getTownyUniverse().getWorld(player.getWorld().getName());\n\t\t\tCoord coord = Coord.parseCoord(player);\n\t\t\tshowTownStatusAtCoord(player, world, coord);\n\t\t} catch (TownyException e) {\n\t\t\tplugin.sendErrorMsg(playe... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
/ Adds each of the three levels. | private void addLevels() {
level1 = new Level();
add(level1, LEVEL_OFFSET, getHeight() - FIRST_LEVEL_VERTICAL_OFFSET);
level2 = new Level();
add(level2, LEVEL_OFFSET, (level1.getY() * (2/3.0)) - level2.getHeight() / 2.0);
level3 = new Level();
add(level3, LEVEL_OFFSET, (level1.getY() * (1/3.0)... | [
"public void add_nodes_to_levels() {\n\t\tfor(int i =0; i<this.max_level+1;i++){\n\t\t\tthis.all_levels.add(new ArrayList<Node>());\n\t\t}\n\t\t\n\t\tfor(Node temp_node:this.list_of_all_nodes){\n\t\t\ttemp_node.level = temp_node.return_all_parents_till_root(temp_node).size();\n\t\t\tArrayList<Node> temp_arraylist =... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
/ Returns the sum of the total laxity of all cores | public int getLaxity() {
int laxity = 0;
for(Core core: cores) {
laxity += core.getLaxity();
}
return laxity;
} | [
"protected static int coresRequired() {\n\t\treturn 1;\n\t}",
"public int getCpuLoad();",
"public int getNumCpuCores() {\r\n return numCpuCores;\r\n }",
"public abstract int computeTotalExecutors();",
"public float getCPULoad(){\r\n float used = ohpool.get_used_CPU();\r\n float alloc... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Sets properties responsible of ingame display of game parameters | private void setProperties() {
AppState appState = AppState.getInstance();
appState.difficultyPropertyProperty().setValue(appState.getGameMode().getName());
appState.lvlPropertyProperty().setValue(appState.getCurrentLvl());
appState.hPPropertyProperty().setValue(appState.getGameMode().ge... | [
"private void setPlayerProperties(){\n //proceed to the game play and set a position for the tank and define everything required to play\n // and set the base\n\n EntitManager.tank = new Tank(\"-1\",\n new Vector2(com.bvisiongames.me.Tanks.cameraWIDTH/2, com.bvisiongames.me.T... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
$ANTLR end "rule__Port__Group__4" $ANTLR start "rule__Port__Group__4__Impl" InternalReflex.g:4646:1: rule__Port__Group__4__Impl : ( ( rule__Port__SizeAssignment_4 ) ) ; | public final void rule__Port__Group__4__Impl() throws RecognitionException {
int stackSize = keepStackSize();
try {
// InternalReflex.g:4650:1: ( ( ( rule__Port__SizeAssignment_4 ) ) )
// InternalReflex.g:4651:1: ( ( rule__Port__SizeAssignment_4 ) )
{
... | [
"public final void rule__ECapabilityAssignment__Group__4() throws RecognitionException {\n\n \t\tint stackSize = keepStackSize();\n \t\n try {\n // InternalAADMParser.g:5287:1: ( rule__ECapabilityAssignment__Group__4__Impl )\n // InternalAADMParser.g:5288:2: rule__ECapabil... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Transfer Ipv4 address from long to String in dot format | private String longToIpv4(long Ipv4long){
String IpStr = "";
final long mask = 0xff;
IpStr = Long.toString(Ipv4long & mask);
for (int i = 1; i < 4; ++i){
Ipv4long = Ipv4long >> 8;
IpStr = (Ipv4long & mask) + "." + IpStr;
}
return IpStr;
} | [
"private static String ipv4ToString(byte[] address) {\n Logger log = getLogger();\n // This code was modeled after similar code in Sun's sun.security.x509.IPAddressName,\n // used by sun.security.x509.X509CertImpl.\n StringBuilder builder = new StringBuilder();\n byte[] ip = new b... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Populates the list of groups to display to the UI thread. | protected void updateGroupData() {
if (!mGroupList.isEmpty()) {
mAdapter.notifyDataSetChanged();
// If we did not load 8 groups, we are at the end of the list, so signal
// not to try to load more groups.
if (mGroupList.size() - mCurrentAmountShown < 8) {
... | [
"private void populateListView() {\n List<String> groupNames = new ArrayList<String>();\n for (Pair<String, Group> pair : savedGroups) {\n groupNames.add(pair.first);\n }\n if (groupsListAdapter != null) {\n groupsListAdapter.clear();\n groupsListAdapter.... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
A reference to a field on an object, given by exp. Class containing the object is given by classType. | public FieldRef(Expression exp, Type classType, String fieldName, Type fieldType)
throws ClassException
{
addJavaNode(exp);
constant = new FieldRefConstant(classType, fieldName, fieldType);
expressionType = fieldType;
} | [
"public static MemberExpression field(Expression expression, Class type, String fieldName) { throw Extensions.todo(); }",
"FieldReference getFieldReference();",
"public FieldRef(Type classType, String fieldName, Type fieldType, boolean staticRef) \n throws ClassException\n {\n this.staticRef = staticRe... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
This is a bit awkward, but we need to get the card set name and internal ID for the item in the list that was selected. We can get this using the AdapterContextMenuInfo. The ID is easy enough; that's part of the info object. The name, however, we'll have to get by getting the target view and getting the display text fr... | @Override
public boolean onContextItemSelected(MenuItem item) {
AdapterContextMenuInfo info =
(AdapterContextMenuInfo)item.getMenuInfo();
TextView tv = (TextView)info.targetView;
selectedCardsetName = tv.getText().toString();
selectedCardsetID = info.id;
// Now let's see which item in the context menu ... | [
"String getSelectedItemDesc();",
"String getSelectedItemOwner();",
"@Override\n public void onCreateContextMenu(ContextMenu menu, View v, ContextMenuInfo menuInfo){\n super.onCreateContextMenu(menu,v,menuInfo);\n GridView gv = (GridView) v;\n AdapterContextMenuInfo info = (AdapterContext... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
repeated .CEcon_GetAssetClassInfo_Request.Class classes = 3; | public Builder addClasses(SteammessagesEconSteamclient.CEcon_GetAssetClassInfo_Request.Class value) {
if (classesBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureClassesIsMutable();
classes_.add(value);
onChanged();
... | [
"SteammessagesEconSteamclient.CEcon_GetAssetClassInfo_Request.Class getClasses(int index);",
"java.util.List<SteammessagesEconSteamclient.CEcon_GetAssetClassInfo_Request.Class> \n getClassesList();",
"java.util.List<? extends SteammessagesEconSteamclient.CEcon_GetAssetClassInfo_Request.ClassOrBuilder> \n... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Tracks minimal elements of an ordered set. | public interface MinTracker<T> {
/** Compares an element x of a set to the current list of minimal elements
* and modifies the set of minimal elements accordingly.
*
* @param x */
void digest(T x);
/** Retrieves the current set of minimal elements.
*
* @return Collection<T> of minimal elements *... | [
"Collection<T> getMinElements();",
"public void smallest() throws IntegerSetException{\r\n\t\t\t\tif(set.isEmpty()) {\r\n\t\t\t\t\tthrow new IntegerSetException(\"This list is empty so there is no smallest integer.\");\r\n\t\t\t\t}\r\n\t\t\t\telse {\r\n\t\t\t\t\tArrayList<Integer> sortedList = new ArrayList<Integ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Radio button Animal Injury or Death is selected as per parameter | public void selectAnimalInjury (String strAnimalInjury)
{
if (strAnimalInjury.equalsIgnoreCase ("Yes") || strAnimalInjury.equalsIgnoreCase ("Y"))
{
List<WebElement> radiobuttons = orClaimClaimantDetails.rdoAnimalInjury;
for (WebElement radiobutton : radiobuttons)
{
if (radiobutton.getAttribut... | [
"public void selectPersonalInjury (String strPersonalInjury)\r\n\t{\r\n\r\n\t\tif (strPersonalInjury.equalsIgnoreCase (\"Yes\") || strPersonalInjury.equalsIgnoreCase (\"Y\"))\r\n\t\t{\r\n\t\t\tList<WebElement> radiobuttons = orClaimClaimantDetails.rdoPersonalInjury;\r\n\t\t\tfor (WebElement radiobutton : radiobutto... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Click on the Create button to create a template. | public void clickOnCreateMyTemplateButton() {
extentTest.log(Status.INFO, "Click on the Create button to create a template.");
createBtn.click();
} | [
"public void clickCreateButton() {\n this.action.click(this.createButton);\n }",
"public void clickCreateNewTask()\r\n\t {\r\n\t\t createNewTask.click();\r\n\t }",
"@Step\r\n\tpublic void clickCreateAccountButton() {\r\n\t\tLOGGER.info(\"Clicking Create Acount button\");\r\n\t\tCreateAccountButton.cli... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Updates the m b mobile phone in the database or adds it if it does not yet exist. Also notifies the appropriate model listeners. | @Indexable(type = IndexableType.REINDEX)
public MBMobilePhone updateMBMobilePhone(MBMobilePhone mbMobilePhone)
throws SystemException {
return updateMBMobilePhone(mbMobilePhone, true);
} | [
"private void updatePhones() {\n\t\t\n\t\tint result = phoneRepository.setPhoneNumber(TypePhone.RESIDENCIAL, 1L);\n\t\tSystem.out.println(\"Result = \" + result);\n\t\t\n\t}",
"public void updateUserPhone(int idUser, String phone) throws PersistenceException;",
"public MBMobilePhone createMBMobilePhone(long id)... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Adds an an edge to the internal Configuration object using a string representation. If a, b are nodes then "a b" specifies a normal edge and "a = b" an optional edge. See teo.isgci.smallgraph.Configuration.toString(). | private void addEdgeFromString(String edge) {
String[] nodes;
boolean optional = false;
if (edge.contains(normalEdgeSep)) {
nodes = edge.replace(" ", "").split(normalEdgeSep);
} else if (edge.contains(optionalEdgeSep)) {
nodes = edge.replace(" ", "").split(option... | [
"public IEdge addEdge(String from, String to, Double cost);",
"void addEdge(Edge e);",
"void addEdge(E edge);",
"void setEdgeLabel(int edge, String label);",
"public void setEdgeConfig(EdgeConfig edgeConfig) {\n this.edgeConfig = edgeConfig;\n }",
"public void addEdge(E e){\n\t\tedges.add(e);\n\... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Return a PrintStream writing to the file named NAME. | private PrintStream getOutput(String name) {
try {
return new PrintStream(new File(name));
} catch (IOException excp) {
throw error("could not open %s", name);
}
} | [
"private static PrintStream openStream(String fn, String name)\n throws IOException {\n try {\n\n PrintStream newStream\n = new PrintStream(new java.io.FileOutputStream(fn));\n if (name != null) {\n System.err.println(name + \" written to \" ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Returns an immutable copy of the input graph. | public static <N, E> ImmutableUndirectedGraph<N, E> copyOf(UndirectedGraph<N, E> graph) {
return new Builder<N, E>(graph).build();
} | [
"public Graph copy();",
"public weighted_graph copy();",
"protected OrderEquivalenceGraph deepCopyGraph() {\n return deepCopyGraph(graph);\n }",
"private DGraph copy(OOP_DGraph g) {\r\n\t\tDGraph newGraph = new DGraph();\r\n\t\tfor (oop_node_data n : g.getV()) {\r\n\t\t\tnewGraph.addNode(new node(n.... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Sets the paper value of this science app paper. | @Override
public void setPaperValue(java.lang.String paperValue) {
_scienceAppPaper.setPaperValue(paperValue);
} | [
"@Override\n\tpublic void setPaperSeq(long paperSeq) {\n\t\t_scienceAppPaper.setPaperSeq(paperSeq);\n\t}",
"@Override\n\tpublic java.lang.String getPaperValue() {\n\t\treturn _scienceAppPaper.getPaperValue();\n\t}",
"public void setPaper_id(String paper_id) {\n this.paper_id = paper_id;\n }",
"@Over... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Get the configured job role parameter TODO move this code and the batch parameter parsing to a parameters factory. Add validation in the DSL if one required param is missing. | public String getJobRoleParameter() {
var parameterValue = this.batchParametersProvider.getParameter("job.role");
return parameterValue.getValue().getPath();
} | [
"String getRequiresRole();",
"com.message.MessageInfo.RoleVOOrBuilder getRoleOrBuilder();",
"Role getRole(String roleName);",
"@ApiModelProperty(required = true, value = \"The role that the place plays, e.g. \\\"UNI Site\\\", or \\\"ENNI Site\\\".\")\n @NotNull\n\n\n public String getRole() {\n return ro... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
/ Convert Distance from a given unit and a given amount to a list of amounts in other units | public ArrayList<String> Distance(String from, float amount, String[] units) {
from = findFrom(from);
if (from.equals("meter")) {
ArrayList<String> kaduvil = new ArrayList<String>();
kaduvil.add("" + amount + " " + units[0] );
kaduvil.add("" + amount / 1000 + " " + units[1] );
kaduvil.add("" + amount * ... | [
"private double convertDistUnits(double inputDistance) {\r\n if (((String)radialDistUnitsCombo.getSelectedItem()).equals(\"Kilometers\")) {\r\n return inputDistance;\r\n }\r\n else if (((String)radialDistUnitsCombo.getSelectedItem()).equals(\"Miles\")) {\r\n return inputDi... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Show an error dialog, production cycle is less than the minimal production cycle | private void showErrorMinimalProductionCycleAlert() {
Alert alert = new Alert(AlertType.ERROR);
alert.setTitle("Fehler");
alert.setHeaderText("Fehler in den Eingabedaten");
alert.setContentText("Optimaler gemeinsamer Produktionszyklus ist kleiner als minimaler zulässiger Produktionszyklus! Bitte korrigieren Sie... | [
"private void showErrorMessage()\n\t{\n\t\tJOptionPane.showMessageDialog(this, \"Attack strength must be greater than defense strength and cannot equal 0.\", \"Invalid Input\", JOptionPane.OK_OPTION);\n\t}",
"protected void showError(){\n JOptionPane.showMessageDialog(null, message, \"Error\", JOptionPane.... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Returns the number of v cals where userId = &63; and startDate = &63; and status = &63;. | public int countByU_D_S(long userId, Date startDate, long status)
throws SystemException {
Object[] finderArgs = new Object[] { userId, startDate, status };
Long count = (Long)FinderCacheUtil.getResult(FINDER_PATH_COUNT_BY_U_D_S,
finderArgs, this);
if (count == null) {
StringBundler query = new StringB... | [
"public int countByF_D_G_U(long userId, Date startDate, long groupId,\n\t\tlong status) throws SystemException {\n\t\tObject[] finderArgs = new Object[] { userId, startDate, groupId, status };\n\n\t\tLong count = (Long)FinderCacheUtil.getResult(FINDER_PATH_COUNT_BY_F_D_G_U,\n\t\t\t\tfinderArgs, this);\n\n\t\tif (co... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Returns the major version of Java as simple integer, i.e. "8" for JDK 1.8, "11" for JDK 11, "12" for JDK 12 and so on. | public static int getJDKVersion() {
return Integer.parseInt(System.getProperty("java.version").replaceAll("^(?:1\\.)?(\\d+).*", "$1"));
} | [
"public static int getMajorJavaVersion() {\n String javaVersion = System.getProperty(\"java.version\");\n // javaVersion should be something like \"1.7.0_25\"\n String[] version = javaVersion.split(\"\\\\.\");\n if (version.length > 2) {\n int majorVersion = Integer.parseInt(v... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Returns this player's expedition in the given suit | Expedition getExpedition(Suit suit); | [
"public Suit getSuit () {\r\n return suit;\r\n }",
"public String getSuit() {\n return suit;\n }",
"public int getSuit() {\n return suit;\n }",
"public char getSuit()\n\t{\n\t\treturn suit;\n\t}",
"public int getSuitInt()\r\n {\r\n return suit;\r\n }",
"public String getSu... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Dynamically determine the classpath, based on the user preference settings for extension directories | private static URL[] getClassPath() {
Preferences userPrefs = Preferences.userNodeForPackage(BoomBox.class);
File userExtDir = new File(userPrefs.get("", Hardcoded.USER_EXTENSION_DIR));
List<URL> classpath = Collections.emptyList();
File[] jarFiles = null;
if (userExtDir.isDirectory()) {
... | [
"public String getSystemClassPath();",
"private static String inferClasspath() {\n final String pathsep = System.getProperty(\"path.separator\");\n ClassLoader leaf = Webservice.class.getClassLoader();\n final ClassLoader root = ClassLoader.getSystemClassLoader().getParent();\n final S... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
asks the player the map | public int askMap(); | [
"private synchronized void askMap() throws RemoteException, Exception{\n //removing the non active players\n removeDisconnectedPlayers();\n\n matchController.getMatch().setMatchIsActive(true);\n //this code is useful for having the master always in first position (he doesn't know lol)\n ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Mutate the given solution. | public BitvectorSolution mutate(BitvectorSolution child); | [
"void mutate(T solution);",
"public void mutate(Solution solution) {\n int size = solution.values.length;\n int first = random.nextInt(size-1);\n int second = first + random.nextInt(size-first);\n\n int firstCopy = solution.values[first];\n solution.values[first] = solution.valu... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Used by listeners in constructing instances of PPProc. A PEND statement is optional, when absent the listener manually sets the endLine for this PPProc. | public void setEndLine(int endLine) {
this.endLine = endLine;
} | [
"public void endOfParagraph() {}",
"@Override\n\tprotected void endOfLine() {\n\t}",
"public void endOfSentence() {}",
"public void setEndLine(int endLine) {\r\n this.endLine = endLine;\r\n }",
"ProcedureSection createProcedureSection();",
"public void endLine() {\n if (currentLine !=... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Determine if the AntPattern is configured. | public boolean isSetAntPattern() {
return ((this.antPattern != null) && (!this.antPattern.isEmpty()));
} | [
"public boolean hasAnt() {\r\n\t\treturn this.ant != null;\r\n\t}",
"public static Predicate<String> ant(final String antPattern) {\n return new Predicate<String>() {\n @Override\n public boolean test(String input) {\n PathContainer pathContainer = PathContainer.parsePa... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
/deleteSite() Delete api/site Site Id to be deleted JSON array of all site instances | @DELETE
@Produces("application/json")
@Path("/{ID}")
public List<Site> deleteSite(@PathParam("ID") int siteId){
return siteDaoObj.removeSite(siteId);
} | [
"DeleteSiteResult deleteSite(DeleteSiteRequest deleteSiteRequest);",
"@DELETE(CoreConstant.CORE_PUBLIC_API_V1 + \"/sites/{siteId}\")\n Call<Void> deleteSiteCall(@Path(\"siteId\") String siteId);",
"@Test\n\t@DatabaseSetup(\"site-test/create-site-data-initial.xml\")\n\t@DatabaseTearDown(\"site-test/generic-te... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Add Staff Member to the database | public int addStaff(Staff staff) {
String sql = "INSERT INTO STAFF VALUES (?,?,?,?,?,?,?,?,?,?)";
return jdbcTemplate.update(sql, new PreparedStatementSetter() {
@Override
public void setValues(PreparedStatement ps) throws SQLException {
ps.setObject(1, null);
ps.setString(2, staff.getName());
... | [
"public void addStaff(Staff staff);",
"public void addStaff(String name, String dob, String email, String number, String address, String password) throws SQLException { //code for add-operation \n st.executeUpdate(\"INSERT INTO IOTBAY.STAFF \" + \"VALUES ('\" \n + name ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
$ANTLR end "rule__OpOther__Group_4__1__Impl" $ANTLR start "rule__OpOther__Group_4_1_0__0" ../de.nie.fin.ui/srcgen/de/nie/fin/ui/contentassist/antlr/internal/InternalFin.g:7907:1: rule__OpOther__Group_4_1_0__0 : rule__OpOther__Group_4_1_0__0__Impl ; | public final void rule__OpOther__Group_4_1_0__0() throws RecognitionException {
int stackSize = keepStackSize();
try {
// ../de.nie.fin.ui/src-gen/de/nie/fin/ui/contentassist/antlr/internal/InternalFin.g:7911:1: ( rule__OpOther__Group_4_1_0__0__Impl )
// ../... | [
"public final void rule__OpOther__Group_6_1_0__0() 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:5357:1: ( rule__O... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Test method for 'com.elasticpath.domain.dataimport.impl.AbstractImportTypeImpl.equals(ImportType)'. | @Test
public void testEqualsImportType() {
assertFalse(AbstractImportTypeImpl.INSERT_UPDATE_TYPE.equals(AbstractImportTypeImpl.UPDATE_TYPE));
} | [
"@Test\n\tpublic void testEqualsObject() {\n\t\tassertFalse(AbstractImportTypeImpl.INSERT_UPDATE_TYPE.equals(new Object()));\n\t}",
"@Test\n\tpublic void testHashCode() {\n\t\tassertTrue(AbstractImportTypeImpl.UPDATE_TYPE.hashCode() != AbstractImportTypeImpl.INSERT_TYPE.hashCode()); // NOPMD\n\t}",
"@Test\n\tpu... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Updates the rover's position within the tilemap, ready for the next frame Simulation is stopped if the rover has hit a rock or gone out of bounds | public void updateRover()
{
//If reached the end of the simulation
if(iFrame >= frames.size())
{
Rover.getRover().finished();
}
//If rover is attempting to go outside the level boundary
else if (roverX + frames.get(iFrame).x >= MAX_COLUMNS //Too far right
... | [
"@Override\n public void update(){\n getNextPosition();\n checkTileMapCollision();\n setPosition(xtemp, ytemp);\n animation.update();\n }",
"private void updateMap() throws GameActionException{\n Robot[] nearbyRobots = r.rc.senseNearbyGameObjects(Robot.class, 14);\n // Proc... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Lists the Compute Nodes Extensions in the specified Pool. | Observable<ServiceResponseWithHeaders<Page<NodeVMExtension>, ComputeNodeExtensionListHeaders>> listWithServiceResponseAsync(final String poolId, final String nodeId); | [
"Observable<Page<NodeVMExtension>> listAsync(final String poolId, final String nodeId, final ComputeNodeExtensionListOptions computeNodeExtensionListOptions);",
"Observable<ServiceResponseWithHeaders<Page<NodeVMExtension>, ComputeNodeExtensionListHeaders>> listWithServiceResponseAsync(final String poolId, final S... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
/ Processes a dial request from a Rayo Client | private void processDialRequest(IQRequest request) throws Exception {
if (getAdminService().isQuiesceMode()) {
log.warn("Gateway is on Quiesce mode. Discarding incoming dial request: [%s]", request);
sendIqError(request, Type.CANCEL, Condition.SERVICE_UNAVAILABLE, "Gateway Server is on Quiesce Mode");
ret... | [
"public void processRequest(){\n\t\tCommandArgument argument = readFromClient();\n\t\tCommandResponse response = processArgument(argument);\n\t\tsendResponse(response);\n\t}",
"void processCall(CallRequest callRequest);",
"public Object handleCommandResponse(Object response) throws RayoProtocolException;",
"v... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Constructor de la EntidadFinancieraDAO que recibe como parametro un EntityManager | public EntidadFinancieraDAO(EntityManager entityManager) {
this.entityManager = entityManager;
} | [
"public AndamentoProcessoDAO() {\n }",
"public EmpresaDAOHibernate() {\r\n\t\t// TODO Auto-generated constructor stub\r\n\t}",
"public PacienteDAO(){ \n }",
"public JpaDAO() {\r\n\t}",
"public BemRegistroDAOImpl() {\n\t\tsuper(BemRegistro.class, NOME_COMANDO_PESQUISAR, NOME_COMANDO_CONSULTAR_IDDB2)... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
If the connected Gerrit is a snapshot version. | @SuppressWarnings("unused")
//called from jelly
public boolean isGerritSnapshotVersion() {
return gerritSnapshotVersion;
} | [
"public boolean isSnapshotVersion( )\n {\n return Version.isSnapshot( getCurrentVersion( ) );\n }",
"public static boolean isSnapshotVersion() {\n\t\treturn getShortVersion().toLowerCase().startsWith(\"snapshot\");\n\t}",
"Boolean checkForSnapshot(Model model) {\n return model.getVersion().c... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Gets the value of the 'field868' field. doc for field868 | public java.lang.CharSequence getField868() {
return field868;
} | [
"public java.lang.CharSequence getField868() {\n return field868;\n }",
"java.lang.String getField1164();",
"java.lang.String getField1571();",
"java.lang.String getField1558();",
"public java.lang.CharSequence getField795() {\n return field795;\n }",
"public java.lang.CharSequence getField974... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Remove all of the elements from both the Map and the linked list implementation. Overrides base class. | public synchronized void removeAll() throws IOException
{
map.clear();
for ( MemoryElementDescriptor me = first; me != null; )
{
if ( me.prev != null )
{
me.prev = null;
}
MemoryElementDescriptor next = me.next;
me = next;
}
first = last = null;
... | [
"public void removeAllElementInsertionMaps()\n {\n list.removeAllElements();\n }",
"public void removeAll()\n\t{\n\t\tObject [] oldContents = keys;\n\t\tfinal int oldCapacity = capacity;\n\t\tfor (int i = 0; i < oldCapacity; i += 1)\n\t\t{\n\t\t\tTriple t = (Triple)oldContents[i];\n\t\t\tif (t != null) \... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Clears the value of the 'TRG_CRT_DT_PART_UTC' field. | public org.LNDCDC_NCS_TCS.SHOWS.apache.nifi.LNDCDC_NCS_TCS_SHOWS.Builder clearTRGCRTDTPARTUTC() {
TRG_CRT_DT_PART_UTC = null;
fieldSetFlags()[59] = false;
return this;
} | [
"public org.LNDCDC_ADS_PRPSL.PRPSL_OTLT.apache.nifi.LNDCDC_ADS_PRPSL_PRPSL_OTLT.Builder clearTRGCRTDTPARTUTC() {\n TRG_CRT_DT_PART_UTC = null;\n fieldSetFlags()[16] = false;\n return this;\n }",
"public org.LNDCDC_ADS_PRPSL.PROPOSAL_LINE.apache.nifi.LNDCDC_ADS_PRPSL_PROPOSAL_LINE.Builder clearTR... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Validates the contents of the regions property of the given member. | private void validateRegions(Member member) {
Set<Region> regionSet = new HashSet<Region>();
regionSet.addAll(member.getRegions());
if (regionSet.size() != member.getRegions().size()) {
throw new IllegalArgumentException("member has duplicate regions");
}
} | [
"private void validateRegionsSize(Member member) {\n if (member.getRegions().size() < getMinRegions()) {\n throw new TooFewRegionsException(getMinRegions());\n }\n if (member.getRegions().size() > getMaxRegions()) {\n throw new TooManyRegionsException(getMaxRegions());\n }\n }",
"protected ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Load the poster image. | public void loadPoster(String url) {
if (url == null) {
Message message = obtainMessage(LOAD_DEFAULT_POSTER);
sendMessage(message);
return;
}
// Cancel any active poster download.
if (mPosterDownloader != null) {
mPosterDownloader.cancelAnd... | [
"private void initializePoster() {\n Picasso.with(this)\n .load(VIDEO_POSTER)\n .placeholder(R.drawable.backgroud_viettel_id_account_info)\n .into(posterImageView);\n Picasso.with(this)\n .load(VIDEO_THUMBNAIL)\n .placeholder(R... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Set the value of senha | public void setSenha(String senha) {
this.senha = senha;
} | [
"public void setUsSenha(String pUsSenha){\n this.usSenha = pUsSenha;\n }",
"public String getSenha() {\n return senha;\n }",
"void setPassword(String senha);",
"private void exibirSenha() {\n if (exibeSenha) {\n txtSenha.setTransformationMethod(PasswordTransformationMetho... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
returns true if distance is in critial threshold and false otherwise REQUIRES: 'a' is valid EFFECTS: returns whether or not 'this' and 'a' are colliding | boolean collide(Airplane a){
double dist = getDistance(a.x, a.y);
return dist-girth-a.girth < 0;
} | [
"public int thereIsCollision() { \n\t\tint impact = NO_COLLISION;\n\t\tfor (int i = 0; i < getObjectives().size(); i++) {\n\t\t\tif ((getPlayingBall().isTouching(getObjective(i)))) {\n\t\t\t\tif (getPlayingBall().getColor() == getObjective(i).getColor()) {\n\t\t\t\t\texplodeBall(i);\n\t\t\t\t\tnewPlayingBall();\n\t... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Called to determine whether the given line of text is a personal tell and to further process it if it is. | private boolean handlePersonalTell(String line){
if (line.indexOf("tells you: ") == -1)
return false;
Matcher matcher = PERSONAL_TELL_REGEX.matcher(line);
if (!matcher.matches())
return false;
String username = matcher.group(1);
String titles = matcher.group(2);
String message ... | [
"private boolean handlePTell(String line){\n if (line.indexOf(\"(your partner) tells you: \") == -1)\n return false;\n \n Matcher matcher = PTELL_REGEX.matcher(line);\n if (!matcher.matches())\n return false;\n\n String username = matcher.group(1);\n String titles = matcher.group(2);\n ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
set the line width to the line chart the width can change with regard to the amount of data | private void setLineChartLineWidth() {
Set<Node> lineNodes = lineChart.lookupAll(".chart-series-line");
for (Node node : lineNodes) {
double width = 3 / Math.log10(CsvData.TickerData.size());
String style = "-fx-stroke-width: " + width + "px;";
node.setStyle(style);
... | [
"public void setLineWidth ( int width ) {\r\n\t\tline_width = width;\r\n\t}",
"int LineSetWidth(int id, int width);",
"void setLineWidth(float width) { }",
"public void setLineWidth(int width) {\n mPaintLine.setStrokeWidth(width);\n }",
"void setLineThickness(int thickness);",
"public int getLin... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
a cleanup method used to delete any temporary arrays used to pass parameters to an invoked remote method. No parameters or return. | public static native void deleteAllTempArrays(); | [
"private void cleanup()\n\t{\n\t}",
"protected void cleanup() {\n }",
"public void cleanupCalls() {\n // no base implementation\n }",
"@Override\n protected void cleanup() {\n bundle.setParameter(BundleParameter.NODE_BUNDLE_ELAPSED_PARAM, accumulatedElapsed.get());\n this.dataProvider = nu... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Allows a custom market data provider to be specified. | public void setMarketDataProvider(MarketDataProvider marketDataProvider) {
this.marketDataProvider = marketDataProvider;
} | [
"public void setMarketDataProvider(MarketDataProvider marketDataProvider) {\n this.marketDataProvider = marketDataProvider;\n }",
"private MarketDataProvider getMarketDataProviderForName(String inProviderName)\n {\n populateProviderList();\n return activeProvidersByName.get(inProviderNa... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
gets this spritesheet animatedsprite current ID. | public int getSpriteID() {
return currentAnimatedspriteID;
} | [
"public int getSpriteID()\n\t{\n\t\treturn this.spriteID;\n\t}",
"public BufferedImage getCurrentSprite() {\n\treturn this.sprites[currentAnimatedspriteID].get();\n }",
"public ImageIdentifier getImageIdentifier() {\n synchronized (this.imageLock) {\n return this.animation.getCurrentImage()... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Tests the getBackground method for map. | public void testGetBackground()
{
assertNotNull( map.getBackground() );
} | [
"@Test\r\n\tpublic void testGetBackground() {\r\n\t\tp1 = new Player(\"Tom\", 120, 130);\r\n\t\tm = MapParser.parse(\"MapTest\", p1);\r\n\t\tp1.setMap((Map) m);\r\n\r\n\t\tassertEquals(\"MapTest\", m.getBackgroundLayer());\r\n\t}",
"private Background createBackground() {\n // Create and fill the image arr... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Returns true if x,y is out of bounds. | private boolean outOfBounds( int x, int y )
{
return ! xInBounds( x ) || ! yInBounds( y );
} | [
"private boolean outOfBounds(int x, int y) {\n return (x < 0 || x >= size) || (y < 0 || y >= size);\n }",
"public boolean outOfBound(int x, int y) {\n if (x >= 0 && x <= (Chess.BOARD_SIZE_X - 1)) {\n if (y >= 0 && y <= (Chess.BOARD_SIZE_Y - 1)) {\n return false;\n }\n }\n return tru... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Sets the value of the 'field246' field | public com.maxpoint.cascading.avro.TestExtraLarge.Builder setField246(java.lang.CharSequence value) {
validate(fields()[246], value);
this.field246 = value;
fieldSetFlags()[246] = true;
return this;
} | [
"public void setField246(java.lang.CharSequence value) {\n this.field246 = value;\n }",
"public void setField(FIELD theField);",
"public void setField248(java.lang.CharSequence value) {\n this.field248 = value;\n }",
"public void setField789(java.lang.CharSequence value) {\n this.field789 = value;\... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
A shot is fired by the spaceship and added to the list of shots. | private void fire() {
testShot shot = new testShot();
shot.x = spaceship.getX() + 5;
shot.x2 = spaceship.getX() + 50;
shot.y = spaceship.getY();
shotList.add(shot);
} | [
"public void addShot (Shot newShot){\n listShots.add(newShot);\n }",
"public void shoot()\n\t{\n\t\thas_shot = true;\n\t\t//parent.println(ship_name + \" has fired a shot\");\n\t\tshot = new Shot(parent, points[0].x, points[0].y, angle);\n\t}",
"public SpaceShipShotListener(List<Ball> shots, GameLevel... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Returns a permutation, if this projection is merely a permutation of its input fields, otherwise null. | public Permutation getPermutation()
{
final int fieldCount = rowType.getFieldList().size();
if (fieldCount != getChild().getRowType().getFieldList().size()) {
return null;
}
Permutation permutation = new Permutation(fieldCount);
for (int i = 0; i < fieldCount; ++i... | [
"public List<Module> permutation() {\n\t\treturn permutation;\n\t}",
"public static boolean[] permutationP(BitSet[] input) {\n\t\tboolean temp[];\n\t\tboolean output[];\n\t\tint row, column, index, j;\n\n\t\tindex = 0;\n\t\ttemp = new boolean[32];\n\t\toutput = new boolean[32];\n\t\tfor (row = 0; row < 8; row++) ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Perform am URI query parameter (name or value) escape operation on a String input using UTF8 as encoding. The following are the only allowed chars in an URI query parameter (will not be escaped): AZ az 09 . _ ~ ! $ ' ( ) , ; | public static String escapeUriQueryParam(final String text) {
return escapeUriQueryParam(text, DEFAULT_ENCODING);
} | [
"String urlParamEncode(String value);",
"public static String escapeUriQueryParam(final String text, final String encoding) {\n if (encoding == null) {\n throw new IllegalArgumentException(\"Argument 'encoding' cannot be null\");\n }\n return UriEscapeUtil.escape(text, UriEscapeUti... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Sets marble in excess. | public void setMarbleInExcess(Marble marbleInExcess) {
this.marbleInExcess = marbleInExcess;
} | [
"public void setExcessMeat(double excessMeat) {\n\t\tthis.excessMeat = excessMeat;\n\t}",
"public void fillWaterbottle(){\n amountRemaining = MAX_AMOUNT;\n }",
"private void moveRemainingMarbles() {\n int player1Marbles = this.player1MarbleCount();\n int player2Marbles = this... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
$ANTLR end "ruleProcessGeneration" $ANTLR start "entryRuleStepGeneration" InternalDsl.g:10151:1: entryRuleStepGeneration returns [EObject current=null] : iv_ruleStepGeneration= ruleStepGeneration EOF ; | public final EObject entryRuleStepGeneration() throws RecognitionException {
EObject current = null;
EObject iv_ruleStepGeneration = null;
try {
// InternalDsl.g:10151:55: (iv_ruleStepGeneration= ruleStepGeneration EOF )
// InternalDsl.g:10152:2: iv_ruleStepGeneration=... | [
"public final EObject entryRuleProcessGeneration() throws RecognitionException {\n EObject current = null;\n\n EObject iv_ruleProcessGeneration = null;\n\n\n try {\n // InternalDsl.g:10101:58: (iv_ruleProcessGeneration= ruleProcessGeneration EOF )\n // InternalDsl.g:10102:... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
find perfect powers upto n | public static void Perfectpower(int n) {
long valuecheck = 0;
PriorityQueue<PerfectNumber> pq = new PriorityQueue<>(new Comparator<PerfectNumber>() {
@Override
public int compare(PerfectNumber o1, PerfectNumber o2) {
return (int) (o1.value - o2.value);
}
});
//base condition
pq.add(new Perfec... | [
"private int nextPowerOf2(int n)\n {\n if (n > 0 && (n & (n - 1)) == 0)\n return n;\n \n int count = 0;\n for (;n != 0; n = n >> 1)\n count += 1;\n \n return 1 << count;\n }",
"public static int powerOf2(int n){\n int counter=1;\n while (n != 1){\n n=n>>1;\n ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Request the editor to load the file currently opened. | public void loadFile()
{
bjEditor.reloadFile();
} | [
"private IEditorPart openEditor(){\n\t\tshell.getDisplay().syncExec(new Runnable() {\n\t\t\tpublic void run() {\n\t\t\t\tIWorkbenchPage page = PlatformUI.getWorkbench()\n\t\t\t\t\t\t.getActiveWorkbenchWindow().getActivePage();\n\t\t\t\ttry {\n\t\t\t\t\tif (currentlySelectedFile.exists())\n\t\t\t\t\topenedEditor = I... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Builds default consumer's properties, and applies custom configurations if any. Note: custom configuration properties will be populated after and additional/overridden to the default configuration. | public static Properties buildKafkaConsumerProps(String bootstrapServers,
String consumerGroupId, boolean consumeFromBeginning, boolean autoCommitOffsets,
Properties customProps) {
Properties props = new Properties();
props.put(ConsumerConfig.BOOTSTRAP_SERVERS_CONFIG, bootstrapSe... | [
"private Properties buildConsumerProperties() {\n Properties properties = new Properties();\n properties.put(ConsumerConfig.BOOTSTRAP_SERVERS_CONFIG, this.kafkaConfig.server);\n properties.put(ConsumerConfig.GROUP_ID_CONFIG, String.format(\"%s-%s-sub\", DEFAULT_ID, UUID.randomUUID().toString())... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |