Package railo.runtime.type

Examples of railo.runtime.type.StructImpl


    return client.getLabel();
  }

  @Override
  public Struct detail() {
    Struct sct=new StructImpl();
    sct.setEL("label", client.getLabel());
    sct.setEL("url", client.getUrl());
   
    return sct;
  }
View Full Code Here


      if(true) return;
     
      PageContextImpl pc=null;
      try{
        pc = ThreadUtil.createPageContext(cw, DevNullOutputStream.DEV_NULL_OUTPUT_STREAM,
        "localhost", "/","", new Cookie[0], new Pair[0], new Pair[0], new StructImpl());
       
      }
      catch(Throwable t){
        return;
      }
View Full Code Here

        Struct meta =null;
        try {
          meta=getMeta(dc,tablequalifier,tableowner,tablename);
        }
        catch(SQLException se){
          meta=new StructImpl();
        }
       
       
        SQL sql=createSQL(meta);
      if(sql!=null) {
View Full Code Here

    return datasource;
  }

  public static Struct getMeta(DatasourceConnection dc,String tableQualifier, String tableOwner, String tableName) throws SQLException {
      DatabaseMetaData md = dc.getConnection().getMetaData();
      Struct  sct=new StructImpl();
    ResultSet columns = md.getColumns(tableQualifier, tableOwner, tableName, null);
   
    try{
      String name;
      while(columns.next()) {
        name=columns.getString("COLUMN_NAME");
        sct.setEL(name, new ColumnInfo(name,columns.getInt("DATA_TYPE"),columns.getBoolean("IS_NULLABLE")));
       
      }
    }
    finally {
      DBUtil.closeEL(columns);
View Full Code Here


  public int doStartTag() throws PageException {
    if(true)throw new TagNotSupported("ntauthenticate");
        String os = System.getProperty("os.name");
        Struct resultSt = new StructImpl();
        pageContext.setVariable(result, resultSt);
       
       
        if(SystemUtil.isWindows())  {
          /*
 
View Full Code Here

        store();
        adminSync.broadcast(attributes, config);
    }

  private void doGetDebugSetting() throws PageException {
    Struct sct=new StructImpl();
    sct.set("maxLogs", Caster.toDouble(config.getDebugMaxRecordsLogged()));
    pageContext.setVariable(getString("admin",action,"returnVariable"),sct);
       
    }
View Full Code Here

     */
    private void doGetMapping() throws PageException {
       
     
        Mapping[] mappings = config.getMappings();
        Struct sct=new StructImpl();
        String virtual=getString("admin",action,"virtual");
       
        for(int i=0;i<mappings.length;i++) {
            MappingImpl m=(MappingImpl) mappings[i];
            if(!m.getVirtual().equals(virtual)) continue;
           
            sct.set("archive",m.getArchive());
            sct.set("strarchive",m.getStrArchive());
            sct.set("physical",m.getPhysical());
            sct.set("strphysical",m.getStrPhysical());
            sct.set("virtual",m.getVirtual());
            sct.set(KeyConstants._hidden,Caster.toBoolean(m.isHidden()));
            sct.set("physicalFirst",Caster.toBoolean(m.isPhysicalFirst()));
            sct.set("readonly",Caster.toBoolean(m.isReadonly()));
            sct.set("inspect",ConfigWebUtil.inspectTemplate(m.getInspectTemplateRaw(), ""));
            sct.set("toplevel",Caster.toBoolean(m.isTopLevel()));

            pageContext.setVariable(getString("admin",action,"returnVariable"),sct);
            return;
        }
        throw new ApplicationException("there is no mapping with virtual ["+virtual+"]");
View Full Code Here

        pageContext.setVariable(getString("admin",action,"returnVariable"),qry);
    }

    private void doGetExtensionInfo() throws PageException {
      Resource ed = config.getExtensionDirectory();
      Struct sct=new StructImpl();
      sct.set(KeyConstants._directory, ed.getPath());
      sct.set(KeyConstants._enabled, Caster.toBoolean(config.isExtensionEnabled()));
     
        pageContext.setVariable(getString("admin",action,"returnVariable"),sct);
    }
View Full Code Here

        }
        pageContext.setVariable(getString("admin",action,"returnVariable"),qry);
    }
   
    private void doGetRestSettings() throws PageException {
    Struct sct=new StructImpl();
    sct.set(KeyConstants._list, Caster.toBoolean(config.getRestList()));
    //sct.set(KeyImpl.init("allowChanges"), Caster.toBoolean(config.getRestAllowChanges()));
    pageContext.setVariable(getString("admin",action,"returnVariable"),sct);
       
    }
View Full Code Here

    /**
     * @throws PageException
     *
     */
    private void doGetMailSetting() throws PageException {
        Struct sct=new StructImpl();
        pageContext.setVariable(getString("admin",action,"returnVariable"),sct);
       
        LogAndSource ls=config.getMailLogger();
        railo.commons.io.log.Log log=ls.getLog();
        String logFile="";
        //String logLevel="";
        if(log instanceof LogResource)logFile=((LogResource)log).getResource().toString();
        String logLevel=LogUtil.toStringType(log.getLogLevel(),"ERROR");
        sct.set("strlogfile",ls.getSource());
        sct.set("logfile",logFile);
        sct.set("loglevel",logLevel);
        int maxThreads=20;
        SpoolerEngine engine = config.getSpoolerEngine();
        if(engine instanceof SpoolerEngineImpl) {
          maxThreads=((SpoolerEngineImpl)engine).getMaxThreads();
        }
       
        sct.set("spoolEnable",Caster.toBoolean(config.isMailSpoolEnable()));
        sct.set("spoolInterval",Caster.toInteger(config.getMailSpoolInterval()));
        sct.set("maxThreads",Caster.toDouble(maxThreads));
        sct.set("timeout",Caster.toInteger(config.getMailTimeout()));
    sct.set("defaultencoding", config.getMailDefaultEncoding());
       
    }
View Full Code Here

TOP

Related Classes of railo.runtime.type.StructImpl

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.