text stringlengths 14 410k | label int32 0 9 |
|---|---|
private void notifyOfSort(boolean restoring) {
for (OutlineModelListener listener : getCurrentListeners()) {
listener.sorted(this, restoring);
}
} | 1 |
private void read(SocketChannelExtender socket) {
int result = socket.read(readBuffer);
if ((result & RES_CLOSE_SOCKET) != 0) {
closeSocketPair(socket);
readBuffer.clear();
return;
}
if ((result & RES_ALLOCATE_BUFFER) != 0) {
readBuffer = ... | 6 |
public synchronized void setBeanContext(BeanContext bc)
throws PropertyVetoException {
// Do nothing if the old and new values are equal
if ((this.beanContext == null) && (bc == null)) {
return;
}
if ((this.beanContext != null) && this.beanContext.equals(bc)) {
... | 7 |
private void scale(final float m, final float[] a, final int offa) {
int nthreads = ConcurrencyUtils.getNumberOfThreads();
if ((nthreads > 1) && (n > ConcurrencyUtils.getThreadsBeginN_1D_FFT_2Threads())) {
nthreads = 2;
final int k = n / nthreads;
Future<?>[] futures ... | 7 |
@Override
public void selectionChanged(TreeSelectionEvent e) {
JoeTree tree = e.getTree();
Document doc = tree.getDocument();
if (doc == Outliner.documents.getMostRecentDocumentTouched()) {
if (tree.getComponentFocus() == OutlineLayoutManager.ICON) {
setEnabled(true);
} else {
setEnabled(false);... | 2 |
private Invoice createInvoiceObjectFromResponse(HttpResponse response) throws IOException, JSONException {
BufferedReader rd = new BufferedReader(new InputStreamReader(response.getEntity().getContent()));
StringBuilder content = new StringBuilder();
String line;
while (null != (line = rd.readLine())) {
... | 2 |
public void playSoundtrack() {
if (this.soundtrack != null) {// sometimes is not loaded at the first
// time
this.soundtrack.play();
// if(this.soundtrack.isPlaying()){
// this.soundtrack.setLooping(true);
// }
// long id = this.soundtrack.play();
// this.soundtrack.setLooping(id, true);
}
} | 1 |
@Override
public <T> T unwrap(Class<T> arg0) throws SQLException {
return null;
} | 0 |
public void activate(final boolean activate)
{
active = activate;
if (active && getCache() == null)
setCache(new LFUCache(0, 0));
// supply a really simple "all you can buffer"-filter
if (active && nwFilter == null) {
nwFilter = new NetworkFilter()
{
public void accept(final CEMI frame, f... | 8 |
public InternetExplorerLauncher(BrowserConfigurationOptions browserOptions, RemoteControlConfiguration configuration, String sessionId, String browserLaunchLocation) {
String mode = browserOptions.get("mode");
if (mode == null) mode = DEFAULT_MODE;
if ("default".equals(mode)) mode = DEFAULT_MOD... | 9 |
private boolean checkValid(int x, int y) {
boolean[] row = new boolean[9];
boolean[] col = new boolean[9];
for (int i = 0; i < 9; i++) {
char rowChar = board[x][i];
char colChar = board[i][y];
if (rowChar != '.') {
if (row[rowChar - '1'])
return false;
else
row[rowChar - '1'] = true;
... | 9 |
public void wdgmsg(Widget sender, String msg, Object... args) {
if(busy){return;}
if(sender == content) {
String request = (String)args[0];
if((Integer)args[1] == 1) {
open(request);
} else {
new WikiPage(ui.wiki, request, true);
}
} else if(sender == cbtn) {
ui.destroy(this);
} else {
... | 4 |
public void test_01() {
// Run
String args[] = { "-classic", "-ud", "0", "testHg3766Chr1", "./tests/test.mnp.01.vcf" };
SnpEff cmd = new SnpEff(args);
SnpEffCmdEff snpeff = (SnpEffCmdEff) cmd.snpEffCmd();
List<VcfEntry> results = snpeff.run(true);
// Check
Assert.assertEquals(1, results.size());
VcfEnt... | 2 |
public static boolean hasSpace(){
for (Item item : inventory) {
if(item == null) return true;
}
return false;
} | 2 |
private void handleStartProcess(String[] cmdLine){
if(cmdLine.length < 3){
System.out.println("invalid argument, see help for more information");
return;
}
int workerId;
try{
workerId = Integer.valueOf(cmdLine[1]);
}catch(Exception... | 6 |
public void set(String name, Object value) {
try {
Scanner scan = new Scanner(this);
File temp = new File("temp");
PrintWriter pw = new PrintWriter("temp");
boolean used = false;
while(scan.hasNextLine()) {
String line = scan.nextLine()... | 5 |
public Compras() {
setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
setBounds(100, 100, 450, 366);
contentPane = new JPanel();
contentPane.setBorder(new EmptyBorder(5, 5, 5, 5));
setContentPane(contentPane);
contentPane.setLayout(null);
JButton btn_Cadastrar = new JButton("Cadastrar");
btn_Cadastrar.se... | 8 |
@Override
public boolean equals(Object obj) {
if (this == obj)
return true;
if (obj == null)
return false;
if (getClass() != obj.getClass())
return false;
IngredientList other = (IngredientList) obj;
if (ingredientList == null) {
if (other.ingredientList != null)
return false;
}
else if (... | 9 |
@Override
public void grantAbilities(MOB mob, boolean isBorrowedRace)
{
final PairList<Ability,AbilityMapping> onesToAdd=new PairVector<Ability,AbilityMapping>();
for(final Enumeration<Ability> a=CMClass.abilities();a.hasMoreElements();)
{
final Ability A=a.nextElement();
final AbilityMapping mapping = CM... | 9 |
public tracuuphong(int khu, String phong, String loai, String quanly,DefaultTableModel tb) {
if(khu==0)khui="b5";
if(khu==1)khui="b6";
if(khu==3)khui="b7";
String maphong;
maphong= khui+"-"+phong;
if (phong.length() == 0) {
JOptionPane.showMessageDialog(null, "Ba... | 9 |
public void keyPressed(KeyEvent e) {
int key = e.getKeyCode();
if (key == KeyEvent.VK_LEFT) {
battlefield.getMuzzle().setAngle(battlefield.getMuzzle().getAngle() - battlefield.getMuzzle().getSpeed());
}
else if (key == KeyEvent.VK_RIGHT) {
battlefield.getMuzzle().setAngle(battlefield.getMuzzle().getAngle(... | 6 |
public void open ()
{
//Check for saving the current file
if (checkSaved ()){
final Lawgbook l = display.getLawgbook ();
File file;
//This crashed a few times with a nullpointerException
fileChooser.showOpenDialog(this); //I need to access a component for this to work. May have to move... | 9 |
protected void processRequest(HttpServletRequest request, HttpServletResponse response)
throws ServletException, IOException {
//On verifie le parametre email existe
String email = request.getParameter("email");
if (email ==null){
request.setAttribute("message", "Le emai... | 9 |
public void setClassName(String className) {
this.className = className;
} | 0 |
private void initArrays() {
if (data == null || picsize != data.length) {
data = new int[picsize];
magnitude = new int[picsize];
xConv = new float[picsize];
yConv = new float[picsize];
xGradient = new float[picsize];
yGradient = new float[... | 2 |
private void leftCtrlClickAction(int x, int y)
{
if (!isEditable())
{
leftShiftClickAction(x, y);
return;
}
if (isTile(x, y))
{
if (selection[x][y] == -1 && selt != 1)
{
selection[x][y] = getArrangementData(x, y)... | 6 |
public String getBilan() {
return bilan;
} | 0 |
public void addSupportedFeatures(String supportsString) {
String[] stringFeatureReps = supportsString.replace("$Supports ","").split("\\s+");
for (String stringFeature : stringFeatureReps) {
try {
stringFeature = stringFeature.replace("\\|", "");
SupportsFeatu... | 2 |
public void actionPerformed(ActionEvent event) {
// JFrame frame = Universe.frameForEnvironment(environment);
try {
getExpression().asCheckedString();
} catch (UnsupportedOperationException e) {
JOptionPane.showMessageDialog(getEnvironment(), e.getMessage(),
"Illegal Expression", JOptionPane.ERROR_MESS... | 1 |
public Deplacement PrecedentDeplacement(int i) {
Deplacement deplacementPrecedent = null;
Tour touractuelle = null;
int j =0;
for (Tour tour : historiqueToursJoueur) {
touractuelle = tour;
for (Deplacement deplacement : tour.getListDeplacement()) {
j++;
if(j == (i))
{
deplacementPreced... | 7 |
public static void testParametreReservation (String nomS, String dateS, String numS) throws BDException {
String requete = "select * from lesspectacles, lesrepresentations where lesspectacles.numS=lesrepresentations.numS and lesspectacles.numS="+numS+" and dateRep = to_date('"+dateS+"','dd/mm/yyyy hh24:mi') and nomS=... | 2 |
public void testForFields_time_HMm() {
DateTimeFieldType[] fields = new DateTimeFieldType[] {
DateTimeFieldType.hourOfDay(),
DateTimeFieldType.minuteOfHour(),
DateTimeFieldType.millisOfSecond(),
};
int[] values = new int[] {10, 20, 40};
Lis... | 2 |
@Override
public boolean isWebDriverType(String type)
{
return StringUtils.equalsIgnoreCase("phantomjs", type);
} | 0 |
public K findKey (Object value, boolean identity) {
V[] valueTable = this.valueTable;
if (value == null) {
K[] keyTable = this.keyTable;
for (int i = capacity + stashSize; i-- > 0;)
if (keyTable[i] != null && valueTable[i] == null) return keyTable[i];
} else if (identity) {
for (int i = capacity + st... | 9 |
private void copyPixels(int destOff, int width, int height, int srcStep, int srcOff, int destStep, int src[], int dest[]) {
int quarterX = -(width >> 2);
width = -(width & 3);
for (int i = -height; i < 0; i++) {
for (int j = quarterX; j < 0; j++) {
dest[destOff++] = src[srcOff++];
dest[destOff++] = src... | 3 |
public String getAddress2() {
return address2;
} | 0 |
private void revealNeighbouringCards(Rectangle removedCardArea,
int rowOfRemovedCard) {
int previousRow = rowOfRemovedCard - 1;
int nextRow = rowOfRemovedCard + 1;
/*
* Stage 7 (20 Marks)
*/
int checkRow;
switch (rowOfRemovedCard) {
case 1:
checkRowOfNeighbours(removedCardArea, checkRow = 0,
... | 3 |
public Long getId() {
return id;
} | 0 |
public static DoHouseWork getSingleton(){
// needed because once there is singleton available no need to acquire
// monitor again & again as it is costly
if(singleton==null) {
synchronized(DoHouseWork.class){
// this is needed if two threads are waiting at the monitor at the
... | 2 |
public static void main(String[] args) throws IOException {
if (args.length == 1) {
Webserver web = new Webserver(args[0]);
web.run();
}
else
System.err.println(
"Usage: java javassist.tools.web.Webserver <port number>");
} | 1 |
private void initGUI() {
setFocusable(true);
this.setBorder(null);
MouseAdapter mouseListener = new MouseAdapter() {
@Override
public void mouseEntered(java.awt.event.MouseEvent evt) {
mouseIsOverButton = true;
setBackground();
}
@Overr... | 8 |
@Override
public void onPluginMessageReceived(String channel, Player player, byte[] message) {
if(!channel.equals(MESSAGING_CHANNEL)) return;
DataInputStream in = new DataInputStream(new ByteArrayInputStream(message));
try {
String subchannel = in.readUTF();
if(subchannel.equals("Forward")) {
... | 5 |
public static void set(String key, Serializable value)
{
synchronized (data)
{
Serializable old = data.put(key, value);
if (((old == null) && (value != null)) || ((old != null) && (!old.equals(value))))
modified = true;
}
} | 4 |
public GetQuestionsFromMySqlDatabase(String hostname, String databaseName, String username, String password)
{
this.hostname = hostname;
this.databaseName = databaseName;
this.username = username;
this.password = password;
} | 0 |
void Stand_Up(float dt) {
int i;
int onfloor = 0;
float scale = 2.0f;
// touch the feet to the floor
for(i=0;i<6;++i) {
if(legs[i].ankle_joint.pos.z>0) legs[i].ankle_joint.pos.z-=4*scale*dt;
else ++onfloor;
// contract - put feet closer to shoulders
Vector3f df = new Vector3f(legs[i... | 6 |
@Override
public void run() {
List<UIEvent> lastEvents = Model.getModel().getInteractionStack().getLastEvents(2);
if (lastEvents.get(0).getEventType() != EventType.MOUSE_BUTTON_UP
|| lastEvents.get(0).getButton() != 1
|| lastEvents.get(1).getEventType() != EventType.MOUSE_BUTTON_DOWN
|| Model.getModel(... | 9 |
public static void main(String[] args) {
int matriceA[][] = {{1, 1, 1, 1, 1},
{2, 2, 2, 2, 2},
{3, 3, 3, 3, 3},
{4, 4, 4, 4, 4},
{5, 5, 5, 5, 5}};
int matriceB[][] = new int[matriceA.length][m... | 5 |
public void _jspService(HttpServletRequest request, HttpServletResponse response)
throws java.io.IOException, ServletException {
PageContext pageContext = null;
HttpSession session = null;
ServletContext application = null;
ServletConfig config = null;
JspWriter out = null;
Object page ... | 6 |
@Test
public void runTestApplicationLifecycle1() throws IOException {
InfoflowResults res = analyzeAPKFile("Lifecycle_ApplicationLifecycle1.apk");
Assert.assertEquals(1, res.size());
} | 0 |
public static Proposition normalizeValueFunction(Proposition self) {
{ Surrogate functionsurrogate = Logic.evaluateRelationTerm((self.arguments.theArray)[0], self);
int newargumentcount = self.arguments.length() - 1;
Proposition newproposition = null;
Proposition duplicate = null;
if (funct... | 6 |
public void setAdapt(boolean newAdapt)
{
adapt = newAdapt;
transformNeedsReform = true;
repaint();
} | 0 |
public static void Edit(){
FileReader pl=null;
String what;
String sCurrentLine="";
Scanner scan = new Scanner(System.in);
what = scan.nextLine();
System.out.println("Input file:\n");
try{
//pl = new FileReader(f);
pl = new FileReader("src/data");
} catch (FileNotFoundException e) {
System.... | 5 |
private ResGridlet cancelReservationGridlet(int reservationID)
{
ResGridlet rgl = null;
// Find in EXEC List first
int found = findGridlet(gridletInExecList_, reservationID);
if (found >= 0)
{
// update the gridlets in execution list up to this point in time
... | 5 |
public void setIpServer(String ip){
this.ipServer = ip;
} | 0 |
public void saveHitbox() {
BufferedReader reader;
try {
reader = new BufferedReader(new FileReader(System.getProperty("resources") + "/database/entities"));
String line;
StringBuilder fileContent = new StringBuilder();
String newLine = null;
while((line = reader.readLine()) != null) {
String[] t... | 5 |
public boolean opEquals(Operator o) {
return (o instanceof LocalLoadOperator && ((LocalLoadOperator) o).local
.getSlot() == local.getSlot());
} | 1 |
public String operatorsToString(){
String str = new String();
for(Operator operand: operatorStack){
str = str + (operand.toString() + " ");
}
return str;
} | 1 |
public boolean isPrimitive() {
if (clazz.isPrimitive()) {
return true;
}
return is(Boolean.class) || is(Character.class) || is(Byte.class)
|| is(Short.class) || is(Integer.class) || is(Long.class)
|| is(Float.class) || is(Double.class) || is(Void.class);
} | 9 |
private void sendFile(){
try {
FileReader fr = new FileReader(file);
long numBytes = file.length();
char[] cbuf;
byte[] buffer = new byte[PACKET_LENGTH];
System.arraycopy(ByteBuffer.allocate(4).putInt((int)numBytes/PACKET_LENGTH+2).array(), 0, buffer, 1, 4);
buffer[0]=2;
sendPacket(buffer);
se... | 5 |
public void removeBit() {
if (length == 0) {
throw new IllegalStateException("no bits to remove");
}
// Shift the bits one place to the right, losing the rightmost bit.
bits = bits >> 1;
length--;
} | 1 |
public Component getListCellRendererComponent(JList list, Object value, int index, boolean isSelected, boolean cellHasFocus) {
java.lang.String itemText = value != null ? value.toString() : "";
if( this.isViewerMode ) {
// Item for current contents preview tool
columnText.se... | 9 |
public static final int StateInit()
{
return 0;
} | 0 |
private void Traversal(TreeNode root,ArrayList<Integer> list) {
if(root != null){
Traversal(root.left,list);
Traversal(root.right,list);
list.add(root.val);
}
} | 1 |
public LevelImporter() {
addWindowListener(new WindowAdapter() {
@Override
public void windowClosed(WindowEvent e) {
Game.get().display.getFrame().setVisible(true);
}
});
setResizable(false);
setTitle("Image to Maze");
setDefaultCloseOperation(JFrame.DISPOSE_ON_CLOSE);
setBounds(100, 100,... | 7 |
private static void shuffle(Agent[] agents) {
for (int i = 0; i < agents.length - 1; i++) {
int j = prng.nextInt(agents.length - i) + i;
Agent tmp = agents[j];
agents[j] = agents[i];
agents[i] = tmp;
}
} | 1 |
public int readInt(String pSection, String pKey, int pDefault)
{
//if the ini file was never loaded from memory, return the default
if (buffer == null) {return pDefault;}
Parameters params = new Parameters();
//get the value associated with pSection and PKey
String valueText = getValue(pSection, ... | 3 |
private final boolean method730(AbstractToolkit var_ha, Class72 class72_0_) {
if (aClass105_1221 == null) {
if (anInt1230 == 0) {
if (Class101_Sub1.aD5684.method4(-7953, anInt1224)) {
int[] is = Class101_Sub1.aD5684.method6(-21540, anInt1220,
0.7F, anInt1224,
false, anInt1220);
... | 6 |
public static void main(String args[]) {
/* Set the Nimbus look and feel */
//<editor-fold defaultstate="collapsed" desc=" Look and feel setting code (optional) ">
/* If Nimbus (introduced in Java SE 6) is not available, stay with the default look and feel.
* For details see http://down... | 6 |
public int edmons_karp(int s, int t) {
int u, e;
mf = 0;
this.s = s;
Arrays.fill(p, -1);
while (true) {
f = 0;
Queue<Integer> q = new LinkedList<Integer>();
int[] dist = new int[V];
Arrays.fill(dist, INF);
dist[s] = 0;
q.offer(s);
Arrays.fill(p, -1);
while (!q.isEmpty())... | 7 |
private boolean interruptCalibration() {
duration += nanoTime() - startTime;
getEventHandler().handleEvent(new CalibrationMessage(epoch, sse, TimeUnit.MILLISECONDS.convert(duration, TimeUnit.NANOSECONDS)));
if (isWalking()) {
try {
sleep(5l);
startTime... | 4 |
public void loadLower30DegreeSlope(Rectangle2D e) {
for(int x = 0; x < TileSet.tileWidth / 2; x++) {
platforms.add(new Platform(new Rectangle2D.Double(e.getX() + (2f * x), e.getCenterY() + x, 2f, 2f)));
//System.out.println("Lower " + platforms.get(platforms.size() - 1).getBox().getY());
}
} | 1 |
@Override
public void signalEndOfData() {
// Do nothing
} | 0 |
private String decoderSerie(int u) {
long D=((u%this.M)*(Outils.inverseModulo(this.W, this.M))%this.M)%this.M;
String s=this.resoudreSacADosSuper(D,TAILLE_ENCODAGE-1);
char[] c=s.toCharArray();
char temp=c[this.sigma1];
c[this.sigma1]=c[this.sigma2];
c[this.sigma2]=temp;
String envers="";
for(int i=0;i<... | 4 |
public static void main(String args[]) {
/* Set the Nimbus look and feel */
//<editor-fold defaultstate="collapsed" desc=" Look and feel setting code (optional) ">
/* If Nimbus (introduced in Java SE 6) is not available, stay with the default look and feel.
* For details see http://down... | 6 |
public DirectionalBorderDetectorDialog(final Panel panel, final String title) {
setTitle(title);
this.panel = panel;
setBounds(1, 1, 450, 250);
Dimension size = getToolkit().getScreenSize();
setLocation(size.width / 3 - getWidth() / 3, size.height / 3
- getHeight() / 3);
this.setResizable(false);
setL... | 8 |
private void buildHeap( Collection<? extends E> c ) {
// move the elements of c into a complete binary tree
// rooted at top
heap = ( E[] ) c.toArray();
size = c.size();
// let cursor be the rightmost interior node
int cursor = ( size / 2 ) - 1;
// invariant: the children of cursor are val... | 2 |
@Override
public void reset() {
fp = null;
if (input.isConnected()) {
if (input.getSource() != null
&& input.getSource().getParent() != null) {
this.setName("plot of "
+ input.getSource().getParent().getName() + "."
+ input.getSource().getName());
hist = new Hist(input.getSource().getPa... | 3 |
public void updateStateBasedOnVelocity() {
if(vx > 0) {
setState(RIGHT);
}
else {
setState(LEFT);
}
} | 1 |
private boolean r_Step_4() {
int among_var;
int v_1;
// (, line 129
// [, line 130
ket = cursor;
// substring, line 130
among_var = find_among_b(a_6, 18);
if (among_var == 0)
{
return false;
... | 9 |
public static void main(String [] args) throws IOException {
// String start = "hit";
// String end = "cog";
// String [] dict = new String[]{"hot","dot","dog","lot","log"};
// HashSet<String> ds = new HashSet<String>(Arrays.asList(dict));
//
// long s1 = System.currentTimeMillis();
/... | 1 |
@Override
public boolean supportsDocumentAttributes() {return false;} | 0 |
private ArrayList<Bar> createBars(){
//arrange data lowest to highest
Arrays.sort(data);
int intervalSize = 0;
if(numOfBars > 0) {
intervalSize = (getMaxNumber(data) / numOfBars);
}
int lowerLimit = 0;
int upperLimit = lowerLimit + intervalSize;
int count;
ArrayList<Bar> bars = new ArrayList<Bar... | 5 |
private int firstEvenIndexOf(Object elem) {
if (elem == null) {
for (int i = 0; i < size(); i = i + 2) {
if (get(i) == null) {
return i;
}
}
} else {
for (int i = 0; i < size(); i = i + 2) {
if (elem.equals(get(i))) {
return i;
}
}
... | 5 |
public void setRadius(double radius) {
_radius = radius;
} | 0 |
public void ReadFile(Message inputMessage, int opID) {
if(AddSharedParentLocks(inputMessage.filePath, opID))
{
//Implement Later
int indexCounter = 1;
System.out.println("Master: trying to read "+inputMessage.filePath + indexCounter);
if (!chunkServerMap.containsKey(inputMessage.filePath + indexCounter)... | 9 |
@Override
public void run() {
try {
server = new ServerSocket(7000);
} catch (IOException e1) {
e1.printStackTrace();
}
try {
System.out.println(new Date() + " --> Server waits for client...");
socket = server.accept(); // blocking
System.out.println(new Date() + " --> Cl... | 8 |
private Class<?> ensureReplacedClass(Scriptable scope, Object obj,
Class<?> staticType) {
final Class<?> type = (staticType == null && obj != null) ? obj
.getClass() : staticType;
if (!type.isPrimitive() && !type.getName().startsWith("java.")
&& this.replacedClasses.add(type)) {
this.replaceJav... | 8 |
public int[] getPixels() {
return pixels;
} | 0 |
@Override
public void execute(CommandSender sender, String[] arg1) {
if (!CommandUtil.hasPermission(sender, PERMISSION_NODES)) {
sender.sendMessage(plugin.NO_PERMISSION);
return;
}
try {
if(plugin.getUtilities().chatChannelExists(arg1[0])){
sender.sendMessage(plugin.CHANNEL_ALREADY_EXISTS);
retu... | 9 |
public boolean save(ArrayList aguardar){
return false;
} | 0 |
@After
public void tearDown()
throws Exception
{
this.scheduler.shutdown();
} | 0 |
public static void update() {
for(Keybinds keybinds : Keybinds.values()) {
keybinds.key.setHeld(keybinds.key.isPressed());
keybinds.key.update();
}
} | 1 |
public static int longestIncreasingSeq(ArrayList<Person> circus) {
Collections.sort(circus);
Hashtable<Person, Integer> hashtable = new Hashtable<Person, Integer>();
for (int i = 0; i < circus.size(); ++i) {
Person curr = circus.get(i);
if (!hashtable.containsKey(curr)) {
hashtable.put(curr, 1);
}
... | 7 |
@Override
public Object getValueAt(int rowIndex, int columnIndex) {
DetallePedido detalle = detalles.get(rowIndex);
switch(columnIndex){
case 0 : return detalle.getIdArticulo();
case 1 : {
try {
return ArticuloController.buscarArticulos(det... | 6 |
private void closeChannel(){
try {
if(this.fileInput != null){
this.fileInput.close();
this.fileInput = null;
}
if(this.fileChannel != null){
this.fileChannel.close();
this.fileChannel = null;
}
}catch (IOException ex) {
ex.printStackTrace();
... | 3 |
public boolean isOpen(String direction) {
switch (direction) {
case "north":
if (this.north[1].equals("True")) {
return true;
} else {
return false;
}
case "east":
if (this.east[1].equ... | 8 |
@Override
public void startSetup(Attributes atts) {
super.startSetup(atts);
setEnabled(false);
addActionListener(this);
Outliner.documents.addTreeSelectionListener(this);
Outliner.documents.addDocumentRepositoryListener(this);
} | 0 |
public void setEstrCaso(List<?> list)
{
for(PEstrCaso e : this._estrCaso_)
{
e.parent(null);
}
this._estrCaso_.clear();
for(Object obj_e : list)
{
PEstrCaso e = (PEstrCaso) obj_e;
if(e.parent() != null)
{
... | 4 |
* @param renamed_New
* @param old
* @return String
*/
public static String replaceSubstrings(String string, String renamed_New, String old) {
{ int stringlength = string.length();
int oldlength = old.length();
int newlength = renamed_New.length();
int nofoccurrences = 0;
int oldst... | 6 |
static CtClass toPrimitiveClass(char c) {
CtClass type = null;
switch (c) {
case 'Z' :
type = CtClass.booleanType;
break;
case 'C' :
type = CtClass.charType;
break;
case 'B' :
type = CtClass.byteType;
break;
... | 9 |
Subsets and Splits
SQL Console for giganticode/java-cmpx-v1
The query retrieves a limited number of text entries within a specific length range, providing basic filtering but minimal analytical insight.