Examples of Item


Examples of client.net.sf.saxon.ce.om.Item

        e.setXPathContext(context);
        e.setLocator(getSourceLocator());
        if (argument.length > 2) {
            Value errorObject = ((Value)SequenceExtent.makeSequenceExtent(argument[2].iterate(context))).reduce();
            if (errorObject instanceof SingletonItem) {
                Item root = ((SingletonItem)errorObject).getItem();
                if ((root instanceof NodeInfo) && ((NodeInfo)root).getNodeKind() == Type.DOCUMENT) {
//                    XPathEvaluator xpath = new XPathEvaluator();
//                    XPathExpression exp = xpath.createExpression("/error/@module");
//                    NodeInfo moduleAtt = (NodeInfo)exp.evaluateSingle((NodeInfo)root);
//                    String module = (moduleAtt == null ? null : moduleAtt.getStringValue());
View Full Code Here

Examples of client.ws.milanas.helpers.beans.Item

     * Sends a SOAP request message to Amazon
     */
    private Item sendSOAPMessage(String operation, String cathegory, HashMap<String, String> parameters) throws SOAPEnvelopeCreationException, SOAPConnectionException
    {
        int numPages, i = 0;
        Item item = new Item();
        Document doc = null;
        DOMItemHandler dih = null;
        SOAPMessage response = null;
        SOAPMessage message = SOAPEnvelopeCreator.createAmazonSearchSOAPEnvelope(operation, parameters, properties);
        try
View Full Code Here

Examples of cloudsync.model.Item

  public void prepareParent(Handler handler, Item item) throws CloudsyncException {

    if (item.getParent() != null) {

      Item parentItem = item.getParent();

      final Path parentPath = Paths.get(localPath + Item.SEPARATOR + parentItem.getPath());

      try {
        Files.createDirectories(parentPath);
      } catch (IOException e) {
        throw new CloudsyncException("Can't create " + parentItem.getTypeName() + " '" + parentItem.getPath() + "'", e);
      }
    }
  }
View Full Code Here

Examples of co.arcs.groove.basking.task.BuildSyncPlanTask.SyncPlan.Item

        Builder<Item> syncPlanItems = ImmutableList.builder();

        for (Integer id : wantedSongs.keySet()) {
            if (existingSongs.containsKey(id)) {
                // Wanted song already exists, so leave as is
                syncPlanItems.add(new Item(existingSongs.get(id),
                        Action.LEAVE,
                        wantedSongs.get(id)));
                existingSongs.remove(id);
            } else {
                // Wanted song is absent, so download
                syncPlanItems.add(new Item(new File(syncDir,
                        Utils.getDiskName(wantedSongs.get(id))),
                        Action.DOWNLOAD,
                        wantedSongs.get(id)
                ));
            }
        }

        // Remaining songs are present but unwanted, so delete
        for (Integer id : existingSongs.keySet()) {
            syncPlanItems.add(new Item(existingSongs.get(id), Action.DELETE, null));
        }
        return new SyncPlan(syncPlanItems.build());
    }
View Full Code Here

Examples of com.aldaviva.autorpg.data.entities.Item

        break;
       
      case RARE_ITEM:
        bulletin = new Bulletin(new Message.CharactersFoundItems(quest.getCharacters()));
        for(Character character : quest.getCharacters()){
          Item newItem = Item.findRandomByRarity(true);
          characterItemManager.offerCharacterAnItem(newItem, character);
          bulletin.add(new Message.CharacterFoundItem(character, newItem));
        }
        break;
       
View Full Code Here

Examples of com.amazonaws.services.dynamodbv2.document.Item

*/
public class B_PutItemTest extends AbstractQuickStart {
    @Test
    public void howToPutItems() {
        Table table = dynamo.getTable(TABLE_NAME);
        Item item = newItem();
        int intAttrVal = item.getInt("intAttr");
        // Creates 10 items of range key values from 1 to 10
        for (int i=1; i <= 10; i++) {
            PutItemOutcome result = table.putItem(
                item.withInt(RANGE_KEY_NAME, i)
                .withInt("intAttr", intAttrVal+i)
            );
            System.out.println(result);
        }
    }
View Full Code Here

Examples of com.amazonaws.services.simpledb.model.Item

      if(clazz == null){
        clazz = obj.getClass();
        info = ClassInfo.getClassInfo(clazz);       
      }
      String itemName = getItemName(clazz, obj);
      Item theItem = null;
      for(Item item:items){
        if(item.getName().equals(itemName)){
          theItem = item;
          items.remove(item);
          break;
View Full Code Here

Examples of com.andrew.Item

public class TestItem {
 
  @Test
  public void testThatItemInstantiationCorrectlyCalculatesVatForTheItem(){
    Item item = new Item("1", "Bag of ice", "100");
   
    BigDecimal expectedUnitPrice = new BigDecimal("100");
    BigDecimal expectedVat = new BigDecimal("14.00");
    BigDecimal expectedUnitPricePlusVat = new BigDecimal("114.00");
   
    assertEquals("1", item.getProductId());     
    assertEquals("Bag of ice", item.getDescription());     
    assertEquals(expectedUnitPrice, item.getUnitPrice());     
    assertEquals(expectedVat, item.getVat());     
    assertEquals(expectedUnitPricePlusVat, item.getUnitPricePlusVat())
    assertEquals(1, item.getCount());
    item.incrementCount();
    assertEquals(2, item.getCount());
   
  }
View Full Code Here

Examples of com.ap.givemetheprice.bean.item.Item

public class ItemFactoryTest {
 
  @Test
  public void createNotTaxedAndNotImportedItem() {
    Item book = ItemFactory.getItem(ItemType.BOOKS, "Vite da un giorno", 1, false, new BigDecimal("12.49"));
    Assert.assertTrue(book instanceof NotTaxedItem);
    Assert.assertEquals(ItemType.BOOKS, book.getType());
    Assert.assertEquals("Vite da un giorno", book.getName());
    Assert.assertEquals(1, book.getQuantity());
    Assert.assertEquals(false, book.isImported());
    Assert.assertEquals(new BigDecimal("12.49"), book.getPrice());
    Assert.assertEquals(new BigDecimal("0"), book.getSalesTaxes());
    Assert.assertEquals(Utils.applyRound(new BigDecimal("12.49")), book.getTotalPrice());
    book = null;
  }
View Full Code Here

Examples of com.aqpproject.worldmodel.data.Item

                    boolean isPoweredDown = car_list.get(i - 1).getPowerDown();
                    boolean isBoosted = car_list.get(i - 1).getBoost();
                    boolean isColliding = car_list.get(i - 1).getColliding();
                    boolean isStatic = car_list.get(i - 1).getIsStaticContact();
                    Vector2D point = car_list.get(i - 1).getContactPoint();
                    Item it = car_list.get(i - 1).getInventory().peek();
                    String type;
                    Integer num_item;

                    if (it == null) {
                        type = "null";
                        num_item = 0;
                    } else {
                        type = it.getType().toString();
                        switch (type) {
                            case "BOMB":
                                type = "Bomb";
                                break;
                            case "MISSILE":
                                type = "Missile";
                                break;
                            case "MINE":
                                type = "Mine";
                                break;
                            case "POWERDOWN":
                                type = "PowerDown";
                                break;
                            case "BOOST":
                                type = "Boost";
                                break;
                            case "TROLL":
                                type = "Troll";
                                break;
                        }
                        num_item = Integer.parseInt(it.getName().substring(4));

                    }
                    theOutput += ";" + name + ";" + posX + ";" + posY + ";" + rot + ";" + velX + ";" + velY + ";" + isPoweredDown + ";" + isBoosted + ";" + isColliding + ";" + point.x + ";" + point.y + ";" + isStatic + ";" + type + ";" + num_item;
                }
                WECar troll_emitter = ((RaceGameState) Singleton.getWorldModel().getState()).getTrollEmitter();
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.