Examples of Item


Examples of cs412.hw3.item.Item

    StringTokenizer t = new StringTokenizer(line);
    List<Item> items = new ArrayList<Item>();
   
    while(t.countTokens() > 1){
      String item = t.nextToken();
      items.add(new Item(item));
    }
   
    // record the max value found for svm preperation
    Item i = Collections.max(items, new Comparator<Item>() {
   
      public int compare(Item o1, Item o2) {
        return Integer.valueOf(o1.getItemName()).compareTo(Integer.valueOf(o2.getItemName()));
      }
   
    });
    int largest = Integer.valueOf(i.getItemName()).intValue();
    if(Double.isNaN(largestItemFoundInit) ||  largest > largestItemFound){
      largestItemFound = largest;
    }
    String classLabel = t.nextToken();
    Transaction tran = new Transaction(TID++,classLabel,items);
View Full Code Here

Examples of cz.cuni.mff.abacs.burglar.logics.objects.items.Item

  }
 
 
  @Override
  public boolean pickUp(Inventory inventory, Item item) {
    Item result = inventory.removeItem(item.getId());
    if(result != null)
      this.addItem(item);
    this.examine((Position)inventory);
   
    this._knowledge.forgetItemPosition(item);
View Full Code Here

Examples of de.mh4j.examples.maxknapsack.model.Item

public class SimulatedAnnealingKnapsackSolverTest {

  @Test
  public void testSolveSimpleInstance() {
    int knapsackCapacity = 59;
    List<Item> items = new ArrayList<>(Arrays.asList(new Item("Foo", 100,
        40), new Item("Bar", 80, 30), new Item("Muh", 5, 5), new Item(
        "Awe", 30, 10)));

    SimulatedAnnealingKnapsackSolver solver = new SimulatedAnnealingKnapsackSolver(
        knapsackCapacity, items);
    solver.run();
View Full Code Here

Examples of de.nava.informa.impl.basic.Item

  public void testObserve() {
    ChannelIF channel = new Channel("Niko's log");
    SimpleChannelObserver observer = new SimpleChannelObserver();
    ((ChannelObservableIF) channel).addObserver(observer);
    assertEquals(0, channel.getItems().size());
    ItemIF item = new Item("Bongo", "Rongoo", null);
    channel.addItem(item);
    assertEquals(1, channel.getItems().size());
    assertTrue(channel.getItems().contains(item));
    assertEquals(item, observer.getMyAddedItem());
   
View Full Code Here

Examples of de.nava.informa.impl.hibernate.Item

   * @throws PersistenceManagerException in case of any problems.
   */
  public ItemIF createItem(ChannelIF channel, String title)
    throws PersistenceManagerException {

    final ItemIF item = new Item(channel, title, null, null);

    saveCreatedItem(channel, item);

    return item;
  }
View Full Code Here

Examples of digi.recipeManager.data.Item

   *            item is ingredient (true) or result (false) ?
   * @return list of recipes
   */
  public List<Recipe> getRecipesForItem(ItemStack item, boolean ingredient)
  {
    return getRecipesForItem(new Item(item), ingredient);
  }
View Full Code Here

Examples of edu.uga.galileo.voci.bo.Item

      bundle.setActive(active);
      vbo = bundle;
    }
    if (type == ContentType.ITEM)
    {
      Item item = new Item();
      item.setItemId(-1);
      item.setProjectId(projectId);
      item.setActive(active);
      vbo = item;
    }

    return vbo;
  }
View Full Code Here

Examples of edu.umd.cs.findbugs.OpcodeStack.Item

            }

            String name = getNameConstantOperand();
            String sig = getSigConstantOperand();
            if ((name.startsWith("set") || name.startsWith("update")) || sig.endsWith(")V")) {
                Item invokedOn = stack.getItemMethodInvokedOn(this);
                if (invokedOn.isInitialParameter() && invokedOn.getRegisterNumber() == 0) {
                    updates++;
                }
                if (inferredMethod != null) {
                    inferredMethod.addCalledMethod(this);
                }
View Full Code Here

Examples of es.ipsa.atril.doc.user.Item

  }

  public void insertContentFromFile(AtrilSession oSes, File oFile)
    throws ElementNotFoundException, IOException {
    String sItemName = Gadgets.removeChars(oFile.getName(), "\"\\/?*:|<>;&");
    Item item = getDocument().item();
    item.setName(sItemName);
    item.insertContentFrom(oFile);
    Log.out.debug(getClass().getName()+".insertContentFromFile("+oFile.getName()+")");
    DAO.log(oSes, getDocument(), getClass(), "INSERT ITEM", AtrilEvent.Level.INFO, sItemName);
  }
View Full Code Here

Examples of etch.compiler.ast.Item

        "Authorize method %s arg %d name not a parameter field or enum (%s) at line %d",
        method.image, argNo+1, arg, lineno() ) );
   
    Enumx e = (Enumx) named;
   
    Item i = e.getItem( path.nextToken() );
    if (i == null)
      throw new ParseException( String.format(
        "Authorize method %s arg %d name not an enum item (%s) at line %d",
        method.image, argNo+1, arg, lineno() ) );
   
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.