Examples of Location


Examples of org.apache.tapestry.Location

        if (_lastLocation == null)
        {
            _lastLine = line;
            _lastColumn = column;
            _lastLocation = new Location(_resourceLocation, line, column);
        }

        return _lastLocation;
    }
View Full Code Here

Examples of org.apache.tapestry.ioc.Location

    @Test
    public void object_can_not_be_instantiated()
    {
        ComponentResources resources = mockComponentResources();
        Location l = mockLocation();
        Environment environment = mockEnvironment();

        expect(resources.triggerEvent(Form.PREPARE, null, null)).andReturn(false);

        train_push(environment, PropertyEditContext.class);
View Full Code Here

Examples of org.apache.tapestry5.ioc.Location

            {
                // Expected
            }
            catch (Exception ex)
            {
                Location location = component == null ? null : component.getComponentResources().getLocation();

                throw new TapestryException(ex.getMessage(), location, ex);
            }
            finally
            {
View Full Code Here

Examples of org.apache.tools.ant.Location

            parser.setEntityResolver(hb);
            parser.setErrorHandler(hb);
            parser.setDTDHandler(hb);
            parser.parse(inputSource);
        } catch (SAXParseException exc) {
            Location location = new Location(exc.getSystemId(), exc.getLineNumber(), exc
                                             .getColumnNumber());

            Throwable t = exc.getException();
            if (t instanceof BuildException) {
                BuildException be = (BuildException) t;
View Full Code Here

Examples of org.apache.twill.filesystem.Location

      }
    }
  }

  private void updateCredentials(String application, RunId runId, Credentials updates) throws IOException {
    Location credentialsLocation = locationFactory.create(String.format("/%s/%s/%s", application, runId.getId(),
                                                                        Constants.Files.CREDENTIALS));
    // Try to read the old credentials.
    Credentials credentials = new Credentials();
    if (credentialsLocation.exists()) {
      DataInputStream is = new DataInputStream(new BufferedInputStream(credentialsLocation.getInputStream()));
      try {
        credentials.readTokenStorageStream(is);
      } finally {
        is.close();
      }
    }

    // Overwrite with the updates.
    credentials.addAll(updates);

    // Overwrite the credentials.
    Location tmpLocation = credentialsLocation.getTempFile(Constants.Files.CREDENTIALS);

    // Save the credentials store with user-only permission.
    DataOutputStream os = new DataOutputStream(new BufferedOutputStream(tmpLocation.getOutputStream("600")));
    try {
      credentials.writeTokenStorageToStream(os);
    } finally {
      os.close();
    }

    // Rename the tmp file into the credentials location
    tmpLocation.renameTo(credentialsLocation);

    LOG.debug("Secure store for {} {} saved to {}.", application, runId, credentialsLocation.toURI());
  }
View Full Code Here

Examples of org.apache.xindice.webadmin.Location

     * @return map containing status for a path
     * @throws DBException
     */
    public static Map copy(Collection col, String dest, boolean overwrite, boolean deep) throws DBException {

        Location destLocation = new Location(dest);
        Collection destCollection = destLocation.getCollection();
        String destName = destLocation.getName();
        Map results = new HashMap();

        if (destLocation.isRoot()) {
            results.put(dest, new Integer(WebdavStatus.SC_BAD_REQUEST));
            return results;
        } else if (destCollection == null) {
            // either intermidiate collection does not exist or destination points to
            // the first level collection (database).
View Full Code Here

Examples of org.apache.xmlbeans.xml.stream.Location

            annotate( new XmlLineNumber( line, column, offset ) );
        }

        void lineNumberAnnotation ( XMLEvent xe )
        {
            Location loc = xe.getLocation();

            if (loc != null)
            {
                lineNumberAnnotation(
                    loc.getLineNumber(), loc.getColumnNumber(), -1 );
            }
        }
View Full Code Here

Examples of org.aspectj.org.eclipse.jdt.internal.formatter.Location

  // location to align and break on.
  public Alignment(String name, int mode, int tieBreakRule, Scribe scribe, int fragmentCount, int sourceRestart, int continuationIndent){
   
    this.name = name;
    this.location = new Location(scribe, sourceRestart);
    this.mode = mode;
    this.tieBreakRule = tieBreakRule;
    this.fragmentCount = fragmentCount;
    this.scribe = scribe;
    this.originalIndentationLevel = this.scribe.indentationLevel;
View Full Code Here

Examples of org.auraframework.system.Location

    public PropertyReferenceImplTest(String name) {
        super(name);
    }

    public void testExpression() throws Exception {
        Location loc = new Location("expressionism", 456);
        PropertyReferenceImpl pr = new PropertyReferenceImpl("test.yo.self", loc);
        assertSame(loc, pr.getLocation());
        assertEquals("root was not correct", "test", pr.getRoot());
        assertEquals(3, pr.size());
        List<String> l = pr.getList();
View Full Code Here

Examples of org.bukkit.Location

        slapHeight = Integer.parseInt(args[1]);
      } catch (Throwable e) {}
    }
   
    // store player's original position, so we can return him safely back (in case he's underground and another player slaps him to heavens)
    Location loc = target.getLocation();
    slappedLastLocations.put(tName, loc);
   
    target.setVelocity(new Vector(0, slapHeight, 0));
   
    // insure player's safe return home even if they fall into deep water and no damage is done
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.