query
stringlengths
8
1.54M
document
stringlengths
9
312k
negatives
listlengths
19
20
metadata
dict
This method was generated by MyBatis Generator. This method corresponds to the database table temperature_measure_hitch_event1
int updateByPrimaryKey(TemperatureMeasureHitchEvent record);
[ "TemperatureMeasureHitchEvent selectByPrimaryKey(String id);", "int insert(TemperatureMeasureHitchEvent record);", "int insertSelective(TemperatureMeasureHitchEvent record);", "public abstract String getMetricIdSql();", "EventTable getEventTable();", "protected abstract String getNextEventTimeSql();", "...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
This method was generated by MyBatis Generator. This method sets the value of the database column checkmain_table.checkMainID
public void setCheckMainID(Long checkMainID) { this.checkMainID = checkMainID; }
[ "public Long getCheckMainID() {\n return checkMainID;\n }", "public void setMainCode(Long mainCode) {\n this.mainCode = mainCode;\n }", "public void setMainTargetId(Long mainTargetId) {\n this.mainTargetId = mainTargetId;\n }", "public void setMainFlag(Boolean mainFlag) {\n ...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Method to see if two items are in the room.
public boolean hasItem2() { if (mapItems.size() <= 1 || items == null) { return false; } return true; }
[ "public boolean atRocket() {\r\n\t\tif (currentRoom == rooms.get(new Tuple(2,2)))\r\n\t\t\treturn true;\r\n\t\treturn false;\r\n\t}", "boolean overlap(ArrayList<Room> rooms, Room ra) {\n for (Room rb : rooms) {\n if (ra.x1 < rb.x2 && ra.x2 > rb.x1 && ra.y1 > rb.y2 + 1 && ra.y2 + 1 < rb.y1) {\n ...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Helper to update the line number in the code to the line number on which this AstNode began.
protected void updateLineNumber(Code code) { code.updateLineNumber(Source.calculateLine(getStartPosition())); }
[ "public LineNumber() {\n\t\tcurrentPosition.add(0,1);\n\t}", "int getStartLineNumber();", "public static void RecalculateLineNumber(TargetCode nowTargetCode) {\n\t\tnowTargetCode.setLineNumber(0);\n\t\tfor (int j = 0; j < nowTargetCode.codeSize(); j++) {\n\t\t\tCode code = nowTargetCode.getCodeByIndex(j);\n\t\t...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Creates new shadows off a given shadowmap size and the number of splits to calculate
public void setShadows(AssetManager am, int shadowMapSize, int nbSplits){ shadow = new DirectionalLightShadowFilter(am, shadowMapSize, nbSplits); shadow.setLight(sun.getLight()); }
[ "public ShadowMap( int size ) { \n depthFBOSize = new Dimension(size,size);\n }", "public void populateShadow() {\n try {\n mLightSources = SpotShadowVertexCalculator.calculateLight(\n mShadowConfig.getLightRadius(),\n mShadowConfig.getLight...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
get and set token
public void setToken(int value){token = value;}
[ "public void setToken(java.lang.String token) {\n this.token = token;\n }", "public java.lang.String getToken() {\n return token;\n }", "public void initializeToken();", "public void setToken(){\n final AuthenticationRequest request = getAuthenticationRequest(AuthenticationResponse....
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
This returns the enum of the BarColor
public BarColor getBarColor(){ return color; }
[ "public BarColumnColor getBarColumnColor() {\n\t\treturn bcColor;\n\t}", "public Color getDragBarColor(){\n\treturn barColor;\n }", "public static Image getCOBar(int color){\r\n return coBars[color];\r\n }", "public int getColorValue(){\n return Color.parseColor(value);\n }", "public ...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
draws a wildcardmatched amount of fluid from the container. the combined sum of the volumes of each of the fluids is not guaranteed to be the same as the fraction passed.
FluidContainer draw(Fraction fraction);
[ "void setFluidContents(int volume);", "public static FluidIngredient of(Fluid fluid, int amount) {\n return new FluidIngredient.FluidMatch(fluid, amount);\n }", "default int calculateFluidVolume(double fluidHeight) {\n double f = (fluidHeight - this.getMinFluidHeight())/(this.getMaxFluidHeight() - th...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
This method was generated by MyBatis Generator. This method returns the value of the database column TRSSETLMT_NIDC_DET.ACCRUED_PROFIT
public BigDecimal getACCRUED_PROFIT() { return ACCRUED_PROFIT; }
[ "public void setACCRUED_PROFIT(BigDecimal ACCRUED_PROFIT) {\r\n this.ACCRUED_PROFIT = ACCRUED_PROFIT;\r\n }", "public BigDecimal getREIMBURSED_PROFIT_FOR_ACCRUAL() {\r\n return REIMBURSED_PROFIT_FOR_ACCRUAL;\r\n }", "public BigDecimal getGRACE_PRD_CMPND_PROFIT_AMT() {\r\n return GRACE...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
/ > Reverse order ingredients from inventory consuming ingredient resource via HTTP REST. > Delete order from database.
@Override public void deleteOrder(Long id) { ingredientClientService.reverseOrderIngredients(orderRepository.findById(id).get()); orderRepository.deleteById(id); }
[ "public Order delete(Order order);", "void deleteOrder(int id);", "void deleteRecipe(Recipe recipe) throws ServiceFailureException;", "public void deleteIngredient(int i) {\r\n\t\tthis.ingredients.remove(i);\r\n\t}", "@DeleteMapping(\"/ordered-items/{id}\")\n @Timed\n public ResponseEntity<Void> delet...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Analyzes the given expression and returns the symbol representation.
private Symbol parse(Expression e) { Symbol ret = null; if (e instanceof AccessExpression) { ret = new AccessSymbol((AccessExpression)e); } else if (e instanceof Identifier) { ret = ((Identifier)e).getSymbol(); } else if (e instanceof ArrayAccess) { re...
[ "public static Symbol getSymbolOf(Expression e) {\n if (e instanceof Identifier) {\n return ((Identifier)e).getSymbol();\n } else if (e instanceof ArrayAccess) {\n return getSymbolOf(((ArrayAccess)e).getArrayName());\n } else if (e instanceof AccessExpression) {\n ...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
private static final String TAG = "AvailableCars"; AvailableCars get from the server all available cars in a specific branch
@Override public List<Car> AvailableCars(String location) { List<Car> result = new ArrayList<Car>(); try { ContentValues query = new ContentValues(); query.put(ConstCars.CarConst.LOCATION_NUMBER, location); String str = PHPtools.POST(WEB_URL + "/AvailableCars.php...
[ "public ArrayList<CarDetail> gettingAllAvailableCars() throws Exception;", "@Override\n public List<Car> AvailableCars() {\n List<Car> result = new ArrayList<Car>();\n\n try {\n\n String str = PHPtools.GET(WEB_URL + \"/AvailableCars.php\");\n JSONArray array = new JSONObject...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
This manager is responsible for managing project resources and phases according to review assignment. This interface extends Configurable interface to support configuration via Configuration API component. Thread Safety: Implementations of this interface are not required to be thread safe.
public interface ReviewAssignmentProjectManager extends Configurable { /** * Adds reviewers to project and extends some project phases if necessary. * * @param reviewAuction * Review auction. * @param project * the Project. * @param assignment * ...
[ "abstract Configurable<?> getConfigurable();", "public static Configurable configure() {\n return new ResourceManager.ConfigurableImpl();\n }", "public IProjectConfiguration getConfiguration()\n {\n return new ProjectConfiguration(mProject, mCheckConfigs, mFileSets, mFilters,\n ...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
The ad group criterion simulation referenced in the query. .google.ads.googleads.v1.resources.AdGroupCriterionSimulation ad_group_criterion_simulation = 110;
com.google.ads.googleads.v1.resources.AdGroupCriterionSimulation getAdGroupCriterionSimulation();
[ "com.google.ads.googleads.v6.resources.AdGroupCriterionSimulation getAdGroupCriterionSimulation();", "com.google.ads.googleads.v6.resources.AdGroupCriterionSimulationOrBuilder getAdGroupCriterionSimulationOrBuilder();", "com.google.ads.googleads.v1.resources.AdGroupCriterionSimulationOrBuilder getAdGroupCriteri...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Updates the edit text behavior according to the point object. Will update the textbox and add corresponding edit event handler.
private void updateEditTextBehavior(final int targetIndex, Point point) { // Set text once to remove the text change listener. endpointEditText[targetIndex] .setText(point.getEditTextRepresentation()); endpointEditText[targetIndex].setSelectAllOnFocus(true); if (!point.isEditable()) { endpointEditText[ta...
[ "protected void editAction(){\n\t\tStructuredSelection selection = (StructuredSelection)pointsTable.getSelection();\n\t\tif (!selection.isEmpty()){\t\n\t\t\tPoint editElement = (Point)selection.getFirstElement();\n\n\t\t\tProvidePointDialog dialog = new ProvidePointDialog(getShell(), editElement.getX(), editElement...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Checks if a cursor with the specified cursorName exists
public boolean hasCursor(final String cursorName) { return this.cursors.containsKey(cursorName); }
[ "public boolean hasCursor()\r\n {\r\n return cursor!=null && cursor.size()>0;\r\n }", "public boolean checkCursor()\n {\n if (mCursor == null || mCursor.isClosed() || mCursor.getCount() == 0)\n return false;\n\n return true;\n }", "public Cursor getCursor(final String cursorN...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
This function will get the locations for all ghosts.
public Map<String, Coordinate> getGhostsLocation() { return new HashMap<>(ghostLocations); }
[ "public synchronized Set<Resource> getAllHosts() {\n Set<Resource> list = new HashSet<>();\n for (DataLocation loc : this.locations) {\n List<Resource> hosts = loc.getHosts();\n \tsynchronized(hosts){\n \t\tlist.addAll(hosts);\n \t}\n }\n\n return list;\n ...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
SUNNYDAY Test passing 2 dice pairs to the setTurnRollsList method for the human player
@Test public void testSetTurnRollsList2DicePair() { HumanPlayer player = new HumanPlayer("Human"); String dicePair1 = "4, 3"; player.setTurnRollsList(dicePair1); String dicePair2 = "1, 3"; player.setTurnRollsList(dicePair2); assertEquals("[4, 3, 1, 3]", player.getTurnRollsList().toString()); }
[ "@Test\n\tpublic void testSetTurnRollsList1DicePair() {\n\t\tHumanPlayer player = new HumanPlayer(\"Human\");\n\t\tString dicePair = \"4, 3\";\n\n\t\tplayer.setTurnRollsList(dicePair);\n\n\t\tassertEquals(\"[4, 3]\", player.getTurnRollsList().toString());\n\t}", "@Test\n\tpublic void testGetDicePairDie2() {\n\t\t...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Creates an Attr of the given name. Note that the Attr instance can then be set on an Element using the setAttribute method. To create an attribute with a qualified name and namespace URI, use the createAttributeNS method.
public Attr createAttribute(String name) throws DOMException;
[ "@Function Attr createAttribute(String name);", "public XmlAttribute CreateAttribute( String name ) { \r\n String prefix = String.Empty;\r\n String localName = String.Empty;\r\n String namespaceURI = String.Empty;\r\n \r\n SplitName( name, out prefix, out localName );\r...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Determine if debugging is enabled on the VM level Stability: unlikely to change, this implementation works from 1.6 through 9.0
@SuppressLint("PrivateApi") static boolean isDebuggingEnabled() { try { Class<?> cVMDebug = Class.forName("dalvik.system.VMDebug"); Method mIsDebuggingEnabled = cVMDebug.getDeclaredMethod("isDebuggingEnabled"); return (Boolean)mIsDebuggingEnabled.invoke(null); } c...
[ "boolean isDebugEnabled();", "public static boolean isDebuggingEnabled() {\n return DEBUG;\n }", "boolean isDebug();", "public boolean isDebugMode() {\n return config.getDebugMode();\n }", "public boolean isDebugEnabled() {\n return isEnabled(DEBUG_ENABLED_MASK);\n }", "private boo...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Get the networkInterfaces property: An array of references to the network interfaces created for this private endpoint.
public List<NetworkInterfaceInner> networkInterfaces() { return this.networkInterfaces; }
[ "@java.lang.Override\n public java.util.List<? extends com.google.cloud.compute.v1.NetworkInterfaceOrBuilder>\n getNetworkInterfacesOrBuilderList() {\n return networkInterfaces_;\n }", "@java.lang.Override\n public java.util.List<com.google.cloud.compute.v1.NetworkInterface> getNetworkInterfacesList() ...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
The complete collection of competitors engaged in the match.
public abstract Collection<? extends Competitor> getCompetitors();
[ "public String getCompetitors() {\n return competitors;\n }", "public int getCompetitors()\r\n\t{\r\n\t\treturn competitors;\r\n\t}", "public java.lang.String getAccountCompetitors() {\n return accountCompetitors;\n }", "public List<ObjectId> getCompetitionList() {\n return(new Arra...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Set the maximum size for the recevier.
protected void setMaxSize(int size) { maxSize = size; }
[ "void setMaximumSize(int newMaxSize);", "public void setMaxSize(long new_size)\n {\n this.max_size=new_size;\n }", "public void setMaxPayloadSize(int max) {\n FormField formField = FormField.textSingleBuilder(ConfigureNodeFields.max_payload_size.getFieldName())\n .setV...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Test of getPulkovo19953DegreeGKCM177E method, of class GaussKrugerPulkovo1995.
@Test public void testPulkovo19953DegreeGKCM177E() { testToWGS84AndBack(PROJ.getPulkovo19953DegreeGKCM177E()); }
[ "@Test\n public void testPulkovo19953DegreeGKCM48E() {\n testToWGS84AndBack(PROJ.getPulkovo19953DegreeGKCM48E());\n }", "@Test\n public void testPulkovo19953DegreeGKCM36E() {\n testToWGS84AndBack(PROJ.getPulkovo19953DegreeGKCM36E());\n }", "@Test\n public void testPulkovo19953DegreeGKCM93E() {\n t...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
optional bool canUseTransforDoor = 2; optional bool canUseTransforDoor = 2;
boolean hasCanUseTransforDoor();
[ "boolean getCanUseTransforDoor();", "public Builder setCanUseTransforDoor(boolean value) {\n bitField0_ |= 0x00000002;\n canUseTransforDoor_ = value;\n onChanged();\n return this;\n }", "public void setOptional(Boolean optional);", "public boolean getCanUseTransforDoor() {\n ...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Attempts to recover the existing AES Key or generates a new one if none is found.
@VisibleForTesting byte[] getAESKey() throws IncompatibleDeviceException, CryptoException { String encodedEncryptedAES = storage.retrieveString(KEY_ALIAS); if (TextUtils.isEmpty(encodedEncryptedAES)) { encodedEncryptedAES = storage.retrieveString(OLD_KEY_ALIAS); } if (enc...
[ "public static SecretKey generateKeyForAES() {\n try {\n KeyGenerator keyGenerator = KeyGenerator.getInstance(\"AES\");\n keyGenerator.init(256);\n return keyGenerator.generateKey();\n } catch (NoSuchAlgorithmException e) {\n throw new CryptoException(\"Fail...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
onCameraFrame detect cat faces and draw rectangle on faces
public Mat onCameraFrame(CvCameraViewFrame inputFrame) { mRgba = inputFrame.rgba(); mGray = inputFrame.gray(); if (mAbsoluteFaceSize == 0) { int height = mGray.rows(); if (Math.round(height * mRelativeFaceSize) > 0) { mAbsoluteFaceSize = Math.round(heigh...
[ "public Mat onCameraFrame(CameraBridgeViewBase.CvCameraViewFrame inputFrame) {\n mRgba = inputFrame.rgba();\n Imgproc.resize(mRgba, mRgba, new Size(100,100));\n // Rotate mRgba 90 degrees\n Core.transpose(mRgba, mRgbaT);\n Imgproc.resize(mRgbaT, mRgbaF, mRgbaF.size(), 0,0, 0);\n ...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Gets the fFT box.
public FFTBox getFFTBox() { return this.fftBox; }
[ "public FTManager getFTManager() {\n return this.ftmanager;\n }", "public java.lang.Boolean getFtSupported() {\r\n return ftSupported;\r\n }", "public double getF()\n\t {\n\t \tswitch(type)\n\t\t \t{\n\t\t \tcase 'F':\n\t\t \tcase 'f': \n\t\t \t\treturn Math.round(degrees*10)/10....
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
get a class type for the specified name in the context of the specified template
public TypeConstant getClassType(String sName, ClassTemplate template) { ConstantPool pool = f_pool; if (sName.startsWith("@")) { int ofEnd = sName.indexOf(" ", 1); if (ofEnd < 0) { throw new IllegalArgumentException("Invalid a...
[ "Class<T> getTemplateType();", "Class<?> getClassFromTypeWithNamespace(String name);", "String getTemplate(String type);", "public IType findType(String name);", "public static Class<?> fromName(String name) {\n return name2Class.get(name);\n }", "ParsedTemplate getTemplate(Context context, Clas...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Instantiates a new ReturnCash2.
public ReturnCash2(DataStore2 dataStore) { super(dataStore); }
[ "@Override\n public Return_Cash CreateReturnCash(){\n return new Return_Cash1();\n }", "@Override\n public Store_Cash CreateStoreCash(){\n return new Store_Cash1();\n }", "public PaymentCash(double amount, double cash) \n {\n super(\"CASH\",amount);\n this....
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Calls the recursive solver function to solve a board; prints an error message if not a valid board.
public void solve(Board board) { boolean solved = solver(0, 0, board); if(solved) { board.printBoard(); } else { System.out.println("This is not a valid board."); } }
[ "public void solveBoard () {\n while (!nextStep());\n }", "public void solve()\n {\n /* INSERT YOUR CODE HERE */\n \tint[][] sudokuArray = this.GridtoArray();\n \tsolveArray(sudokuArray);\n \tthis.Grid = sudokuArray;\n \t\n \tSystem.out.println(\"solve\");\n }", "private vo...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Calculate the projection factor of the distance of the point coordinates along the line. If the point is within the line the range will be between 0.0 > 1.0.
public static double projectionFactor(final Point lineStart, final Point lineEnd, final Point point) { final double x1 = lineStart.getX(); final double y1 = lineStart.getY(); final double x2 = lineEnd.getX(); final double y2 = lineEnd.getY(); final double x = point.getX(); final double y =...
[ "private static Point2D.Double calProjectionPoint(Point2D.Double point, Line2D.Double line) {\n double x1 = line.getX1();\n double y1 = line.getY1();\n double x2 = line.getX2();\n double y2 = line.getY2();\n double x3 = point.getX();\n double y3 = point.getY();\n dou...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Container's getter for DcmRoleTemplateView.
public ViewObjectImpl getDcmRoleTemplateView() { return (ViewObjectImpl)findViewObject("DcmRoleTemplateView"); }
[ "public ViewLinkImpl getDcmRoleTemplateLnk() {\r\n return (ViewLinkImpl)findViewLink(\"DcmRoleTemplateLnk\");\r\n }", "public List<TemplateRole> getTemplateRoles() {\n return templateRoles;\n }", "public ViewObjectImpl getDcmTemplateView() {\r\n return (ViewObjectImpl)findViewObject(\...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Removes the user from the user list given the username of the user
public void removeUser(String username) { userList.remove(username); }
[ "public void removeUser(String username);", "public void removeUser(TList selectedUser);", "public void removeUser(String username)\n\t{\n\t\tIterator<User> current = users.iterator();\n\t\twhile(current.hasNext())\n\t\t{\n\t\t\tUser currentUser = current.next();\n\t\t\tif(currentUser.getUsername() == username)...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
$ANTLR end "rule__Primary__Group_5__5" $ANTLR start "rule__Primary__Group_5__5__Impl" InternalGaml.g:14268:1: rule__Primary__Group_5__5__Impl : ( ( rule__Primary__Group_5_5__0 )? ) ;
public final void rule__Primary__Group_5__5__Impl() throws RecognitionException { int rule__Primary__Group_5__5__Impl_StartIndex = input.index(); int stackSize = keepStackSize(); try { if ( state.backtracking>0 && alreadyParsedRule(input, 845) ) { return ; } ...
[ "public final void rule__EPrimary__Group_0__1() throws RecognitionException {\n\n \t\tint stackSize = keepStackSize();\n \t\n try {\n // InternalAADMParser.g:15684:1: ( rule__EPrimary__Group_0__1__Impl )\n // InternalAADMParser.g:15685:2: rule__EPrimary__Group_0__1__Impl\n...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Returns the value of the 'Timesheet' reference.
Timesheet getTimesheet();
[ "public Timesheet getEmpTimeSheetShow() {\r\n return empTimeSheetShow;\r\n }", "public int getTimeSheetEntryID() {\n\t\treturn fieldTimeSheetEntryID;\n\t}", "String getTimesheetId();", "public Calendar getReferenceTime()\n {\n return this.baseTime;\n }", "public List<Timesheet> getTim...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
entrada: arquivo vazio saida: zero registros na listagem
@Test public void testListarVazio() throws IOException { // 1) criar o arquivo de dados vazio String nomeArquivo = "dados.txt"; new File(nomeArquivo).createNewFile(); // 2) criar o processador de arquivos // utilizando o arquivo criado acima ProcessadorDeArquivoSequencial pas = new ProcessadorDeA...
[ "private static void obtenirUneListe() throws FileNotFoundException {\n\t\tSystem.out.println(\"\\r\\nPour combien de jours : \");\n\t\tint nbJours = sc.nextInt();\n\n\t\tSystem.out.println(\"\\r\\nCombien de propositions : \");\n\t\tint nbPropositions = sc.nextInt();\n\n\t\tList<List<Recette>> listeProposition = g...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Constructs CompressingMessageWriter using external MessageWriter.
CompressingMessageWriter(MessageWriter wr) { this.writer = wr; }
[ "void messageWriter(MessageWriter messageWriter);", "public interface CompressedStreamWriter\n{\n\n /**\n * Initializes encoder with block data component and its binary encoding info\n * @param blockComponent\n * @param binaryBlock\n * @throws CDMException\n */\n public abstract void ini...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Get the raft options
RaftOptions getRaftOptions();
[ "go.micro.runtime.RuntimeOuterClass.ListOptions getOptions();", "String[] getOptions();", "public Options getOptions();", "public abstract String[] getOptions();", "public MountTOptions getOptions() {\n return this.options;\n }", "go.micro.runtime.RuntimeOuterClass.ReadOptions getOptions();", "p...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Load the native library. The governing assumption is that the .jar created "inplace" does NOT have the libdir file; it is appended to the .jar during the `make install` step. The root name "libgtkjni" is historical. We've left it as is because there's no burning need to further pollute the system library space (althoug...
private static final void loadNativeCode() { final BufferedReader reader; String libdir; final ProtectionDomain domain; final CodeSource source; final URL url; String jar; final File library; final String path; try { /* ...
[ "protected String findTheLibrary(String BINLIB_PREFIX, String name) {\r\n String result = null; // By default, search the java.library.path for it\r\n \r\n String resourcePath = BINLIB_PREFIX + System.mapLibraryName(name);\r\n \r\n // If it isn't in the map, try to expand to temp ...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Construct an App State based on the storage and state xml.
public StorageAppState(Storage storage, String xml) { this.storage = storage; storage.setItem(key = TEMP_STORAGE_PREFIX + nextKeyNum++, xml); }
[ "void setupAppState() {\n // Attempt to load existing config\n app_state = new AppState();\n app_state.loadConfiguration();\n\n // Force user to select a folder where journal will be stored (if not selected already)\n if (!app_state.configurationExists()) {\n DirectoryC...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Defines a method for validating the text format of some data.
public interface IDataValidator<T> { /*************************************************************************** * Validates and creates the data from the text representation if possible * or throws a {@link FormatException} otherwise. * @param text the text representation of the data to be val...
[ "boolean validateText(String format, String text);", "boolean isValid(final String word, final String textData);", "public void InvalidFormat();", "public abstract void validate(String value) throws DatatypeException;", "public String validate(Data[] data);", "public interface Validator {\n\n /**\n ...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
return this.service.getAllProducts().stream().map(Product > new ProductResponse(Product)).collect(Collectors.toList());
@GetMapping() public List<ProductResponse> getAllProducts(){ var result = new ArrayList<ProductResponse>(); for(Product a: this.service.getAllProducts()){ result.add(new ProductResponse(a)); } return result; }
[ "public List<Product> getProducts();", "@GetMapping(path =\"/products\")\n public ResponseEntity<List<Product>> getProducts() {\n return ResponseEntity.ok(productService.getAll());\n }", "List<Product> getAllProducts();", "@RequestMapping(value = \"/products\", method = RequestMethod.GET, produces = Medi...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Click on 2 Link.
public ItemPage clickLink2() { _2.click(); return this; }
[ "public void ClickFirstValue()\r\n\t\r\n\t{\r\n\t\tFirstlink.click();\r\n\t}", "public ItemPage clickLink1() {\n _1.click();\n return this;\n }", "HtmlPage clickSiteLink();", "public void clickSitesAndJobs() {\r\n\t\tlink_SitesandJobs.click();\r\n\t}", "public void clickOnSellAMotorcycleLin...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Sets the probability of success
public final void setProbabilityOfSuccess(double prob) { if ((prob < 0.0) || (prob > 1.0)) { throw new IllegalArgumentException("Probability must be [0,1]"); } myProbSuccess = prob; myProbFailure = 1.0 - myProbSuccess; }
[ "public void setProbOfFailure(int prob) {\n \tif( prob <= 100 || prob >= 0){\n \t\tthis.probOfFailure = prob;\n \t}\n }", "public void setProb(double value) {\r\n this.prob = value;\r\n }", "public void setProbMut (float value) {\r\n mut_prob= value;\r\n }", "public void setFai...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
optional float tcp_ping_var = 11;
public boolean hasTcpPingVar() { return result.hasTcpPingVar(); }
[ "private MeasureResult doTCPPing(String ip){\n \tMeasureResult result = new MeasureResult(ip);\n \tlong[] delays = new long[5];\n \tint errorCount = 0;\n\t\ttry{\n\t\t\tfor(int i=0; i<5; i++){\n\t\t\t\tlong t1 = System.currentTimeMillis();\n\t\t\t\tSocket socket = new Socket();\n\t\t\t\ttry{\n\t\t\t\t\tsoc...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
return "mongo://" + host + ":" + port + "/" + mongodb + "?connectionPool=" + pool + "&ssl=" + ssl;
@RequestMapping("/mongo") public String getMongoConfigDetails() { return "mongo://" + rickleProperties.getHost() + ":" + rickleProperties.getPort() + "/" + rickleProperties.getMongodb() + "?connectionPool=" + rickleProperties.getPool() + "&ssl=" + rickleProperties.isSsl(); }
[ "private void apriConnessione(String collection) throws Exception{\r\n System.err.println(\"mongodb://\"+this.ip+\":\"+this.porta);\r\n mongoClient=MongoClients.create(\"mongodb://\"+this.ip+\":\"+this.porta);\r\n database=mongoClient.getDatabase(dbName);\r\n this.collection=database.get...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
enter employ code from Excel sheet
public void enter_employ_code(String value) { employ_code.clear(); employ_code.sendKeys(value); }
[ "public void enterProductCode() throws IOException {\n\t\tAddProductWithAssetPage sp = new AddProductWithAssetPage(driver);\n\t\tlog.info(\"Enter Product Code\");\n\t\tAssert.assertTrue(enterProductCode.isDisplayed());\n\t\tenterProductCode.sendKeys(sp.ExcelRead(sheetName).get(7));\n\t\t\n\n\t}", "public void sea...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
returns true if the encounter will request the player to trade.
public boolean willRequestTrade() { return willTrade; }
[ "private boolean canTrade() {\n if(canContinue(true)) {\n // Check if both players have accepted the trade\n return this.accepted.getOrDefault(sender.getUniqueId(), false) && this.accepted.getOrDefault(target.getUniqueId(), false);\n }\n return false;\n }", "public b...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Get the color for the the side of a triangle that should not be visible due to being on the inside of a closed manifold.
Color getBacksideColor();
[ "public Color getTriangleColor() {\n\t return triangleColor;\n\t}", "public String getOppositeColor() {\n return oppositeColor;\n }", "public boolean isSideSolid(EnumFacing face);", "public Paint getColorOff() {\n return colorOff;\n }", "Color getEdgeColor();", "public Color getInve...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
field1 = 100; Non Static member cannot be accessed from static nested class
public void fieldChangeFromStaticNestedClass(){ field2 = 200; System.out.println("Static nested class, field 2 :" +field2); }
[ "private static void $noinline$testStaticFieldSets(Object o, Object o2, Object o3) {\n inner_static = o;\n inner_static2 = o2;\n inner_static3 = o3;\n }", "private static native void _recordStaticFieldOffset (long offset, Field f);", "public void printMessage() {\n\n // Try making '...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
This example shows the assertion on number of rows.
@Test public void rows_number_assertion_examples() { Request request = new Request(dataSource, "select * from albums"); assertThat(request).hasNumberOfRows(15) .column().hasNumberOfRows(15); }
[ "@Test\n public void testnbRows() {\n assertEquals(emptyDf.nbRows(),0);\n assertEquals(students.nbRows(),6);\n assertEquals(oscars.nbRows(),89);\n assertEquals(cities.nbRows(),128);\n }", "@Test\n\tpublic void testGetRowCount() {\n\t\tint result = m1.getRowCount();\n\t\tassertEqu...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Return a set of all elements in both this set and the argument.
@Override public ImmutableSet<T> intersection(Set<T> other) { return intersect(asThis(other)); }
[ "public Set union(Set anotherSet);", "Set<E> intersect(Set<E> other);", "public ZYSet<ElementType> union(ZYSet<ElementType> otherSet){\n ZYSet<ElementType> result = new ZYArraySet<ElementType>();\n for(ElementType e :this){\n result.add(e);\n }\n for(ElementType e :otherSet){\n result.add(e...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Validate the data types for listed items in the data set.
public void validateType(Object ... args) throws DataException { if (args.length % 2 > 0) { throw new DataException( "Arguments not a list of pairs", this.getPath() ); } for (int a = 0; ...
[ "private void validateDataType() {\n if (getDataElement().getCalculation() != null) {\n String dataType = getDet().getDataElement(getDataElement().getCui()).getDatatype();\n if (!FormUtils.VALID_CALCULATION_DATATYPES.contains(dataType)) {\n notifyValidatorErrorListener(ERROR_KEY1); \n }\n ...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
A Binomial coefficient based function to find nth catalan number in O(n) time
public static int catalanBinomial(int n) { // Calculate value of 2nCn long c = binomialCoefficientIterative(2 * n, n); // return 2nCn/(n+1) return (int) (c / (n + 1)); }
[ "int catalan(int n) { \n int res = 0; \n \n // Base case \n if (n <= 1) { \n return 1; \n } \n for (int i = 0; i < n; i++) { \n res += catalan(i) * catalan(n - i - 1); \n } \n return res; \n }", "int catalan(int n) {\n int r...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
sets whether or not there are locked bricks in the game. Saves number of locked bricks when removing.
public void setLocked(boolean b){ lockedEnabled = b; if (b == false){ //Make locked bricks no longer locked bricks.forEach( bList -> bList.forEach( brick -> { if(brick.active && brick.locked){ //only active, locked bricks are unlocked brick.locked = false; brick.setColor(colors[brick.type]); //b...
[ "private boolean manageBrickHit(List<Brick> bricks, Brick b) {\n if (b.updateHitToBrick(currentLevel) && !b.getIsPowerUp()) {\n removeBrick(b, bricks, root);\n return true;\n }\n return false;\n }", "public static void addDeadBrick(){\n\t\tdeadBricks++;\n\t}", "private boolean bricksCleared(...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Elimina un empleado perteneciente a la lista de empleados del manager.
public static void quitarUnEmpleado(Empleado empleadoEliminado ) { listaDeEmpleados.remove(empleadoEliminado); }
[ "public void remove(Empregado e) {\n\t\tSystem.out.println(\"Não é possível remover empregado subordinado do programador\");\n\t}", "public void removeEmployee(Employee emp) {\n employees.remove(emp);\n }", "public String eliminarEmpregado(Empregados empregado) {\n this.empregadosFacade.remove(...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Sets the value of the lineItem property.
public void setLineItem(int value) { this.lineItem = value; }
[ "public void setItemLine(ItemLine il);", "public void setItemLine(ItemLine il, boolean copy);", "public void setLineItemNumber(int value)\n {\n lineItemNumber = value;\n }", "public void setLineItemNumber(int value) {\r\n this.lineItemNumber = value;\r\n }", "public void setLineItemNu...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Should delete the room if the index is found in the database.
@Test public void shouldDeleteTheRoomIfTheIndexIsFoundInTheDatabase() throws Exception { final DeleteRoomCommand command = new DeleteRoomCommand(validRoomOffer); final UrlyBirdRoomOfferService roomOfferService = new UrlyBirdRoomOfferService( dao, builder, null, null); when(dao.read(validRoomOffer.getIn...
[ "public void deleteRoom(Room room);", "void deleteRoom(int id) throws DataAccessException;", "Boolean deleteRoom(String roomId);", "@Test(expected = Exception.class)\n public void shouldNotDeleteTheRoomIfTheIndexIsNotFoundInTheDatabaseAndThorwAnException()\n\t throws Exception {\n\n\tfinal DeleteRoomCom...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
optional .com.fuhu.proto.KafkaRequestParam request = 8;
KafkaRequestParamOrBuilder getRequestOrBuilder();
[ "KafkaRequestParam getRequest();", "public KafkaRequestParam getRequest() {\n return request_;\n }", "public KafkaRequestParamOrBuilder getRequestOrBuilder() {\n if (requestBuilder_ != null) {\n return requestBuilder_.getMessageOrBuilder();\n } else {\n return request_;\n...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Interface for traversal and pathfinding algorithms to be displayed by animated graph visualization tools. The algorithm is assumed to be of the following general form add start vertex to open set while open set is not empty remove a vertex u from open set add u to closed set if u is the goal vertex done = true break fo...
public interface GraphAnimation<E> { /** * Performs one step of the algorithm and returns the node added to * the closed set. The returned value may be null if no vertex is * added to the closed set (some implementations of Dijkstra's * algorithm allow this). The returned value is always null whe...
[ "void startedBuildingGraph();", "public interface FullPathAlgorithm {\n\t\n\n\t/**\n\t * An unique name that identifies the algorithm and its parametrization\n\t * (which we may call the \"multiagent strategy\"). \n\t */\n\tpublic String getName();\n\t\n\t\n\t/**\n\t * Called by the simulator as soon as the simul...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
byte offset from the start of the enclosing uncompressed buffer where the uncompressed data should be written
public long uncompressedOffset() { int o = __offset(10); return o != 0 ? bb.getLong(o + bb_pos) : 0L; }
[ "public long compressedOffset() { int o = __offset(6); return o != 0 ? bb.getLong(o + bb_pos) : 0L; }", "public final int getByteOffset() {\n\n //\tCalculate the offset of the byte buffer\n int pCnt = getParameterCount();\n int pos = WORDCNT + (2 * pCnt) + 3 + m_offset;\n return pos;\n...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
required int32 c2s_cardTemplateId = 1;
public int getC2SCardTemplateId() { return c2SCardTemplateId_; }
[ "int getC2SCardTemplateId();", "public int getC2SCardTemplateId() {\n return c2SCardTemplateId_;\n }", "boolean hasC2SCardTemplateId();", "public de.uni_koblenz.jgralabtest.schemas.gretl.pddsl.Card createCard();", "pomelo.area.CardHandler.Card getS2CCard();", "int getCardId();", "int getC2SCardI...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Gets the vertical array. each cell in the array represents the column regex.
String[] getVerticalArray();
[ "public String[] parseColNames(String line,String regex){\n // Not quite right, because includes spurious 0,0 column. \n\t\tString[] fields = line.split(regex,-1); // -1 to include empty cols.\n\t\tString[] colNames = new String[fields.length-colOffset];\n\t\t\n\t\t//System.err.println(\"colNames.length=\"+colNa...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
This method was generated by MyBatis Generator. This method sets the value of the database column core_user.core_dept_id
public void setCoreDeptId(Long coreDeptId) { this.coreDeptId = coreDeptId; }
[ "public Long getCoreDeptId() {\n return coreDeptId;\n }", "public void setCoreUserId(Long coreUserId) {\n this.coreUserId = coreUserId;\n }", "private void setDeptId() {\n String id = getDeptId();\n if (validId(id)) {\n this.deptId = id;\n } else {\n this.deptId = \"None01...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
$ANTLR end "entryRuleOneDec" $ANTLR start "ruleOneDec" InternalDsl.g:513:1: ruleOneDec : ( ( rule__OneDec__Alternatives ) ) ;
public final void ruleOneDec() throws RecognitionException { int stackSize = keepStackSize(); try { // InternalDsl.g:517:2: ( ( ( rule__OneDec__Alternatives ) ) ) // InternalDsl.g:518:2: ( ( rule__OneDec__Alternatives ) ) { // InternalDsl.g:51...
[ "public final void entryRuleOneDec() throws RecognitionException {\n try {\n // InternalDsl.g:505:1: ( ruleOneDec EOF )\n // InternalDsl.g:506:1: ruleOneDec EOF\n {\n if ( state.backtracking==0 ) {\n before(grammarAccess.getOneDecRule()); \n ...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
GET /patienttoshifts/:id : get the "id" patientToShift.
@GetMapping("/patient-to-shifts/{id}") @Timed public ResponseEntity<PatientToShift> getPatientToShift(@PathVariable Long id) { log.debug("REST request to get PatientToShift : {}", id); PatientToShift patientToShift = patientToShiftService.findOne(id); return Optional.ofNullable(patientTo...
[ "@GetMapping(\"/shifts/{id}\")\n @Timed\n public ResponseEntity<ShiftsDTO> getShifts(@PathVariable Long id) {\n log.debug(\"REST request to get Shifts : {}\", id);\n ShiftsDTO shiftsDTO = shiftsService.findOne(id);\n return ResponseUtil.wrapOrNotFound(Optional.ofNullable(shiftsDTO));\n ...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Get link info for a given class
public LinkInfo getLinkInfo(ClassInfo cli) { return this.linkerInfo.getLinkInfo(cli); }
[ "protected abstract Content getClassLink(LinkInfo linkInfo);", "@Test\n public void getLinkClassPopulated() {\n browseTo(\"/hasLink-1.html\", \"hasLink - 1\");\n assertEquals(\"Wrong classes returned\",\n \"class1 class2 class3\", driverWrapper.getLinkClass(\"test 1\"));\n }", ...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
whoWon accessor gives the winner of the game
public char whoWon() { return(winner); }
[ "public Winner whoWins(){\r\n\r\n /* transfer the matrix to an array */\r\n Sign[] flatBoard = flattenBoard();\r\n\r\n /* check if someone has won */\r\n if (CompPlayer.compWon(flatBoard))\r\n return Winner.COMPUTER;\r\n else if (CompPlayer.playerWon(flatBoard))\r\n ...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Set the 'StreetDirection' attribute value. Street direction of an address (e.g., N, E, S, NW, SW).
public void setStreetDirection(String streetDirection) { this.streetDirection = streetDirection; }
[ "void setStreet(au.gov.asic.types.StreetType street);", "public String getStreetDirection() {\n return streetDirection;\n }", "public void setStreet(java.lang.String street)\n {\n synchronized (monitor())\n {\n check_orphaned();\n org.apache.xmlbeans.Simp...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
REQUIRES: score is an int [125] MODIFIES: this EFFECTS: sets mood color based on ui score
public void setColor (int score) { if (score == 1) { color = setColor.navy; } else if (score == 2) { color = setColor.lightBlue; } else if (score == 3) { color = setColor.green; } else if (score == 4) { color = setColor.lightGreen; ...
[ "private void setUpGameScoreColor() {\n if (gameItemViewModel.getRatings_count() == 0)\n gameRateScore.setTextColor(view.getResources().getColor(R.color.colorAccent));\n else if (Double.parseDouble(gameItemViewModel.gameRate) * 20 > 72)\n gameRateScore.setTextColor(view.getResour...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
This refreshes the task tree. Useful if you know you've changed something behind gradle's back or when first displaying this UI.
public void refreshTaskTree() { basicGradleUI.refreshTaskTree(); }
[ "public void refreshTree() {\n\t\trefreshPersons();\n\t\trefreshPlays();\n\t\trefreshEnsembles();\n\t\trefreshProductions();\n\t}", "void refreshTaskInformation();", "public void refresh() {\n tasks.clear();\n tasks.addAll(repo.read());\n }", "public void doReloadTask() {\n task = pare...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Creates a storage minecart from the given bukkit minecart
public MinecartManiaStorageCart(Minecart cart) { super(cart); initialize(); }
[ "public MinecartManiaStorageCart(Minecart cart, String owner) {\n\t\tsuper(cart, owner);\n\t\tinitialize();\n\t}", "public ShoppingCart createCart() {\n\t\treturn save(new ShoppingCart());\n\t}", "public void makeSavedCartLive();", "public void saveCart() throws IOException {\n String fileName = userid...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Returns the canceled routes of the last 24 hours.
@RequestMapping(path = "/last24hCanceledRoutes", method = RequestMethod.GET) public List<RouteCanceled> getLast24hCanceledRoutes() { Query queryObject = new Query("Select * from route_canceled", "blablamove"); QueryResult queryResult = BlablamovebackendApplication.influxDB.query(queryObject); ...
[ "@RequestMapping(path = \"/specificCanceledRoutes\", method = RequestMethod.GET)\n\tpublic List<RouteCanceled> getRoutesCanceledByTimeframe(Date from, Date to) {\n\t\tQuery queryObject = new Query(\"Select * from route_canceled\", \"blablamove\");\n\t\tQueryResult queryResult = BlablamovebackendApplication.influxDB...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
main() method to execute the program, it also creates the maze frame
public static void main(String[] args) { Scanner input = new Scanner(System.in); System.out.println("Enter dimensions (rows*columns) for the Maze: - "); System.out.print("Enter number of rows: -"); rows = input.nextInt(); System.out.print("Enter number of columns: -"); ...
[ "public static void main(String[] args) {\n String startCoords, endCoords, userInput;\n System.out.println(\"Welcome to the A-Mazing Maze Solver Program!!!\");\n\n // New input scanner to collect user input\n Scanner input = new Scanner(System.in);\n System.out.print(\"Please ente...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Get messages belonging to a particular queue so that they can be examined.
public List<Message> getMessages(final String queueUrl) { final Queue queue = queuesByQueueUrl.get(queueUrl); return new ArrayList<Message>(queue.messageQueue); }
[ "List<InboundMessage> browseQueueMessages(String queueName);", "Collection<Message> readAll(String queueName) throws BrokerException;", "List<MBQMessage> get(String queueName, List<String> ids);", "List<InboundMessage> readMessages(String queueName, int timeout);", "private ArrayList<Message> getMessagesByR...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Get the tplName property: Panorama Template Stack to join (Once configured we can not edit the value).
public String tplName() { return this.tplName; }
[ "public String getTemplateBuildPlanName() {\n return this.templateBuildPlan.getBpelScopeElement().getAttribute(\"name\");\n }", "public String getTemplateName() {\n return templateName;\n }", "public PathTemplate getNameTemplate() {\n return nameTemplate;\n }", "java.lang.String getTum...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Provides settings which control how a cache is to be configured.
public interface ICacheConfiguration { /** * Get time to live in seconds. * * @return */ public int getTtlInSeconds(); /** * Set time to live in seconds. * * @param value */ public void setTtlInSeconds(int value); /** * Indicates whether cache is ena...
[ "ICacheConfiguration getCacheConfiguration ();", "public CacheConfiguration() {\r\n addConfiguration(new ExceptionHandlingConfiguration<CacheExceptionHandler<K, V>>());\r\n addConfiguration(new CacheLoadingConfiguration<K, V>());\r\n addConfiguration(new ManagementConfiguration());\r\n ...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Updates a note in the database
public void updateNote(Note note) { try { //Date now = new Date(); Color color = note.getColor(); preparedNoteUpdateStatement.setString(1, note.getTitle()); preparedNoteUpdateStatement.setString(2, note.getText()); preparedNoteUpdateStatement.setDate...
[ "@Test\n\tpublic void testUpdateNote() {\n//\t\tlog.trace(\"Testing updating note\");\n\t\tfinal short week = 2;\n\n\t\t// get the list of individual notes for week 2\n\t\tList<Note> notes = noteDao.findIndividualNotes(TEST_QCBATCH_ID, week);\n\n\t\tassertTrue(!notes.isEmpty());\n\n\t\tNote note = notes.get(1);\n\n...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Sets the agency's longitude.
public void setLongitude(double longitude) { this.longitude = longitude; }
[ "void setLongitude(double longitude);", "public void setLongitude(double aLongitude) {\r\n longitude = aLongitude;\r\n }", "private void setLongitude(double longitude) {\r\n\t\tthis.longitude = longitude;\r\n\t}", "public void setLongitude(double value) {\n longitude = value;\n }", "@Override\...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Gets the A button on the controller.
public JoystickButton getButtonA() { return button[0]; }
[ "public boolean getAButton() {\n\t\treturn getRawButton(A_BUTTON);\n\t}", "public boolean getAButton() {\n\t\treturn getRawButton(A_Button);\n\t}", "public boolean getButtonA() {\n\t\treturn joystick.getRawButton(this.buttA);\n\t}", "public AutomationButton getButton(int index) {\n return new Automatio...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
required int32 devotenum = 3 [default = 0];
int getDevotenum();
[ "private DeviceTypeEnum(int value) {\n this.value = value;\n }", "int getDevType();", "void setDevice(int value);", "public interface DeviceControlCodes {\r\n\t/**\r\n\t * Open the connection to the device. This command must be sent before any\r\n\t * other data may be sent or collected.\r\n\t */\r\...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
This method is used to update ListsManager.
private void updateListsManager(ListsManager listsManager) { listsManager.getSelectedTagsList().clear(); listsManager.setViewType(VIEW_TYPE.ALL); listsManager.setCategoryType(CATEGORY_TYPE.ALL); listsManager.updateLists(); }
[ "protected abstract void updateList();", "void refreshLists(){\n\t\tString[] taskListItem = manager.getTaskNameList();\n\t\tlistTasks.setItems(taskListItem);\n\t\tString[] npcListItem = manager.getNPCNameList();\n\t\tlistNpc.setItems(npcListItem);\n\t}", "private void updateList() {\n\t\tif(todos != null) {\n\t...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
write a setRational method
public void setRational (int numer, int denom){ numerator = numer; denominator = denom; }
[ "public L1513_Rational() {\n\t this(0, 1);\n\t }", "public void setRational(int a)\n {\n num = a / gcd(a, 1);\n den = 1;\n }", "public void setRational(int a, int b)\n {\n if (b == 0)\n {\n throw new IllegalArgumentException(\"Denominator cannot be zero\");\n ...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
$ANTLR end "rule__AstOutputPattern__Group_5__0__Impl" $ANTLR start "rule__AstOutputPattern__Group_5__1" ../org.caltoopia.frontend.ui/srcgen/org/caltoopia/frontend/ui/contentassist/antlr/internal/InternalCal.g:14965:1: rule__AstOutputPattern__Group_5__1 : rule__AstOutputPattern__Group_5__1__Impl ;
public final void rule__AstOutputPattern__Group_5__1() throws RecognitionException { int stackSize = keepStackSize(); try { // ../org.caltoopia.frontend.ui/src-gen/org/caltoopia/frontend/ui/contentassist/antlr/internal/InternalCal.g:14969:1: ( rule__AstOutputPattern__Group_5_...
[ "public final void rule__AstOutputPattern__Group__5() throws RecognitionException {\n\n \t\tint stackSize = keepStackSize();\n \n try {\n // ../org.caltoopia.frontend.ui/src-gen/org/caltoopia/frontend/ui/contentassist/antlr/internal/InternalCal.g:14772:1: ( rule__AstOutputPattern...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Return the CommerceIdentifierCostCenterContainer property.
public CommerceIdentifierCostCenterContainer getCommerceIdentifierCostCenterContainer() { return mCommerceIdentifierCostCenterContainer; }
[ "public String getCostCenterId() {\n return mCostCenterId;\n }", "public void setCommerceIdentifierCostCenterContainer(CommerceIdentifierCostCenterContainer pCommerceIdentifierCostCenterContainer) {\n mCommerceIdentifierCostCenterContainer = pCommerceIdentifierCostCenterContainer;\n }", "public CostCent...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
jsonSchemaGenerator Returns the JSON schema generator subbuilder.
public JsonSchemaGenerator.Builder jsonSchemaGenerator() { if (jsonSchemaGenerator == null) jsonSchemaGenerator = createJsonSchemaGenerator(beanStore(), parent, resource()); return jsonSchemaGenerator; }
[ "public JsonSchemaGenerator getJsonSchemaGenerator() {\n\t\treturn jsonSchemaGenerator;\n\t}", "public Builder jsonSchemaGenerator(JsonSchemaGenerator value) {\n\t\t\tjsonSchemaGenerator().impl(value);\n\t\t\treturn this;\n\t\t}", "public Builder jsonSchemaGenerator(Class<? extends JsonSchemaGenerator> value) {...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Gets the value of the 'var214' field.
public java.lang.Integer getVar214() { return var214; }
[ "public java.lang.Integer getVar214() {\n return var214;\n }", "public java.lang.Integer getVar213() {\n return var213;\n }", "public java.lang.Integer getVar213() {\n return var213;\n }", "public java.lang.Integer getVar217() {\n return var217;\n }", "public java.lang.Integer getVar...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
True if the session should be invalidated only after listeners are called.
@Description("The configured value, if true the session should be invalidated only after listeners are called") public boolean isInvalidateAfterListener();
[ "protected boolean shouldValidateSession ()\n {\n return false;\n }", "public final boolean isSessionExpired() {\n if (this.isExpired) return true;\n if (this.expireTime == 0) return false;\n if (this.lastAccessTime == -1) return false; // Forcefully allow the access time to exis...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
This method was generated by MyBatis Generator. This method returns the value of the database column t_member.is_readcard
public Short getIsReadcard() { return isReadcard; }
[ "boolean getCreCard();", "boolean getDebtCard();", "@Override\r\n\tpublic CustomerCard getCustomerCard(String cardNo) {\r\n\t\tQuery query=getSessionFactory().getCurrentSession().createQuery(\"from CustomerCard as cc where cc.cardNumber=:cardNo and cc.status=:=status\");\r\n\t\tquery.setParameter(\"cardNo\",car...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Return the file system of the second cluster.
protected FileSystem getFileSystem2() { return fileSystem2; }
[ "public FileSystem getFileSystem(){\n System.setProperty(Constant.HADOOP_USER_NAME, \"hdfs\");\n Configuration conf = new Configuration();\n FileSystem fs = null;\n try {\n fs = FileSystem.get(conf);\n } catch (IOException e) {\n e.printStackTrace();\n ...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
/ Configure Key Store for Tests
public static void setUpAppKeystoreForTest() { System.setProperty("javax.net.ssl.trustStore", KEYSTORE_PATH); System.setProperty("javax.net.ssl.trustStorePassword", KEYSTORE_PASSWORD); }
[ "@Test\n public void testSetKeyStorePath() {\n //\n KeyringBackend instance = new KeyringBackendImpl();\n\n //\n instance.setKeyStorePath(\"/path/to/keystore\");\n assertEquals(\"/path/to/keystore\", instance.getKeyStorePath());\n }", "@Test\n public void testGetKeyStor...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Returns the only instance of Parser.
public static Parser getInstance() { if (theOne == null) { theOne = new Parser(); } return theOne; }
[ "protected Parser getParser() {\n\t\treturn myParser;\n\t}", "public static ClassParser getInstance() {\n\t\tif (instance == null)\n\t\t\tinstance = new ClassParser();\n\t\treturn instance;\n\t}", "public static Parser getInstance(Context ctx){\n if(instance == null){\n instance = new Parser(c...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
$ANTLR end "ruleLayerRelations" $ANTLR start "entryRuleRelationType" InternalMyDsl.g:2773:1: entryRuleRelationType returns [String current=null] : iv_ruleRelationType= ruleRelationType EOF ;
public final String entryRuleRelationType() throws RecognitionException { String current = null; AntlrDatatypeRuleToken iv_ruleRelationType = null; try { // InternalMyDsl.g:2773:52: (iv_ruleRelationType= ruleRelationType EOF ) // InternalMyDsl.g:2774:2: iv_ruleRelation...
[ "public final String entryRuleLayerRelationName() throws RecognitionException {\n String current = null;\n\n AntlrDatatypeRuleToken iv_ruleLayerRelationName = null;\n\n\n try {\n // InternalMyDsl.g:2887:57: (iv_ruleLayerRelationName= ruleLayerRelationName EOF )\n // Intern...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Create BREED from JSON
public static Breed fromJSON(final InputStream in) throws IOException { int jfci = -1; int jbgroup = -1; String jbname = null; final JsonParser jp = JSON_FACTORY.createParser(in); // while we are not on the start of an element or the element is not // a token element, a...
[ "protected abstract Biglietto creaBigliettoDaJSON(JSONObject jsonBiglietto) throws JSONException;", "public JSONBuilder() {\n _sb = new StringBuilder();\n }", "public void createFromJson(File json) throws IOException {\n ObjectMapper mapper = new ObjectMapper();\n JSONFeed feed = mapper....
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Adds a SymbolLayer to display the depth of the lake's areas
private void setUpDepthNumberSymbolLayer(@NonNull Style loadedMapStyle) { SymbolLayer depthNumberSymbolLayer = new SymbolLayer("DEPTH_NUMBER_SYMBOL_LAYER_ID", GEOJSON_SOURCE_ID); depthNumberSymbolLayer.withProperties( textField("{depth}"), textSize(17f), textColor(Color.WHITE), t...
[ "void addLayer(String layerName);", "public Button.Layer addLayer(Symbol symbol, Transform matrix, AlphaTransform cxform, int depth, boolean usedForHitArea, boolean usedForUp, boolean usedForDown, boolean usedForOver) {\n Layer layer = new Layer(symbol, matrix, cxform, depth, usedForHitArea, usedForUp, use...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
The getPaymentGroupMap method returns the Map of payment names to PaymentGroups.
public Map getPaymentGroupMap();
[ "public PaymentGroup getPaymentGroup(String pPaymentGroupName);", "public List<Person> getPaymentGroup() {\n return paymentGroup;\n }", "public Map<ServiceID,String[]> getGroups() {\n return new HashMap<ServiceID,String[]>(groups);\n }", "public Map<ExportGroup, Boolean> getRpExportGroupMa...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Set current view that is currently being updated
protected void setCurrentView( final View view ) { updater.setCurrentView( view ); }
[ "public void updateView() {\n if (settingsController != null) {\n settingsController.recreateView();\n settingsController.updateView();\n remoteHandler.createAndAddRemoteSettingsView(settingsController.getProgramView());\n }\n if (programController != null) {\n ...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
optional .bosphorus2.PARTYPROXY partyproxyinherited_fields = 2;
boolean hasPartyproxyinheritedFields();
[ "private PARTYPROXY(Builder builder) {\n super(builder);\n }", "PartyType getFreightForwarderParty();", "Party getParty();", "boolean hasPartyidentifiedinheritedFields();", "public L2Party getParty()\r\n\t{\r\n\t\treturn null;\r\n\t}", "public interface Infoblox {\n\n /**\n * By default, all th...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Initialize fingerprint database , store all hardcoded database information during this function Remember to update the total number of location point for database at the top of this file
public void initializeFingerprintDb(FingerprintDatabase fingerprintDB) { // Remember to update the total number of location point for database at the top of this file //---------------------------------------------------------------------------------------------------- fingerprintDB.fillUpEachMea...
[ "private void initDB() {\n characterdataDb = new CharacterdataDatabase(this);\n characterdataDb.open();\n statsDb = new StatsDatabase(this);\n statsDb.open();\n weaponDb = new WeaponDatabase(this);\n weaponDb.open();\n armorDb = new ArmorDatabase(this);\n armo...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }