Package java.lang

Examples of java.lang.Object


      remove( child );
    }
  }

  private <P, C> void storeParent( @Nonnull C child, @Nonnull P parent ) {
    Object oldParent = findParent( child );
    if ( oldParent != null ) {
      if ( parent == oldParent ) {
        return;
      } else {
        throw new IllegalStateException( "Child <" + child + "> still has a parent: <" + oldParent + ">. New parent is: <" + parent + '>' );
View Full Code Here


   */
  @Nonnull
  public List<? extends Object> getPredecessors( @Nonnull Object child ) {
    List<Object> list = new ArrayList<Object>();

    Object parent = findParent( child );
    while ( parent != null ) {
      list.add( parent );
      parent = findParent( parent );
    }

View Full Code Here

   * @param parent   the parent
   * @param children the children
   */
  public void store( @Nonnull Object parent, @Nonnull List<? extends Object> children ) {
    for ( int index = 0; index < children.size(); index++ ) {
      Object child = children.get( index );
      store( child, parent, index );
    }
  }
View Full Code Here

            new com.sun.star.beans.PropertyValue("user",0,myConfigItems.get("user"),com.sun.star.beans.PropertyState.DIRECT_VALUE),
            new com.sun.star.beans.PropertyValue("password",0,myConfigItems.get("password"),com.sun.star.beans.PropertyState.DIRECT_VALUE)
        };
        try
        {
            Object rConfigProv = myServiceManager.createInstanceWithArguments("com.sun.star.configuration.ConfigurationProvider",ConInfo);                                       
        if(rConfigProv != null)
        {
            myConfigProvider  = (com.sun.star.lang.XMultiServiceFactory)UnoRuntime.queryInterface(com.sun.star.lang.XMultiServiceFactory.class, rConfigProv);                                  
            if (myConfigProvider == null)
            {
View Full Code Here

    try
    {       
        String[] aNodeNames = xNode.getElementNames();                                                    
            for(int i=0; i < aNodeNames.length; i++)
            {
              Object returnNode =  xNode.getByName(aNodeNames[i]);
        if(returnNode instanceof com.sun.star.uno.XInterface)
        {
          //CASE: INNER NODE: calling            
         
          //starttag    
View Full Code Here

            XInterface xCfgAccess = (XInterface) myConfigProvider.createInstanceWithArguments("com.sun.star.configuration.ConfigurationAccess", new Object[]{sNodeName, new Integer(-1)});           
          com.sun.star.container.XNameAccess xNode = (com.sun.star.container.XNameAccess)UnoRuntime.queryInterface(com.sun.star.container.XNameAccess.class,xCfgAccess);
          // PropertySet ( geht noch nicht -> bug )
          // com.sun.star.beans.XPropertySetInfo xNodeProper = (com.sun.star.beans.XPropertySetInfo)UnoRuntime.queryInterface(com.sun.star.beans.XPropertySetInfo.class,xCfgAccess);
          //
          Object myNode = xNode.getByName(sValueName);
            if (myNode instanceof XInterface)
            {
                myprintln("It's a node not a value");
            }
            else
View Full Code Here

     *
     * @param className The ProxyHandler implementation class name
     */
    public void setProxyHandler(String className) {

        Object handler = null;
        try {
            Class handlerClass = webContainer.loadCommonClass(className);
            handler = handlerClass.newInstance();
        } catch (Exception e) {
            String msg = MessageFormat.format(_rb.getString(PROXY_HANDLER_CLASS_LOAD_ERROR), className);
View Full Code Here

     *
     * @param className The ProxyHandler implementation class name
     */
    public void setProxyHandler(String className) {

        Object handler = null;
        try {
            Class handlerClass = webContainer.loadCommonClass(className);
            handler = handlerClass.newInstance();
        } catch (Exception e) {
            String msg = MessageFormat.format(_rb.getString(PROXY_HANDLER_CLASS_LOAD_ERROR), className);
View Full Code Here

    XConnection xConn    = xConnector.connect("socket,host=localhost,port=6001");
    if(xConn == null) System.err.println("no XConnection!");

    IBridge iBridge = UnoRuntime.getBridgeByName("java", null, "remote", null, new Object[]{"iiop", xConn, null});

    Object rInitialObject = iBridge.mapInterfaceFrom("classic_uno", XInterface.class);

    if(rInitialObject != null)
    {
      System.err.println("got the remote object");
      System.out.println("before naming service !");
      try
      {
        XNamingService rName = (XNamingService)UnoRuntime.queryInterface(XNamingService.class, rInitialObject );
        try
        {
          if(rName != null)
          {
            System.err.println("got the remote naming service !");
            Object rXsmgr = rName.getRegisteredObject("StarOffice.ServiceManager");
            XMultiServiceFactory rSmgr = (XMultiServiceFactory)UnoRuntime.queryInterface(XMultiServiceFactory.class, rXsmgr);
            if(rSmgr != null)
            {
              System.out.println("got the remote service manager !");
              Object rDriver = rSmgr.createInstance("com.sun.star.sdbc.ADriver");
              if(rDriver != null)
              {
                System.out.println("got a com.sun.star.sdbc.Driver !");
                com.sun.star.sdbc.XDriver  xDriver  = (XDriver)UnoRuntime.queryInterface(com.sun.star.sdbc.XDriver.class,rDriver);
                if(xDriver != null)
View Full Code Here

}

public static class CtorReader extends AFn{
  public Object invoke(Object reader, Object firstChar){
    PushbackReader r = (PushbackReader) reader;
    Object name = read(r, true, null, false);
    if (!(name instanceof Symbol))
      throw new RuntimeException("Reader tag must be a symbol");
    Symbol sym = (Symbol)name;
    return sym.getName().contains(".") ? readRecord(r, sym) : readTagged(r, sym);
  }
View Full Code Here

TOP

Related Classes of java.lang.Object

Copyright © 2018 www.massapicom. 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.