query
stringlengths
8
1.54M
document
stringlengths
9
312k
negatives
listlengths
19
20
metadata
dict
======================================================== Programmer's data members ======================================================== / PROTECTED REGION ID(JavaDSTest.variables) ENABLED START Put static variables here / PROTECTED REGION END JavaDSTest.variables / PROTECTED REGION ID(JavaDSTest.private) ENABLED ST...
@Init(lazyLoading = false) public final void initDevice() throws DevFailed { xlogger.entry(); logger.debug("init device " + deviceManager.getName()); /*----- PROTECTED REGION ID(JavaDSTest.initDevice) ENABLED START -----*/ // Put your device initialization code here /*----- PROTECTED REGION END -----*/...
[ "public void initDevice() {\r\n\t\t\r\n\t}", "private void initDevice() {\n device = new Device();\n device.setManufacture(new Manufacture());\n device.setInput(new Input());\n device.setPrice(new Price());\n device.getPrice().setCurrency(\"usd\");\n device.setCritical(De...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
PLANNER COMMUNICATIONS METHODS Called when data has been received for the planner. flag output options are (OUTPUT_TO_LOG, OUTPUT_TO_FILE, OUTPUT_TO_LOG_AND_FILE, OUTPUT_TO_NONE)
public void receivedPlannerData(ArrayList<Integer> data, int flag) { String timeStamped = "[" + new Time(System.currentTimeMillis()) + "] "; String output = ""; for (int i=0;i<data.size();i++) { output += data.get(i); if (i != data.size()-1) output += ","; } switch (flag) { // Output data to log...
[ "public interface RpcLogger {\n\n\t/**\n\t * Logger a single RPC call.\n\t * \n\t * @param client the initiator of the RPC call.\n\t * @param server the server of the RPC all.\n\t * @param signature the service method called.\n\t * @param request protobuf.\n\t * @param response protobuf.\n\t * @param errorMessage i...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Creates a new telefono solicitud producto with the primary key. Does not add the telefono solicitud producto to the database.
public static com.ext.portlet.halcon.model.TelefonoSolicitudProducto create( long idTelefSolicitudProducto) { return getPersistence().create(idTelefSolicitudProducto); }
[ "@PostMapping(\"/productos\")\n @Timed\n public ResponseEntity<Producto> createProducto(@RequestBody Producto producto) throws URISyntaxException {\n log.debug(\"REST request to save Producto : {}\", producto);\n if (producto.getId() != null) {\n return ResponseEntity.badRequest().hea...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Gets the value of the messageNum property.
public long getMessageNum() { return messageNum; }
[ "public int getMessageNum() {\n return mMessageNum;\n }", "public java.lang.Integer getNummessage() {\r\n\t\treturn nummessage;\r\n\t}", "public int get_nbr_message() {\r\n return this.nbr_message;\r\n\r\n }", "public int getMessageNumber()\n {\n return _message.getMessageNumbe...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
This method was generated by MyBatis Generator. This method returns the value of the database column device.bb_guid
public String getBbGuid() { return bbGuid; }
[ "public void setBbGuid(String bbGuid) {\r\n\t\tthis.bbGuid = bbGuid;\r\n\t}", "public int getID_BBDD()\n\t{\n\t\treturn this.ID_BBDD;\n\t}", "public DeviceId intBrId() {\n return this.bridgeId;\n }", "public Integer getBlId() {\n return blId;\n }", "String getBPId();", "public Long get...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
True if has "declassEvent" attribute
boolean isSetDeclassEvent();
[ "java.lang.String getDeclassEvent();", "void setDeclassEvent(java.lang.String declassEvent);", "public boolean hasDetonated()\r\n\t{\r\n\t\treturn detonated;\r\n\t}", "void unsetDeclassEvent();", "@objid (\"0480e45a-6886-42c0-b13c-78b8ab8f713d\")\n boolean isIsEvent();", "public boolean hasEVENTDT() {\...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Sets whether to use step filters.
public static void setUseStepFilters(boolean useFilters) { fgUseStepFilters = useFilters; setStateModified(true); }
[ "public static boolean useStepFilters() {\r\n \t\treturn fgUseStepFilters;\r\n \t}", "public static boolean getDefaultUseStepFilters() {\r\n \t\treturn false;\r\n \t}", "public void setElseFilter(final boolean value) {\n isElseFilter = value;\n }", "public void setIsFilter(java.lang.String isFilter)...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Get the model for entry for xml
public Map<String, String> getModelForEntryForXml( IEntry entry ) { Map<String, String> model = new HashMap<String, String>( ); model.put( Entry.ATTRIBUTE_ENTRY_ID, String.valueOf( entry.getIdEntry( ) ) ); model.put( Entry.ATTRIBUTE_TITLE, StringEscapeUtils.escapeXml( entry.getTitle( ) ) ); ...
[ "private GenericModel extractModelFromRef(String ref) {\n\t\tString srcFile = extractFileNameFromRef(ref);\n\t\t// Extract the extension of the model file and find the corresponding model object in the registry\n\t\tString srcFileExtension = srcFile.substring(srcFile.lastIndexOf(\".\")+1, srcFile.length());\n\t\tGe...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
This method is used to add a food item to the favorites
public void addItemToFavorites(FoodItem item){ Log.d(TAG, "addItemToFavorites: adding item to the favorites"); String user_id = mAuth.getCurrentUser().getUid(); //Write an efficent firebase query here to get the food item and insert it into the cart // DatabaseReference reference = Fireb...
[ "@Override\n public void addFavorite(DiscoverMovieResponse.DiscoverMovie movie) {\n ContentValues contentValues = new ContentValues();\n contentValues.put(MoviesContract.COLUMN_MOVIE_ID_KEY, movie.getId());\n mContext.getContentResolver().insert(MoviesContract.Favorites.CONTENT_URI, contentV...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
BlockQueue testQueue=new BlockQueue(); testQueue.addQueueElement("a"); testQueue.addQueueElement("b"); testQueue.addQueueElement("c"); System.out.println(testQueue.getQueueElement()); System.out.println(testQueue.getQueueElement()); System.out.println(testQueue.getQueueElement());
public static void main(String[] args) { // System.out.println(testQueue.getQueueElement()); // System.out.println(testQueue.getQueueElement()); }
[ "@Test\n public void queue() {\n\n Queue<String> q = new LinkedList<>();\n q.offer(\"1\");\n q.offer(\"2\");\n q.offer(\"3\");\n System.out.println(q.offer(\"4\"));\n System.out.println(q.add(\"2\"));\n System.out.println(q.toString());\n System.out.println...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
This method compares two values in active status of CTrip Class and sorts in true order
@Override public int compare(Object o1, Object o2) { CTrip no1=(CTrip) o1; CTrip no2=(CTrip) o2; if (no1.isTripActive() == no2.isTripActive()) { return 0; } if(no1.isTripActive()) return 1; return -1; }
[ "private void sortByStatus()\n {\n Collections.sort(passengers, new PassengerComparator());\n }", "@Override\n public int compareTo(Train t) {\n if (this.getPriority() > t.getPriority()) {\n return 1;\n } //if the first train has higher priority return -1\n else if (t.getPr...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Sets the value of the 'field54' field.
public void setField54(java.lang.CharSequence value) { this.field54 = value; }
[ "public com.maxpoint.cascading.avro.TestExtraLarge.Builder setField54(java.lang.CharSequence value) {\n validate(fields()[54], value);\n this.field54 = value;\n fieldSetFlags()[54] = true;\n return this; \n }", "public void setField56(java.lang.CharSequence value) {\n this.field56 = valu...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
determine whehter the given pending budget construction general ledger is paid at a biweekly or hourly rate
public boolean isHourlyPaid(PendingBudgetConstructionGeneralLedger pendingBudgetConstructionGeneralLedger);
[ "public BigDecimal calculateHourlyPayRate(PendingBudgetConstructionAppointmentFunding appointmentFunding);", "float getBudget();", "public boolean isHourlyPaid(PendingBudgetConstructionAppointmentFunding appointmentFunding);", "int getRemainingBudget();", "public boolean isBancrupt(){\r\n \treturn _budge...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Returns a map of requirements (stable ids) of the job post.
public Map<String, Boolean> getRequirements() { return requirements; }
[ "public static void printJobPostingRequirements(JobPosting jobPosting) {\n SimpleDateFormat formatter = new SimpleDateFormat(\"MM/dd/yyyy\");\n String strDate = formatter.format(jobPosting.getRequirements().getApplicationsDeadlineDate());\n System.out.println(String.format(\n \"J...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Generator logic Stages: 1) Decide remove or not remove foods 2) Determine number of removed foods 3) Remove foods 4) Determine number of generated viruses to reach threshold 5) Generate food
@Override public void generate(@NotNull Duration elapsed) { //Remove or not? Random rand = new Random(); if (rand.nextDouble() > 1 - removeChance) { List<Food> foods = new ArrayList<>(getField().getCells(Food.class)); int toRemove = (int) (foods.size() * rand.nextDoub...
[ "public void GameCollisionFood(){\n\t\tint growthPool = 0;\n\t\tfor(GameObject food : gameObjectCollection){\n\t\t\tif(food instanceof Food){\n\t\t\t\tgrowthPool = ((Food)food).getAmount();\n\t\t\t\tSystem.out.println(\"\\n\" + \"Amount of food: \" + growthPool + \"\\n\");\n\t\t\t\tgameObjectCollection.remove(food)...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Gets the native handle.
public int getHandle() { return m_handle; }
[ "@CalledByNative\n public long getNativeBridge() {\n return mNativePointer;\n }", "public String getHandle() {\r\n return handle;\r\n }", "public String getHandle() {\n return this.handle;\n }", "long getHandle(JNIHandle jni) throws NoSuchFieldException, SecurityException, Ill...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Select candidate (If the array have the majority element, then the candidate is always this majority element) because major_count >= n/2 + 1
private static int getMajorityElementMooreVotingAlgorithm(int[] a) { int maj_index = 0; int count = 1; int candidate = a[0]; for (int i = 1; i < a.length; i++) { if (a[i] == candidate) { count++; } else { count--; } ...
[ "private static int findCandidate(int []arr){\n\t\t\n\t\tint major_index =0;\n\t\tint count =1;\n\t\t\n\t\tfor(int i=1; i< arr.length ;i++){\n\t\t\tif(arr[major_index] == arr[i]){\n\t\t\t\tcount++;\n\t\t\t}else{\n\t\t\t\tcount--;\n\t\t\t}\n\t\t\tif(count == 0){\n\t\t\t\tmajor_index = i;\n\t\t\t\tcount =1;\n\t\t\t}\...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Test of searchMovieBetweenStations method, of class MovieModel.
@Test public void testSearchMovieBetweenStations() { System.out.println("searchMovieBetweenStations"); MovieModel instance = new MovieModel(); ResultSet expResult = null; ResultSet result = instance.searchMovieBetweenStations(); assertEquals(expResult, result); ...
[ "@Test\r\n public void testSearchMovie() throws MovieDbException {\r\n LOG.info(\"searchMovie\");\r\n \r\n // Try a movie with less than 1 page of results\r\n List<MovieDb> movieList = tmdb.searchMovie(\"Blade Runner\", 0, \"\", true, 0);\r\n // List<MovieDb> movieList = tmdb.sear...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Metodo para retorno do catalogo de jogos (Lista de jogos comprados).
public List<Jogo> getListaDeJogosComprados() { return listaDeJogosComprados; }
[ "public List<Jogador> getListaJogadores() {\n terminarAVez();\n return this.listaJogadores;\n }", "public List<Jogo> jogosComJogabilidadeComum(Jogabilidade jogabilidade) {\r\n\t\tList<Jogo> listaDeJogosComMesmaJogabilidade = new ArrayList<Jogo>();\r\n\r\n\t\tfor (Jogo jogo : listaDeJogosComprados...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Highlight the selected message.
private void highlightSelectedMessage(boolean ensureSelectionVisible) { if (!isViewCreated()) { return; } final ListView lv = getListView(); if (mSelectedMessageId == -1) { // No message selected lv.clearChoices(); return; } ...
[ "public void highlight() {\n\t\t\n\t}", "public void drawHighlight() {\n if (highlighted){\n parent.pushStyle();\n parent.pushMatrix();\n parent.translate((float) x,(float) y);\n parent.noFill();\n parent.strokeWeight((float) (width / 16));\n parent.stroke(GuiConstants.colorWhite...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Compresses given files to given zipFile
public final void compress(final File zipFile, final File... files) { ZipCompression.compress(zipFile, this, files); }
[ "public static void zip(String[] files, String zipFile) { \n\n\t\ttry { \n\t\t\tBufferedInputStream origin = null; \n\t\t\tFileOutputStream dest = new FileOutputStream(zipFile); \n\n\t\t\tZipOutputStream out = new ZipOutputStream(new BufferedOutputStream(dest)); \n\n\t\t\tbyte data[] = new byte[BUFFER]; \n\n\t\t\t...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Method used to play the sound of a cue hitting the ball.
public void playCueSound() { playSound(cueSound); }
[ "public void playBallCollisionSound() {\n playSound(ballSound);\n\n }", "public void playBallBallCollisionSound() {\n \tSound collisionSound = game.getAssetManager().get(\"poolBall.mp3\");\n \tcollisionSound.play(0.9f);\n }", "public void playBallDoorCollisionSound() {\n \tSound collisionS...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Updates the role name associated to a client
private void updateKeycloakClientRole(Long resourceId, String oldRoleName, String newRoleName) { ClientResource clientResource = realmResource.clients().get(resourceId.toString()); RoleResource roleResource = clientResource.roles().get(oldRoleName); RoleRepresentation roleRepresentation = roleR...
[ "public void changeClientName() {\n String clientID = getToken(\"Enter the clients id that you want to modify: \");\n String name = getToken(\"Enter the new name: \");\n Client result = warehouse.changeName(clientID, name);\n if (result.getName() != name)\n System.out.println(...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
This method was generated by MyBatis Generator. This method returns the value of the database column PMSTRADE.SECURITY_DISCREPANCY
public String getSECURITY_DISCREPANCY() { return SECURITY_DISCREPANCY; }
[ "@Column(name = \"REC_SECURITY\")\n\tpublic String getRecSecurity()\n\t{\n\t\treturn recSecurity;\n\t}", "public void setSECURITY_DISCREPANCY(String SECURITY_DISCREPANCY) {\r\n this.SECURITY_DISCREPANCY = SECURITY_DISCREPANCY == null ? null : SECURITY_DISCREPANCY.trim();\r\n }", "public String getConf...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
read edge message (async)
@Override public EdgeResult readAsync(EdgeMessage msg) throws Exception { EdgeNodeInfo ep = msg.getRequest().getEdgeNodeInfo(); EdgeNodeIdentifier id = EdgeNodeIdentifier.ReadValueId; if (ep.getEdgeNodeID() != null) { id = ep.getEdgeNodeID().getEdgeNodeIdentifier(); } if (EdgeNodeIdentifier...
[ "void makeMessageRead();", "public void handleBeingRead(CMMsg msg);", "public ArduinoMessage read() {\n Log.d(TAG, \"In read.\");\n while (true) {\n try {\n return queue.takeFirst();\n } catch (InterruptedException e) { }\n }\n }", "private Message ...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Get a Widget deployment
public Future<WidgetDeployment> getWidgetsDeploymentAsync(GetWidgetsDeploymentRequest request, final AsyncApiCallback<WidgetDeployment> callback) { try { final SettableFuture<WidgetDeployment> future = SettableFuture.create(); final boolean shouldThrowErrors = pcapiClient.getShouldThrowErrors(); p...
[ "public Deployment getDeployment();", "public Future<ApiResponse<WidgetDeployment>> getWidgetsDeploymentAsync(ApiRequest<Void> request, final AsyncApiCallback<ApiResponse<WidgetDeployment>> callback) {\n try {\n final SettableFuture<ApiResponse<WidgetDeployment>> future = SettableFuture.create();\n f...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Set prefix & suffix for pseudo build.
public void setPrefixAndSuffix(String prefix, String suffix) { this.prefix = prefix; this.suffix = suffix; }
[ "public void setPropertyPrefix(String prefix);", "void setPrefix(String prefix);", "void setSuffix(String suffix);", "public void prefix( String base ) {\r\n\t\tthis.prefix = base;\r\n\t\ts.prefix( base );\r\n\t}", "public void setPropertyPrefix(String prefix) {\n \tpropertyPrefix = prefix;\n }", "pri...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
RenderableTo Created by jedabero on 26/10/15.
public interface RenderableTo { void render(Graphics graphics, int x, int y); }
[ "public Renderer(Object toRender) {\n this.toRender = toRender;\n }", "private void createRenderable() {\n\n ModelRenderable.builder()\n // To load as an asset from the 'assets' folder ('src/main/assets/andy.sfb'):\n .setSource(this, Uri.parse(\"earth.sfb\"))\n\n ...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Test method associate(). Modification date is null, IPE expected.
public void testassociate8() throws Exception { try { Address address = this.getAddress(); address.setCreationDate(new Date()); address.setModificationDate(new Date()); address.setModificationDate(null); this.dao.associate(address, 1, false); ...
[ "public void testassociate7() throws Exception {\r\n try {\r\n Address address = this.getAddress();\r\n address.setCreationDate(new Date());\r\n address.setModificationDate(new Date());\r\n address.setCreationDate(null);\r\n this.dao.associate(address, 1...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Maps the source Array into a new List parameterized by destinationClass.
<S, D> List<D> mapAsList(S[] source, Class<D> destinationClass, MappingContext context);
[ "<S, D> List<D> mapAsList(S[] source, Class<D> destinationClass);", "<S, D> List<D> mapAsList(Iterable<S> source, Class<D> destinationClass);", "<S, D> List<D> mapAsList(S[] source, Type<S> sourceType, Type<D> destinationType);", "<S, D> D[] mapAsArray(D[] destination, S[] source, Class<D> destinationClass);"...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Returns whether the the config should be automatically reloaded
public boolean isAutoReload() { return this.autoReload; }
[ "boolean isConfigurationReload();", "public boolean isForceReloadCheck()\n {\n return forceReloadCheck;\n }", "@Override\n\tpublic boolean hasConfigChanged() {\n\t\treturn false;\n\t}", "private boolean configUpdated() {\r\n try {\r\n URL url = ctx.getResource(XHP_CONFIG);\r\n ...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Constructs a new empty StringEditor with the specified number of columns. A default model is created and the initial string is set to null.
public StringEditor(int aColumns) { super(aColumns); // Don't make right-justified }
[ "public NullStringEditor () {\n super();\n editable = true;\n }", "public StringEditor() {\n\t\tsuper();\n\t\tmEditor = new JTextField();\n\t\t\n\t}", "public JTextField(int columns) {\n this(null, null, columns);\n }", "public JHelpEditText(final int columns)\n {\n this(J...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Setter for the entry list reference.
public void setEntryList(List<Entry> entryList) { this.entryList = entryList; }
[ "protected void setRefList( ReferenceList refList )\n {\n _refList = refList;\n }", "public Registry(List<Entry> entryList){\n\t\tthis.entryList = entryList;\n\t}", "public ListEntry() {\n this.data = null;\n this.next = null;\n this.prev = null;\n }", "void setEntries(Lis...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Sets the XMLReader used to write SAX events to
public void setXMLReader(XMLReader xmlReader) { setContentHandler(xmlReader.getContentHandler()); setDTDHandler(xmlReader.getDTDHandler()); setEntityResolver(xmlReader.getEntityResolver()); setErrorHandler(xmlReader.getErrorHandler()); }
[ "public void setReader(Object reader) {\n\t\tthis.reader = reader;\n\t\tthis.handleConfig(\"reader\", reader);\n\t}", "void setReaders(XMLReader sourceReader, XMLReader stylesheetReader);", "public void configureSettings(XMLStreamReader reader) throws TJXMLException, XMLStreamException;", "public void setInpu...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Signal to the operator that they won bid
public void wonBid(String bid) { sendMessage(Prefix.WONBID, bid); }
[ "public void eventMakeBid(Player player, int bid);", "public void setWon(){\n won = true;\n }", "public void buyFarm(){\n bought = !bought;\n }", "public void beInvincible() {\n \tthis.invincible = true;\n \tthis.dungeon.Notify();\n }", "private void bust() {\n //Dialog b...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
$ANTLR end "rule__Table__Group__7" $ANTLR start "rule__Table__Group__7__Impl" InternalMyDsl.g:2474:1: rule__Table__Group__7__Impl : ( ( rule__Table__Group_7__0 )? ) ;
public final void rule__Table__Group__7__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { // InternalMyDsl.g:2478:1: ( ( ( rule__Table__Group_7__0 )? ) ) // InternalMyDsl.g:2479:1: ( ( rule__Table__Group_7__0 )? ) { ...
[ "public final void rule__Table__Group_7__0() throws RecognitionException {\n\n \t\tint stackSize = keepStackSize();\n \t\n try {\n // InternalMyDsl.g:2952:1: ( rule__Table__Group_7__0__Impl rule__Table__Group_7__1 )\n // InternalMyDsl.g:2953:2: rule__Table__Group_7__0__Imp...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Get Access Instructions Window Text
public String getAccessInstructionsWindowText(){ WebElement accessInstructions = driver.findElement(By.xpath("//div[contains(@class,'resizable-pinned') and contains(@style,'visibility: visible')]//div[contains(@class,'x-html-editor')]//textarea")); String instr = accessInstructions.getAttribute("value"); ...
[ "public String getInfoText();", "public String getAboutBoxText();", "public String getInstructionalText() throws Exception {\n strResult = null;\n try {\n logInstruction(\"LOG INSTRUCTION :GETTING INSTRUCTIONAL TEXT\");\n frameSwitch.switchToAddLinkFrame();\n uiDri...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
This will create a new packet for the listed recipient It should also fill the packet with data for the recipient
public Packet createPacket(int recipientID);
[ "private static DatagramPacket createPacket(byte[] data, SocketAddress remote) {\r\n\t\tDatagramPacket packet = new DatagramPacket(data, data.length, remote);\r\n\t\treturn packet;\r\n\t}", "void handleNewDataPacket(UDPAddress sender, UDPDataPacket packet) {\n Hashtable<Integer, UDPDataPacket> waitArea ...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
fetching all data in podcast table from database
@Override public Set<Podcast> getAllPodcast() { String query="select * from podcast"; try { Statement statement= connection.createStatement(); ResultSet resultSet=statement.executeQuery(query); while(resultSet.next()) { podcas...
[ "public static ArrayList<Song> getAll() {\n ArrayList<Song> songs = new ArrayList<>();\n try {\n Class.forName(\"com.mysql.jdbc.Driver\");\n conn = DriverManager.getConnection(\"jdbc:mysql://\" + host + \"/\" + db + \"?\" + \"user=\" + user + \"&password=\" + psw );\n\n ...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
repeated .adamant.global.v1.WalletType wallet_type = 8 [json_name = "walletType"];
@java.lang.Override public int getWalletTypeValue(int index) { return walletType_.get(index); }
[ "lightpay.lnd.grpc.NewAddressRequest.AddressType getType();", "@java.lang.Override\n public adamant.global.v1.Enum.WalletType getWalletType(int index) {\n return walletType_converter_.convert(walletType_.get(index));\n }", "TokenlyBalancesType getType();", "com.whiuk.philip.mmorpg.shared.Messages.ClientM...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Returns the RecordTemplate of the publication data item.
public RecordTemplate getRecordTemplate() throws PublicationTemplateException;
[ "public interface PublicationTemplate {\r\n \r\n /**\r\n * Returns the RecordTemplate of the publication data item.\r\n */\r\n public RecordTemplate getRecordTemplate() throws PublicationTemplateException;\r\n \r\n /**\r\n * Returns the RecordSet of all the records built from this template.\r\n */...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Set the info about the output to write for the Job. This queries the metadata server to find the StorageDriver to use for the table. Throws error if partition is already published.
@SuppressWarnings("unchecked") public static void setOutput(Job job, HowlTableInfo outputInfo) throws IOException { HiveMetaStoreClient client = null; try { client = createHiveClient(outputInfo.getServerUri(), job.getConfiguration()); Table table = client.getTable(outputInfo.getDa...
[ "private void setStorageInfo(){\n float maxStorage = watch.getWatchData().getMaxStorage();\n float usedStorage = watch.getWatchData().getUsedStorage();\n String labelText = usedStorage + \"/\" + maxStorage + \" MB used\";\n\n storageBar.setProgress(usedStorage / maxStorage);\n sto...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Indicates whether an initial value is provided for the given node type and attribute key
boolean provideInitialAttributeValue(NodeType type, String attributeName);
[ "public boolean hasInitialValue() {\n return Objects.nonNull(getInitialValue());\n }", "protected abstract boolean attributeFits(String value);", "boolean isSetDefaultValue();", "private boolean hasAttributeKey(String xryLine) {\n int attributeKeyIndex = xryLine.indexOf(KEY_VALUE_DELIMITER);\...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
allow to change the publication state of node to draft or published state
public void changeState(Node node, String status) throws ValueFormatException, PathNotFoundException, UnsupportedRepositoryOperationException, LockException, RepositoryException, IncorrectStateUpdateLifecycleException, Exception { if (node.hasProperty(StageAndVersionPublicationConstant.PUBLICATION_...
[ "public void setPublished(boolean value) {\n this.published = value;\n }", "public void setIsPublished(Boolean isPublished) {\n this.isPublished = isPublished;\n }", "public void setIsPublish(Boolean isPublish) {\n this.isPublish = isPublish;\n }", "public void forcePublish(Publi...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
A method to set if the player is computer.
public void setIfComputer(boolean state) { isComputer = state; }
[ "public boolean isItComputer()\n {\n return isComputer;\n }", "public abstract boolean isComputer();", "void setComputer(Computer computer);", "boolean isComputerControlled();", "private void setComputerChoice() {\n\t\tcomputerChoice = POSSIBLE_CHOICE[randomNumber];\n\t}", "public void setCom...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
$ANTLR end "rule__DeclareList__Group_1__0" $ANTLR start "rule__DeclareList__Group_1__0__Impl" InternalDsl.g:9194:1: rule__DeclareList__Group_1__0__Impl : ( ';' ) ;
public final void rule__DeclareList__Group_1__0__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { // InternalDsl.g:9198:1: ( ( ';' ) ) // InternalDsl.g:9199:1: ( ';' ) { // InternalDsl.g:9199:1: ( ';' ) /...
[ "public final void rule__DeclareList__Group_1__1() throws RecognitionException {\n\n \t\tint stackSize = keepStackSize();\n \t\n try {\n // InternalDsl.g:9213:1: ( rule__DeclareList__Group_1__1__Impl )\n // InternalDsl.g:9214:2: rule__DeclareList__Group_1__1__Impl\n ...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Constructor of class ReviewInfo that creates object based on appropriate JSONObject data. Constructor parses json object and extracts each field by key.
public ReviewInfo(JSONObject jsonReview) throws JSONException { String strType = jsonReview.getString(JSON_PARAM_TYPE); if(strType.equals(EntityInfo.JSON_VALUE_POLICIES)) { m_type = EntityType.kPolices; } else { m_type = EntityType.kParty; ...
[ "public ReviewInfo()\n {\n m_nReviewValue = REVIEW_VALUE_POSITIVE;\n m_nID = 1;\n m_type = EntityType.kPolices;\n m_strReviewText = \"\";\n }", "public static Review parseItemJson(JSONObject itemJSON) throws JSONException {\n JSONObject obj = itemJSON;\n Review item...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Insert a new filter entry
private void insertRow(String filter, boolean active, boolean include, int type, @Nullable String key, @Nullable String value) { ContentValues values = new ContentValues(); values.put(FILTER_COLUMN, filter); values.put(ACTIVE_COLUMN, active ? 1 : 0); values.put(INCLUDE_COLUMN, include ? ...
[ "public void insert(int index, FilterListEntry entry) {\r\n \tentries.insertElementAt(entry, index);\r\n }", "void addFirst(String name, Filter filter);", "void addBefore(String name, Filter filter);", "public void addFilter() {\n\t\tStringBuffer messageBuffer = new StringBuffer();\n\t\t\n\t\t// we have...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Custom volume configuration for the root volumes that are attached to streaming sessions. This parameter is only allowed when sessionPersistenceMode is ACTIVATED.
public VolumeConfiguration getVolumeConfiguration() { return this.volumeConfiguration; }
[ "public StreamingSession withVolumeConfiguration(VolumeConfiguration volumeConfiguration) {\n setVolumeConfiguration(volumeConfiguration);\n return this;\n }", "Map<String, SapDiskConfiguration> volumeConfigurations();", "com.google.cloud.baremetalsolution.v2.VolumeConfig getVolumes(int index);...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Metodo para escribir una frase de matrix en un fichero Para que cuando ejecutes el programa no se escriba mas de 1 vez o hayan errores comprobamos si el length del fichero es mas de 0, eso significa que esta escrito si el length es 0, significa que esta vacio, entonces introducimos la frase
public static void ejercicio() { File f = new File("..\\M6_salasA\\frasesMatrix.txt"); FileWriter fw; try { fw = new FileWriter(f); if (!f.exists()) { f.createNewFile(); } if (f.length() == 0) { fw.write("Yo solo puedo mostrarte la puerta, tú eres quien la tiene que atravesar."); } fw...
[ "public void savePartialMatrizInFile(String nameFile, int lStart, int cStart, int lAmount, int cAmount)\n {\n //definir dados\n int lin;\n int col;\n int i, j;\n FILE arquivo;\n String linha;\n\n //obter dimensoes de linha e coluna\n lin = lines();\n ...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
carves out vertical corridors
public void vCorridor(int x, int y1, int y2){ for (int i=Math.min(y1,y2); i<=Math.max(y1,y2); i++){ grid[i][x] = 1; } }
[ "public void circulos() {\n pushMatrix();\n translate(width/2, height/2);\n rotate(-h);\n noFill();\n strokeWeight(5);\n stroke(255);\n ellipse(10, 10, 20, 20);\n popMatrix();\n\n h = h + 0.3f;\n }", "@Test\n\tpublic void testCuatroEnRayaVertical() {\n\t\t\n\t\tint []posX = new int[4];...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
An object that contains details about an aggregation request based on Amazon Machine Images (AMIs).
public AmiAggregation getAmiAggregation() { return this.amiAggregation; }
[ "public AggregationRequest withAmiAggregation(AmiAggregation amiAggregation) {\n setAmiAggregation(amiAggregation);\n return this;\n }", "public void setAmiAggregation(AmiAggregation amiAggregation) {\n this.amiAggregation = amiAggregation;\n }", "public interface Aggregation {\n\n ...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
construct a new channel category bean for this category
private ChannelCategoryBean addChildren(WebRequest request, PortletCategory category, List<IPortletDefinition> allChannels, IPerson user, String type, Locale locale) { ChannelCategoryBean categoryBean = new ChannelCategoryBean(category); categoryBean.setName(messageSource.getMessage(category.getName(), ...
[ "private void createChannelComponent() {\n if (getComponent(ChannelComponentMO.class)!=null)\n return;\n \n addComponent(new ChannelComponentMO(this));\n }", "private ChannelCategoryBean prepareCategoryBean(\n WebRequest request,\n PortletCategory category,\n ...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Returns the result of interpreting the object as an instance of 'Change Transaction'. This implementation returns null; returning a nonnull result will terminate the switch.
public T caseChangeTransaction(ChangeTransaction object) { return null; }
[ "public T caseTransaction(Transaction object) {\n\t\treturn null;\n\t}", "public T caseEntityChange(EntityChange object) {\n\t\treturn null;\n\t}", "public T caseRelationChange(RelationChange object) {\n\t\treturn null;\n\t}", "public T caseTransactionMode(TransactionMode object) {\n\t\treturn null;\n\t}", ...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
add replies to the given annotation
private void addAnnotationReplies(Collection<Annotation> annotations) { for(Annotation annotation : annotations) { ArrayList<Annotation> replies = allReplies.remove(annotation.getId()); if(replies!=null) { annotation.setReplies(replies); addAnnotationReplies(replies); } } }
[ "public void add(ReplyToPost reply){\n super.add(reply);\n list.add(reply);\n }", "public void setReplies(List<String> replies) {\n this.replies = replies;\n }", "public void addReplyTo(AID dest) {\n\t\tif (dest != null) { \n\t\t\t//#MIDP_EXCLUDE_BEGIN\n\t\t\treply_to = (reply_to == nul...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Returns true if field withSemanticFiltering is set (has been assigned a value) and false otherwise
public boolean isSetWithSemanticFiltering() { return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __WITHSEMANTICFILTERING_ISSET_ID); }
[ "public boolean isFilterOn() {\r\n\t\treturn !packageTypeSet.isEmpty();\r\n\t}", "@DISPID(3083)\n @PropGet\n boolean getIsFiltered();", "public boolean isLogicalFilterSetted() {\n\t\treturn engine.isPropertySetted(Properties.LOGICAL_FILTER);\n\t}", "public boolean isFiltered() {\r\n\r\n return is_fil...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Sets the patTpcd value for this ForeignPatentDocumentsInfo.
public void setPatTpcd(java.lang.String patTpcd) { this.patTpcd = patTpcd; }
[ "public void setPatDt(java.lang.String patDt) {\n this.patDt = patDt;\n }", "public void setCorgPatno(java.lang.String corgPatno) {\n this.corgPatno = corgPatno;\n }", "public void setPatN(double v) {\n if (Problem_Type.featOkTst && ((Problem_Type)jcasType).casFeat_PatN == null)\n jc...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Gets the value of the 'clientInstanceId' field.
public Energistics.Etp.v12.Datatypes.Uuid getClientInstanceId() { return clientInstanceId; }
[ "public Energistics.Etp.v12.Datatypes.Uuid getClientInstanceId() {\n return clientInstanceId;\n }", "public void setClientInstanceId(Energistics.Etp.v12.Datatypes.Uuid value) {\n this.clientInstanceId = value;\n }", "public java.lang.String getClientID() {\n return clientID;\n }", "public java.lan...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Get SQL92_RESERVED_WHERE node from the subtree of SQL92_RESERVED_SELECT
public static SqlASTNode getWhereInSelectRaw(SqlASTNode selectKey) { assert (selectKey.getType() == PantheraParser_PLSQLParser.SQL92_RESERVED_SELECT); return (SqlASTNode) selectKey .getFirstChildWithType(PantheraParser_PLSQLParser.SQL92_RESERVED_WHERE); }
[ "public final where_key_return where_key() throws RecognitionException {\n where_key_return retval = new where_key_return();\n retval.start = input.LT(1);\n\n\n Object root_0 = null;\n\n Token SQL92_RESERVED_WHERE543=null;\n\n Object SQL92_RESERVED_WHERE543_tree=null;\n\n t...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Get The public IP object array of the bound NAT gateway.
public NatGatewayAddress [] getPublicIpAddressSet() { return this.PublicIpAddressSet; }
[ "public List<String> internalInboundIpAddresses() {\n return this.innerProperties() == null ? null : this.innerProperties().internalInboundIpAddresses();\n }", "public String getPublicIpAddress() {\n return publicIpAddress;\n }", "public String[] getIpAddresses()\n {\n return ipAdd...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Clears the value of the 'uid' field
public influent.idl.FL_Cluster.Builder clearUid() { uid = null; fieldSetFlags()[0] = false; return this; }
[ "public com.example.DNSLog.Builder clearUid() {\n uid = null;\n fieldSetFlags()[0] = false;\n return this;\n }", "public Term.Builder clearUid() {\n uid = null;\n fieldSetFlags()[0] = false;\n return this;\n }", "public void clearUser() {\n setUse...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
tests the lookup method in multiple situations
@Test public void testLookup() { hashy.insert("yes"); assertTrue("Checks single", hashy.lookup("yes")); assertFalse("Checks single", hashy.lookup("no")); hashy.insert("no"); hashy.insert("ok"); hashy.insert("maybe"); assertFalse("Checks multiple", hashy.lookup("oops")); assertTrue("Checks multiple", h...
[ "Lookup getLookup();", "@Test\n public void testLookup() throws Exception {\n // Setup\n final String name = \"STD ENGINE 105\";\n final Item expected = ItemDB.lookup(name);\n\n // Lookup by name\n assertNotNull(ItemDB.lookup(name));\n\n // Lookup by MWO ID\n as...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Recalculates the image histogram and resets the palette. Called periodically during the fit.
public void recalcHistogram();
[ "void resetData() {\n red = new RedHistogram();\n green = new GreenHistogram();\n blue = new BlueHistogram();\n }", "public void updateHistogram() {\n\n // Dont bother updating histogram if tab not even visible, save resources.\n if (!this.isVisible()) {\n return;\...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Handle when the module destroy
private void onModuleDestroy() { //! //! Handle the destroy notification. //! mLifecycle.onPause(); mLifecycle.onDispose(); //! //! Unload resource module. //! mResources.onModuleDestroy(); mResources.unloadAll(); //! //!...
[ "private void onModuleDestroy() {\n //!\n //! Handle the destroy notification.\n //!\n mLifecycle.onPause();\n mLifecycle.onDispose();\n\n //!\n //! Unload resource module.\n //!\n mResources.onModuleDestroy();\n mResources.unloadAll();\n\n ...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Adds new QA test to database. When TestId is null, then a new number is generated.
@RequestMapping("/{datasetid}/add") public String addQATest(QATest qatest, @PathVariable("datasetid") String datasetId, RedirectAttributes redirectAttributes) { String testtype = qatest.getTestType(); if (testtype.trim().equals("")) { redirectAttributes.addFlashAt...
[ "private int insert_test_in_db() throws SQLException\n {\n String query = \"INSERT INTO Test_item ( test_id, description ) \" +\n \"VALUES ( '\" + this.test_id.toString() + \"'\"+\n \", '\" + this.test_text_area.getText() + \"' )\";\n\n return db.execute_update(query...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
For parameterized types returns the list of parameters.
List<Type> getTypeParameters();
[ "Collection<Parameter> getTypedParameters();", "default Class<?>[] getParameterTypes()\n\t\t{\n\t\t\treturn get().getParameterTypes();\n\t\t}", "public List<AbstractTypeVariable> getTypeParameters() {\n return new ArrayList<>();\n }", "public CxxType[] getParamTypes() {\n CxxType[] paramsT = new Cx...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
$ANTLR end "entryRulePModel" $ANTLR start "rulePModel" ../org.osate.xtext.aadl2.properties/srcgen/org/osate/xtext/aadl2/properties/parser/antlr/internal/InternalPropertiesParser.g:70:1: rulePModel returns [EObject current=null] : this_ContainedPropertyAssociation_0= ruleContainedPropertyAssociation ;
public final EObject rulePModel() throws RecognitionException { EObject current = null; EObject this_ContainedPropertyAssociation_0 = null; enterRule(); try { // ../org.osate.xtext.aadl2.properties/src-gen/org/osate/xtext/aadl2/properties/parser/antlr/intern...
[ "public final EObject entryRulePModel() throws RecognitionException {\n EObject current = null;\n\n EObject iv_rulePModel = null;\n\n\n try {\n // ../org.osate.xtext.aadl2.properties/src-gen/org/osate/xtext/aadl2/properties/parser/antlr/internal/InternalPropertiesParser.g:62:2: (iv_r...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Method to test mirrorVertical
public static void testMirrorVertical() { Picture caterpillar = new Picture("caterpillar.jpg"); caterpillar.explore(); caterpillar.mirrorVertical(); caterpillar.explore(); }
[ "public static void testMirrorVertical()\n {\n CollageLab caterpillar = new CollageLab(\"caterpillar.jpg\");\n caterpillar.explore();\n caterpillar.mirrorVertical();\n caterpillar.explore();\n }", "public static void testMirrorVertical()\n {\n Picture caterpillar = new Picture(\"caterpillar.jpg\...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
This method helps publishing Position Demands for ECS using Event Service
private void publishEcsPositionDemand(Optional<IEventService> eventService, ConfigKey configKey, DoubleItem azItem, DoubleItem elItem) { SystemEvent se = jadd(new SystemEvent(configKey.prefix()), azItem, elItem); log.debug("Inside TpkEventPublisher publishEcsPositionDemand " + configKey + ": " + se + ": eventSer...
[ "private void publishMcsPositionDemand(Optional<IEventService> eventService, ConfigKey configKey, DoubleItem azItem,\n\t\t\tDoubleItem elItem) {\n\t\tSystemEvent se = jadd(new SystemEvent(configKey.prefix()), azItem, elItem);\n\t\tlog.debug(\"Inside TpkEventPublisher publishMcsPositionDemand \" + configKey + \": \"...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Given a NoxItem position try to load this NoxItem if the view is not performing a fast scroll after a fling gesture.
private void loadNoxItem(int position) { if (!scroller.isScrollingFast()) { noxItemCatalog.load(position, useCircularTransformation); } }
[ "@Override\n\t\t\tpublic void onScroll(AbsListView view, int firstVisibleItem,\n\t\t\t\t\tint visibleItemCount, int totalItemCount) {\n\t\t\t\tif(((firstVisibleItem+visibleItemCount+50)>totalItemCount) && (!isLoad) && state>0){\n\t\t\t\t\t\n\t\t\t\t\t//if(!getLoaderManager().getLoader(0).isStarted()){\n\t\t\t\t\t\t...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
domain status. enum values are akin to those of zimbraAccountStatus zimbraAccountStatus values: active active lockout no login until lockout duration is over locked no login maintenance no login, no delivery(try again, no bouncing) pending no login, no delivery(bouncing mails), Account behavior is like closed, except t...
@ZAttr(id=535) public void unsetDomainStatus() throws com.zimbra.common.service.ServiceException { HashMap<String,Object> attrs = new HashMap<String,Object>(); attrs.put(Provisioning.A_zimbraDomainStatus, ""); getProvisioning().modifyAttrs(this, attrs); }
[ "DomainStatus getDomainStatus();", "@ZAttr(id=535)\n public ZAttrProvisioning.DomainStatus getDomainStatus() {\n try { String v = getAttr(Provisioning.A_zimbraDomainStatus); return v == null ? null : ZAttrProvisioning.DomainStatus.fromString(v); } catch(com.zimbra.common.service.ServiceException e) { re...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Enables recording to a filename, generator only writes all the objects on shutdown
public void enableRecording(String filename){ logger.debug("Enabled recording to file:"+filename); mode = Mode.RECORD; this.filename = filename; logger.info("Recording enabled"); }
[ "private void startRecordingToFile() {\n\t\tfindViewById(R.id.buttonStopRecording).setEnabled(true);\n\t\tfindViewById(R.id.buttonStartRecording).setEnabled(false);\n\n\t\tDate startDate = new Date();\n\t\t// Create a new folder that represents the date and time when we started to record\n\t\tFile directory = new F...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
/ API for Streaming Environment Run TF train for DataStream.
public static <OUT> DataStream<OUT> train(StreamExecutionEnvironment streamEnv, TFConfigBase tfConfig) throws IOException { return train(streamEnv, tfConfig, (TypeInformation<OUT>) null); }
[ "public static <OUT> DataStream<OUT> train(StreamExecutionEnvironment streamEnv,\n\t\t\t\t\t\t\t\t\t\t\t TFConfigBase tfConfig, TypeInformation<OUT> outTI) throws IOException {\n\t\treturn run(streamEnv, ExecutionMode.TRAIN, null, tfConfig, outTI);\n\t}", "public static <IN, OUT> DataStream<OUT> train(StreamExec...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Dereference some content! This means replacing any reference inside the content by the full referenced content. The result is an artifact content that can be used on its own.
public interface ContentDereferencer { /** * Called to dereference the given content to its dereferenced form * @param content */ ContentHandle dereference(ContentHandle content, Map<String, ContentHandle> resolvedReferences); /** * Called to rewrite any references in the content s...
[ "ContentHandle dereference(ContentHandle content, Map<String, ContentHandle> resolvedReferences);", "public Content getRefContent();", "ContentHandle rewriteReferences(ContentHandle content, Map<String, String> resolvedReferenceUrls);", "public interface ReferencedContent extends Content {\n // Constants -...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Container's getter for VbookPublisherVO1.
public ViewObjectImpl getVbookPublisherVO1() { return (ViewObjectImpl)findViewObject("VbookPublisherVO1"); }
[ "public TemplateViewObject getPublisherVO1() {\n return (TemplateViewObject)findViewObject(\"PublisherVO1\");\n }", "public ViewObjectImpl getRep_PublisherVo1() {\n return (ViewObjectImpl)findViewObject(\"Rep_PublisherVo1\");\n }", "public ViewObjectImpl getSuggestedPublisherVo1() {\n ...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
/ Joins two (tabseparated) files by comparing the values specified in leftindex and rightIndex
public void LeftJoin(String leftFile, String rightFile, String outFile, int leftIndex, int rightIndex) { }
[ "public void LeftIndexedJoin(String leftFile, String indicesFile, String outFile, String value, String noValue, boolean keepLeftValue) throws IOException\r\n\t{\t\t\r\n\t\tString line;\r\n\t\t\r\n\t\tArrayList<Integer> indexValues = new ArrayList<Integer>();\r\n\t\t\r\n\t\tSystem.out.println(\"Reading indices into ...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Gets the status exception.
public List<StatusException> getStatusException() { return statusException; }
[ "public java.lang.String getEstatus() {\n return estatus;\n }", "public String exception() {\n return this.exception;\n }", "Exception getException();", "public Throwable getException(){\n\t\treturn testResult.getException();\n\t}", "com.github.jtendermint.jabci.types.Types.ResponseExcep...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
This constructor should generally not be used directly. Instead use AggregationQueryBuilder to construct this object.
public AggregationQuery( final CommonQueryOptions commonQueryOptions, final AggregateTypeQueryOptions<P, R, T> dataTypeQueryOptions, final IndexQueryOptions indexQueryOptions, final QueryConstraints queryConstraints) { super(commonQueryOptions, dataTypeQueryOptions, indexQueryOptions, queryC...
[ "private StructuredAggregationQuery(com.google.protobuf.GeneratedMessageV3.Builder<?> builder) {\n super(builder);\n }", "AggregationBuilder buildAggregation();", "public QueryResultAdapter(AggregationQuery q)\n {\n this(q, (UID) null);\n }", "public Query(){\n this(new MongoQueryFilter....
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Test case number: 48 / 23 covered goals: Goal 1. org.jfree.chart.renderer.category.AbstractCategoryItemRenderer.setLegendItemLabelGenerator(Lorg/jfree/chart/labels/CategorySeriesLabelGenerator;)V: Line 736 Goal 2. org.jfree.chart.renderer.category.AbstractCategoryItemRenderer.()V: Line 256 Goal 3. org.jfree.chart.rende...
@Test public void test48() throws Throwable { StatisticalLineAndShapeRenderer statisticalLineAndShapeRenderer0 = new StatisticalLineAndShapeRenderer(); CategorySeriesLabelGenerator categorySeriesLabelGenerator0 = statisticalLineAndShapeRenderer0.getLegendItemToolTipGenerator(); // Undeclared excep...
[ "@Test\n public void test04() throws Throwable {\n CategoryStepRenderer categoryStepRenderer0 = new CategoryStepRenderer();\n CategoryTextAnnotation categoryTextAnnotation0 = new CategoryTextAnnotation(\"Base item URL generator not cloneable.\", (Comparable) \"Base item URL generator not cloneable.\", ...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
setSentido Metodo modificador usado para cambiar el bSentido del objeto
public void setSentido(boolean bSentido) { this.bSentido = bSentido; }
[ "public void cambieSentido() {\n\t\tsentidoLR=(!sentidoLR);\n\t}", "public void setSentidoLlenado(String sentidoLlenado) {\n this.sentidoLlenado = sentidoLlenado;\n }", "public void setSentTo(int sentTo) {\n this.sentTo = sentTo;\n }", "public boolean getSentido() {\r\n return this.bSenti...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Get all the comments from the server
private static void getAllComments() { String response = webTarget.path("/comments/all") .request() .accept(MediaType.TEXT_PLAIN) .get(String.class); System.out.print(response); System.out.println("-------------------"); System.out.println(...
[ "public static AllComments getAllComments() {\n String baseUrl = prop.getProperty(BASE_URL);\n String commentsEndpoint = prop.getProperty(COMMENTS_ENDPOINT);\n String url = baseUrl + commentsEndpoint;\n log.info(\"URL to be hit:\" + url);\n\n Response response = when().get(url);\n...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Sets the subscriberName value for this UpdateRecurringPaymentsProfileRequestDetailsType.
public void setSubscriberName(java.lang.String subscriberName) { this.subscriberName = subscriberName; }
[ "public void setSubscriberId(java.lang.String subscriberId) {\n this.subscriberId = subscriberId;\n }", "public void setSubscriber(com.huawei.www.bme.cbsinterface.cbs.businessmgr.NewSubscriberExtRequestSubscriber subscriber) {\r\n this.subscriber = subscriber;\r\n }", "public java.lang.Strin...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Shows courses registered to the instructor with the entered ID
@GetMapping("/courses/{id}") public ResponseEntity<List<Course>> coursesOfInstructor(@PathVariable int id){ return new ResponseEntity<>(instructorService.coursesOfInstructor(id),HttpStatus.ACCEPTED); }
[ "@Override\r\n\tpublic void showCourses() {\r\n\t\t// TODO Auto-generated method stub\r\n\t\tSystem.out.println(\"\\n========================================================================\");\r\n\t\tSystem.out.println(\"\\t\\t\\tAvailable Courses\");\r\n\t\tSystem.out.println(\"===================================...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Find the biggest and the smallest integer in an array, and swap them
static void swapSmallestAndBiggest( int array[] ) { // TODO }
[ "public static void SwapLargestSmallest(int[] array) {\n\n }", "public static int[] getLargestAndSmallest(int[] array)\n\t{\n\t\tint[] result = new int[2];\n\t\tint limit = array.length;\n int temp = 0;\n // The outer loop determines the number of passes \n // through the array that will t...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
minimapCursor = Numeric value to convert to text.
public static MinimapCursorEnum valueOf(int minimapCursor) { // The function converts the passed numeric value to its corresponding text. return (MinimapCursorEnum) minimapCursorMap.get(minimapCursor); }
[ "public int getValue() \n {\n return minimapCursorEnum;\n }", "@Override\n public void output(Word value){ \n Integer integerValue = value.getUnsignedValue();\n int intValue = (int)integerValue; \n guiDisplay.append(String.valueOf((char)intValue)); ...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Regression test for HDFS2753. In this bug, the following sequence was observed: Some blocks are written to DNs while the SBN was down. This causes the blockReceived messages to get queued in the BPServiceActor on the DN. When the SBN returns, the DN reregisters with the SBN, and then flushes its blockReceived queue to ...
@Test public void testBlocksAddedWhileStandbyIsDown() throws Exception { DFSTestUtil.createFile(fs, new Path("/test"), 3*BLOCK_SIZE, (short) 3, 1L); banner("Stopping standby"); cluster.shutdownNameNode(1); DFSTestUtil.createFile(fs, new Path("/test2"), 3*BLOCK_SIZE, (short) 3, 1L); banner("...
[ "@Test\n public void testBlocksAddedBeforeStandbyRestart() throws Exception {\n banner(\"Starting with NN0 active and NN1 standby, creating some blocks\");\n DFSTestUtil.createFile(fs, new Path(\"/test\"), 3*BLOCK_SIZE, (short) 3, 1L);\n // Roll edit log so that, when the SBN restarts, it will load\n /...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Test a literals toString method
@Test public void testToString() { Literal test6 =new Literal(-231,true); Literal test7 =new Literal(-5); Literal test8 =new Literal(-589,false); Literal test9 =new Literal(9184); assertEquals(test6.toString(),"231 true"); assertEquals(test7.toString(),"5 false"); assertEquals(test8.toString(),"5...
[ "public void testToString()\n\t{\n\t\t//TODO Implement toString().\n\t}", "@Test\n public void testToString() {\n System.out.println(\"toString\");\n String expResult = \"A\";\n String result = instance.toString();\n assertEquals(expResult, result);\n }", "@Test\n public voi...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Returns source attestations that have the same beacon head block as the one seen in state
private static List<PendingAttestation> get_matching_head_attestations( BeaconState state, UnsignedLong epoch) throws IllegalArgumentException { return get_matching_source_attestations(state, epoch).stream() .filter( a -> a.getData() .getBeacon_block_roo...
[ "default List<PendingAttestation> get_matching_head_attestations(BeaconState state, EpochNumber epoch) {\n return get_matching_source_attestations(state, epoch).stream()\n .filter(a -> a.getData().getBeaconBlockRoot().equals(\n get_block_root_at_slot(state, get_attestation_slot(state, a.getData...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Remove scheduled services. Only local services need to be unscheduled. Any clustered services are defined in the db and so will be cleared by the data import itself.
private void removeLocalServices() { for (JiraServiceContainer service : serviceManager.getServices()) { try { if (service.isLocalService()) { serviceManager.removeService(service.getId()); } } catch (Exception e) { log....
[ "void removeAllTasksForService(PerunSession sess, Service service);", "public static int rmScheduledEvent()\n\t{\n\t\tString sql = \"DELETE FROM BSM_SCHEDULER_EVENT_REPORT\";\n\t\tDBUtil.executeSQL(sql);\n\t\t\n\t\t//Remove report event from table BSM_SCHEDULER_EVENT\n\t\tsql = String.format(\"DELETE FROM BSM_SCH...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Routing of get request to get all buyer method
@GetMapping("buyers") public ResponseEntity<?> getAllBuyer() throws DatabaseConnectivityFailedException, Exception{ List<Buyer> allBuyer =buyerService.getAllBuyer(); responseEntity = new ResponseEntity<List<Buyer>>(buyerService.getAllBuyer(),HttpStatus.OK); return responseEnt...
[ "@GetMapping(\"buyers/{buyerName}\")\n public ResponseEntity<?> getBuyerByName(@PathVariable String buyerName) throws DatabaseConnectivityFailedException, BuyerNotFoundException, Exception{\n\n responseEntity = new ResponseEntity<List<Buyer>>(buyerService.getBuyerByName(buyerName),HttpStatus.OK);\...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
$ANTLR end "entryRuleNET_LVALUE" $ANTLR start "ruleNET_LVALUE" ../com.ironglass.hdlforge.ui/srcgen/com/ironglass/hdlforge/ui/contentassist/antlr/internal/InternalSystemVerilog.g:350:1: ruleNET_LVALUE : ( rulePS_OR_HIERARCHICAL_NET_IDENTIFIER ) ;
public final void ruleNET_LVALUE() throws RecognitionException { int stackSize = keepStackSize(); try { // ../com.ironglass.hdlforge.ui/src-gen/com/ironglass/hdlforge/ui/contentassist/antlr/internal/InternalSystemVerilog.g:354:2: ( ( rulePS_OR_HIERARCHICAL_NET_IDENTIFIER...
[ "public final void entryRuleNET_LVALUE() throws RecognitionException {\r\n try {\r\n // ../com.ironglass.hdlforge.ui/src-gen/com/ironglass/hdlforge/ui/contentassist/antlr/internal/InternalSystemVerilog.g:342:1: ( ruleNET_LVALUE EOF )\r\n // ../com.ironglass.hdlforge.ui/src-gen/com/irong...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
/ / A Read Only property representing the median of the data in the dataset. / Defined as data[n/2+1] for count is odd and (data[n/2]+data[n/2+1])/2 fo even count /
public double getMedian() { sortObservations(); if (m_sdata.length == 0) { return Double.NaN; } boolean even = (m_sdata.length % 2 == 0 ? true : false); if (even) { return ((m_sdata[m_sdata.length / 2 - 1] + m_sdata[m_sdata.length / 2]) / 2.0); ...
[ "double median() {\n\t\t\n\t\tint count = this.count();\n\t\tdouble mid;\n\t\tif (count % 2 == 0) {\n\t\t\tmid = (this.sortedArray[(count-2)/2]+this.sortedArray[(count-2)/2+1])/2;\n\t\t} else {\n\t\t\tmid = this.sortedArray[(count-1)/2];\n\t\t}\n\t\treturn mid;\n\t}", "private static double median(double[] m) {\n...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Decreases the karma of this post and the relevant karma of the user who created the post by one each.
public void downvote() { //TODO this.karma --; this.user.getKarma().downvote(this.getType());//both decrease by one }
[ "public void decreaseKarma(final int i) {\n final boolean flagChanged = karma > 0;\n karma -= i;\n if (karma <= 0) {\n karma = 0;\n updateKarma(flagChanged);\n } else {\n updateKarma(false);\n }\n }", "public Karma() \n\t{\n\t\tthis.linkKarma ...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
$ANTLR end "rule__ActionFacet__Group__1__Impl" $ANTLR start "rule__VarFacet__Group__0" InternalGaml.g:10563:1: rule__VarFacet__Group__0 : rule__VarFacet__Group__0__Impl rule__VarFacet__Group__1 ;
public final void rule__VarFacet__Group__0() throws RecognitionException { int rule__VarFacet__Group__0_StartIndex = input.index(); int stackSize = keepStackSize(); try { if ( state.backtracking>0 && alreadyParsedRule(input, 606) ) { return ; } // Internal...
[ "public final void ruleVarFacet() throws RecognitionException {\n int ruleVarFacet_StartIndex = input.index();\n\n \t\tint stackSize = keepStackSize();\n \n try {\n if ( state.backtracking>0 && alreadyParsedRule(input, 120) ) { return ; }\n // InternalGaml.g:173...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Determines whether this node has a sibling node that is an immediate value and both nodes belong to a sum expression.
boolean hasAddendSibling();
[ "boolean hasFirstOperandNodeId();", "protected boolean isRValue(Expression exprChild)\n {\n return true;\n }", "private static boolean checkSumTree(Node root) {\n\t\tif (root == null)\treturn true;\n\t\t// if it is a leaf node, then it is sum-tree.\n\t\tif (root.left == null && root.right =...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
CosEventComm/PushSupplier.java . Generated by the IDLtoJava compiler (portable), version "3.2" from CosEventComm.idl Wednesday, June 15, 2016 7:24:31 PM COT Interface for a push supplier.
public interface PushSupplier extends PushSupplierOperations, org.omg.CORBA.Object, org.omg.CORBA.portable.IDLEntity { }
[ "cn.chain33.javasdk.model.protobuf.BlockchainProtobuf.PushSubscribeReq getPush();", "public interface ProxyPushConsumer\n\textends ProxyPushConsumerOperations, org.omg.CORBA.Object, org.omg.CORBA.portable.IDLEntity, org.omg.CosEventComm.PushConsumer\n{\n}", "public interface StructuredPushConsumer extends Struc...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Sets the rejections in the response to the passed rejection list. This replaces any existing rejections in the response.
public void setRejections(List<IRejection> rejections);
[ "public void setReject(){\n repairRequest.reject();\n view.reject();\n }", "public final void setCommitment_Response_Escalations(java.util.List<slm_notifications.proxies.Response_Escalation> commitment_response_escalations)\r\n\t{\r\n\t\tsetCommitment_Response_Escalations(getContext(), commitment...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Gets the yearSelected attribute of the CalendarBean object
public int getYearSelected() { return yearSelected; }
[ "private int getSelectedYear() {\n return selectedYear;\n }", "private int getYear() {\r\n Calendar cal = monthView.getCalendar();\r\n return cal.get(Calendar.YEAR);\r\n }", "public Integer getDateyear() {\n return dateyear;\n }", "java.lang.String getYear();", "public S...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Creates the Google Copyright text that will be showed on the canvas lower right corner
public void createImgGoogleCopyright(Color googleCopyrightTextColor) { // googleCopyrightText = new BufferedImage(490, 15, BufferedImage.BITMASK); // Graphics2D g = (Graphics2D) googleCopyrightText.getGraphics(); // g.setPaint(new GradientPaint(10, 10, new Color(255, 255, 255, 0), 33, // 30, new Color(255, 255, 2...
[ "private TextView setupCopyright() {\n final TextView copyrightText = new TextView(getContext());\n copyrightText.setEnabled(false);\n copyrightText.setText(R.string.map_copyright_mml);\n copyrightText.setPadding(0, 0, 5, 0);\n copyrightText.setGravity(Gravity.BOTTOM | Gravity.CEN...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Compatibility Operator This method compares this entry value with another entry value to see if they are "compatible". They are compatible if equal, taking into account that they may be in different forms (uncalibrated versus calibrated). They may also have different operators, so in the case where I have this object b...
public final boolean isCompatibleWith( final XTCEContainerEntryValue that ) { // if these are exactly the same object on the Java heap then they must // be compatible if ( this == that ) { return true; } // next check if the parameter/argument represented is actual...
[ "public QualitativeValue getEqual() throws ClassCastException;", "public QualitativeValue getNonEqual() throws ClassCastException;", "default boolean compare(Operator op, ISqlObject other) {\n if (this instanceof ConstantSqlObject\n && other instanceof ConstantSqlObject\n &&...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }