Examples of Location


Examples of org.eclipse.osgi.service.datalocation.Location

  private boolean canUpdate() {
    final AtomicBoolean canUpdate = new AtomicBoolean(true);

    SafeRunnable.run(new LoggingSafeRunnable() {
      public void run() throws Exception {
        Location installLocation = Platform.getInstallLocation();
        if (installLocation != null && installLocation.getURL() != null) {
          File installDirectory = toFile(installLocation.getURL());
          if (!installDirectory.isFile()) {
            File pluginsDir = new File(installDirectory, PLUGINS);
            File featuresDir = new File(installDirectory, FEATURES);
            if (pluginsDir.isDirectory() && featuresDir.isDirectory()) {
              try {
View Full Code Here

Examples of org.eclipse.sapphire.samples.map.Location

           
            for( String locationName : locations )
            {
                if( ! map.hasLocation( locationName ) )
                {
                    final Location location = map.getLocations().insert();
                    location.setName( locationName );
                   
                    final DiagramNodePart locationNodePart = diagram.getDiagramNodePart(location);
                    locationNodePart.setNodeBounds( x, y );
                   
                    x += 50;
View Full Code Here

Examples of org.exolab.castor.xml.location.Location

        sb.append("ValidationException: ");
        String message = vx.getMessage();
        if (message != null) {
            sb.append(message);
        }
        Location location = vx.getLocation();
        if (location != null) {
            sb.append(";\n   - location of error: ");
            sb.append(location.toString());
        }
        Throwable t = vx.getCause();
        if (t != null) {
            sb.append("\n");
            sb.append(t.getMessage());
View Full Code Here

Examples of org.flywaydb.core.internal.util.Location

    public static void configure(Flyway flyway, Properties properties) throws SQLException {
        flyway.setCallbacks(new RepeatableCallback(flyway, properties));
        List<MigrationResolver> migrationResolvers = new ArrayList<>();
        for (String locationDescriptor : flyway.getLocations()) {
            migrationResolvers.add(new RepeatableMigrationResolver(flyway, "R", new Location(locationDescriptor)));
        }

        flyway.setResolvers(migrationResolvers.toArray(new MigrationResolver[0]));
    }
View Full Code Here

Examples of org.fusesource.hawtjournal.api.Location

  }

  @Override
  public User getUser(int userId) {
    try {
      Location location = new Location();
      JournalUserStorage.MetaData metaData = metaDataList.get(userId);
      location.readExternal(ByteStreams.newDataInput(metaData.getLocation()));
      return User.fromByteBuffer(userJournal.read(location));
    } catch (IOException e) {
      throw new RuntimeException(e);
    }
  }
View Full Code Here

Examples of org.glassfish.contextpropagation.Location

    }

    @Override
    public Location getLocation() {
      try {
        Location location =  get(Location.KEY);
        if (location == null) {
          //throw new AssertionError("No location set");
          location = new Location(new ViewImpl(Location.KEY)) {};
          final Entry locationEntry = new Entry(location,
              Location.PROP_MODES, ContextType.VIEW_CAPABLE).init(true, false);
          mapFinder.getMapAndCreateIfNeeded().put(Location.KEY, locationEntry);
        }
        return location;
View Full Code Here

Examples of org.glassfish.jersey.examples.flight.model.Location

            throw new BadRequestException("Incomplete data.");
        }

        Aircraft aircraft = new Aircraft();
        aircraft.setType(new AircraftType(manufacturer, type, capacity));
        aircraft.setLocation(SimEngine.bound(new Location(x, y)));

        if (!DataStore.addAircraft(aircraft)) {
            throw new InternalServerErrorException("Unable to add new aircraft.");
        }
View Full Code Here

Examples of org.gtugs.domain.Location

  public void incrementOrStoreLocation(Double latitude,
      Double longitude) {
    PersistenceManager pm = getPersistenceManager();

    String key = latitude + ";" + longitude;
    Location location = null;

    try {
      location = pm.getObjectById(Location.class, key);

      if (location != null) {
        location.setOccurrences(location.getOccurrences() + 1);
        pm.makePersistent(location);
      }
    } catch (JDOObjectNotFoundException e) {
      location = new Location(key, latitude, longitude);
      pm.makePersistent(location);
    } finally {
      pm.close();
    }
  }
View Full Code Here

Examples of org.hibernate.search.test.engine.Location

    Session session = openSession();
    FullTextSession fullTextSession = Search.getFullTextSession( session );
    Transaction transaction = fullTextSession.beginTransaction();
    Country italy = new Country( "Italy", 39d );
    for ( int i = 0; i < NUM_LOCATIONS; i++ ) {
      session.persist( new Location( i, Long.valueOf( i ), 7 * i, Double.valueOf( 9 * i ), Integer
          .valueOf( 100 - i ), String.valueOf( i ) + "42", null, italy, BigDecimal.ONE ) );
    }
    transaction.commit();
    session.close();
  }
View Full Code Here

Examples of org.hibernate.test.annotations.id.entities.Location

    Session s = openSession();
    Transaction tx = s.beginTransaction();
    s.persist( tower );
    s.flush();
    s.clear();
    Location loc = new Location();
    loc.latitude = tower.latitude;
    loc.longitude = tower.longitude;
    assertNotNull( s.get( Tower.class, loc ) );
    tx.rollback();
    s.close();
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.