当前位置: 首页>>代码示例>>Java>>正文


Java AppConfig.getProperty方法代码示例

本文整理汇总了Java中com.openbravo.pos.forms.AppConfig.getProperty方法的典型用法代码示例。如果您正苦于以下问题:Java AppConfig.getProperty方法的具体用法?Java AppConfig.getProperty怎么用?Java AppConfig.getProperty使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在com.openbravo.pos.forms.AppConfig的用法示例。


在下文中一共展示了AppConfig.getProperty方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: loadProperties

import com.openbravo.pos.forms.AppConfig; //导入方法依赖的package包/类
@Override
public void loadProperties(AppConfig config) {
    
    String sCommerceID = config.getProperty("payment.commerceid");
    String sCommerceTerminal = config.getProperty("payment.terminal");
    String sCommerceSign = config.getProperty("payment.commercesign");
    String sCommerceSHA = config.getProperty("payment.SHA");
    
    if (sCommerceID!=null && sCommerceTerminal!=null && sCommerceSign!=null && sCommerceSHA!=null && sCommerceSign.startsWith("crypt:")) {
        jtxtCommerceCode.setText(config.getProperty("payment.commerceid"));
        AltEncrypter cypher = new AltEncrypter("cypherkey");
        jtxtCommerceTerminal.setText(comboValue(config.getProperty("payment.terminal")));
        jtxtCommerceSign.setText(cypher.decrypt(config.getProperty("payment.commercesign").substring(6)));
        jCheckBox1.setSelected(Boolean.valueOf(config.getProperty("payment.SHA")).booleanValue());
    }
 
}
 
开发者ID:iMartinezMateu,项目名称:openbravo-pos,代码行数:18,代码来源:ConfigPaymentPanelCaixa.java

示例2: loadProperties

import com.openbravo.pos.forms.AppConfig; //导入方法依赖的package包/类
public void loadProperties(AppConfig config) {

        jtxtUrl.setText(config.getProperty("erp.URL"));    
        jtxtId.setText(config.getProperty("erp.id"));
        jTextField2.setText(config.getProperty("erp.pos"));
        jTextField1.setText(config.getProperty("erp.org"));
        
        String sERPUser = config.getProperty("erp.user");
        String sERPPassword = config.getProperty("erp.password");        
        if (sERPUser != null && sERPPassword != null && sERPPassword.startsWith("crypt:")) {
            // La clave esta encriptada.
            AltEncrypter cypher = new AltEncrypter("cypherkey" + sERPUser);
            sERPPassword = cypher.decrypt(sERPPassword.substring(6));
        }        
        jtxtName.setText(sERPUser);
        jtxtPassword.setText(sERPPassword);    
        
        dirty.setDirty(false);
    }
 
开发者ID:iMartinezMateu,项目名称:openbravo-pos,代码行数:20,代码来源:JPanelConfigERP.java

示例3: loadProperties

import com.openbravo.pos.forms.AppConfig; //导入方法依赖的package包/类
public void loadProperties(AppConfig config) {
    
    jtxtDbDriverLib.setText(config.getProperty("db.driverlib"));
    jtxtDbDriver.setText(config.getProperty("db.driver"));
    jtxtDbURL.setText(config.getProperty("db.URL"));
    
    String sDBUser = config.getProperty("db.user");
    String sDBPassword = config.getProperty("db.password");        
    if (sDBUser != null && sDBPassword != null && sDBPassword.startsWith("crypt:")) {
        // La clave esta encriptada.
        AltEncrypter cypher = new AltEncrypter("cypherkey" + sDBUser);
        sDBPassword = cypher.decrypt(sDBPassword.substring(6));
    }        
    jtxtDbUser.setText(sDBUser);
    jtxtDbPassword.setText(sDBPassword);   
    
    dirty.setDirty(false);
}
 
开发者ID:iMartinezMateu,项目名称:openbravo-pos,代码行数:19,代码来源:JPanelConfigDatabase.java

示例4: loadProperties

import com.openbravo.pos.forms.AppConfig; //导入方法依赖的package包/类
/**
 *
 * @param config
 */
@Override
public void loadProperties(AppConfig config) {
    
    String sCommerceID = config.getProperty("payment.commerceid");
    String sCommerceTerminal = config.getProperty("payment.terminal");
    String sCommerceSign = config.getProperty("payment.commercesign");
    String sCommerceSHA = config.getProperty("payment.SHA");
    
    if (sCommerceID!=null && sCommerceTerminal!=null && sCommerceSign!=null && sCommerceSHA!=null && sCommerceSign.startsWith("crypt:")) {
        jtxtCommerceCode.setText(config.getProperty("payment.commerceid"));
        AltEncrypter cypher = new AltEncrypter("cypherkey");
        jtxtCommerceTerminal.setText(comboValue(config.getProperty("payment.terminal")));
        jtxtCommerceSign.setText(cypher.decrypt(config.getProperty("payment.commercesign").substring(6)));
        jCheckBox1.setSelected(Boolean.valueOf(config.getProperty("payment.SHA")).booleanValue());
    }
 
}
 
开发者ID:gnoopy,项目名称:wifepos,代码行数:22,代码来源:ConfigPaymentPanelCaixa.java

示例5: loadProperties

import com.openbravo.pos.forms.AppConfig; //导入方法依赖的package包/类
/**
 *
 * @param config
 */
@Override
public void loadProperties(AppConfig config) {

    jtxtUrl.setText(config.getProperty("erp.URL"));    
    jtxtId.setText(config.getProperty("erp.id"));
    jTextField2.setText(config.getProperty("erp.pos"));
    jTextField1.setText(config.getProperty("erp.org"));
    
    String sERPUser = config.getProperty("erp.user");
    String sERPPassword = config.getProperty("erp.password");        
    if (sERPUser != null && sERPPassword != null && sERPPassword.startsWith("crypt:")) {
        // La clave esta encriptada.
        AltEncrypter cypher = new AltEncrypter("cypherkey" + sERPUser);
        sERPPassword = cypher.decrypt(sERPPassword.substring(6));
    }        
    jtxtName.setText(sERPUser);
    jtxtPassword.setText(sERPPassword);    
    
    dirty.setDirty(false);
}
 
开发者ID:herbiehp,项目名称:unicenta,代码行数:25,代码来源:JPanelConfigERP.java

示例6: loadProperties

import com.openbravo.pos.forms.AppConfig; //导入方法依赖的package包/类
/**
 *
 * @param config
 */
@Override
public void loadProperties(AppConfig config) {

    jtxtMachineHostname.setText(config.getProperty("machine.hostname"));

    String lafclass = config.getProperty("swing.defaultlaf");
    jcboLAF.setSelectedItem(null);
    for (int i = 0; i < jcboLAF.getItemCount(); i++) {
        LAFInfo lafinfo = (LAFInfo) jcboLAF.getItemAt(i);
        if (lafinfo.getClassName().equals(lafclass)) {
            jcboLAF.setSelectedIndex(i);
            break;
        }
    }
    // jcboLAF.setSelectedItem(new LookAndFeelInfo());

    jcboMachineScreenmode.setSelectedItem(config.getProperty("machine.screenmode"));
    jcboTicketsBag.setSelectedItem(config.getProperty("machine.ticketsbag"));
    jchkHideInfo.setSelected(Boolean.valueOf(config.getProperty("till.hideinfo")).booleanValue());        
    jtxtStartupLogo.setText(config.getProperty("start.logo"));
    jtxtStartupText.setText(config.getProperty("start.text"));          
  
    dirty.setDirty(false);
}
 
开发者ID:gnoopy,项目名称:wifepos,代码行数:29,代码来源:JPanelConfigGeneral.java

示例7: loadProperties

import com.openbravo.pos.forms.AppConfig; //导入方法依赖的package包/类
/**
 *
 * @param config
 */
@Override
public void loadProperties(AppConfig config) {
  
    jcboDBDriver.setSelectedItem(config.getProperty("db.engine"));
    jtxtDbDriverLib.setText(config.getProperty("db.driverlib"));
    jtxtDbDriver.setText(config.getProperty("db.driver"));
    jtxtDbURL.setText(config.getProperty("db.URL"));
    
    String sDBUser = config.getProperty("db.user");
    String sDBPassword = config.getProperty("db.password");        
    if (sDBUser != null && sDBPassword != null && sDBPassword.startsWith("crypt:")) {
        // La clave esta encriptada.
        AltEncrypter cypher = new AltEncrypter("cypherkey" + sDBUser);
        sDBPassword = cypher.decrypt(sDBPassword.substring(6));
    }        
    jtxtDbUser.setText(sDBUser);
    jtxtDbPassword.setText(sDBPassword);   
    
    dirty.setDirty(false);
}
 
开发者ID:sbandur84,项目名称:micro-Blagajna,代码行数:25,代码来源:JPanelConfigDatabase.java

示例8: loadProperties

import com.openbravo.pos.forms.AppConfig; //导入方法依赖的package包/类
@Override
public void loadProperties(AppConfig config) {
    String sCommerceID = config.getProperty("payment.commerceid");
    String sCertificatePass = config.getProperty("payment.certificatePassword");
    String sCertificatePath = config.getProperty("payment.certificatePath");
    
    if (sCommerceID!=null && sCertificatePath!=null && sCertificatePass!=null && sCertificatePass.startsWith("crypt:")) {
        jtxtStoreName.setText(config.getProperty("payment.commerceid"));
        AltEncrypter cypher = new AltEncrypter("cypherkey");
        jtxtCertificatePass.setText(cypher.decrypt(config.getProperty("payment.certificatePassword").substring(6)));
        jtxtCertificatePath.setText(config.getProperty("payment.certificatePath"));
    }
}
 
开发者ID:iMartinezMateu,项目名称:openbravo-pos,代码行数:14,代码来源:ConfigPaymentPanelLinkPoint.java

示例9: loadProperties

import com.openbravo.pos.forms.AppConfig; //导入方法依赖的package包/类
@Override
public void loadProperties(AppConfig config) {
    String sCommerceID = config.getProperty("payment.commerceid");
    String sCommercePass = config.getProperty("payment.commercepassword");
    
    if (sCommerceID != null && sCommercePass != null && sCommercePass.startsWith("crypt:")) {
        jtxtCommerceID.setText(config.getProperty("payment.commerceid"));
        AltEncrypter cypher = new AltEncrypter("cypherkey" + config.getProperty("payment.commerceid"));
        jtxtCommercePwd.setText(cypher.decrypt(config.getProperty("payment.commercepassword").substring(6)));
    }
}
 
开发者ID:iMartinezMateu,项目名称:openbravo-pos,代码行数:12,代码来源:ConfigPaymentPanelGeneric.java

示例10: loadProperties

import com.openbravo.pos.forms.AppConfig; //导入方法依赖的package包/类
public void loadProperties(AppConfig config) {
    
    String slang = config.getProperty("user.language");
    String scountry = config.getProperty("user.country");
    String svariant = config.getProperty("user.variant");
    
    if (slang != null && !slang.equals("") && scountry != null && svariant != null) {                    
        Locale currentlocale = new Locale(slang, scountry, svariant);
        for (int i = 0 ; i < jcboLocale.getItemCount(); i++)  {
            LocaleInfo l = (LocaleInfo) jcboLocale.getItemAt(i);
            if (currentlocale.equals(l.getLocale())) {
                jcboLocale.setSelectedIndex(i);
                break;
            }
        }        
    } else {
        jcboLocale.setSelectedIndex(0);
    }
    
    jcboInteger.setSelectedItem(writeWithDefault(config.getProperty("format.integer")));
    jcboDouble.setSelectedItem(writeWithDefault(config.getProperty("format.double")));
    jcboCurrency.setSelectedItem(writeWithDefault(config.getProperty("format.currency")));
    jcboPercent.setSelectedItem(writeWithDefault(config.getProperty("format.percent")));
    jcboDate.setSelectedItem(writeWithDefault(config.getProperty("format.date")));
    jcboTime.setSelectedItem(writeWithDefault(config.getProperty("format.time")));
    jcboDatetime.setSelectedItem(writeWithDefault(config.getProperty("format.datetime")));
           
    dirty.setDirty(false);
}
 
开发者ID:iMartinezMateu,项目名称:openbravo-pos,代码行数:30,代码来源:JPanelConfigLocale.java

示例11: loadProperties

import com.openbravo.pos.forms.AppConfig; //导入方法依赖的package包/类
/**
     *
     * @param config
     */
    @Override
        public void loadProperties(AppConfig config) {
        String sAccountID = config.getProperty("payment.BluePay.accountID");
        String sSecretKey = config.getProperty("payment.BluePay.secretKey");
        String sURL = config.getProperty("payment.BluePay.URL");
        
//        System.out.println(sURL);
         
        if (sAccountID!=null && sSecretKey!=null && sURL!=null && sURL.startsWith("https://")) {
            jtxtURL.setText(config.getProperty("payment.BluePay.URL"));
            jtxtAccountID.setText(config.getProperty("payment.BluePay.accountID"));
            jtxtSecretKey.setText(config.getProperty("payment.BluePay.secretKey"));
        }
    }
 
开发者ID:herbiehp,项目名称:unicenta,代码行数:19,代码来源:ConfigPaymentPanelBluePay20POST.java

示例12: printId

import com.openbravo.pos.forms.AppConfig; //导入方法依赖的package包/类
/**
     *
     * @return
     */
    public String printId() {
// We need acces to the config file        
      AppConfig m_config =  new AppConfig(new File((System.getProperty("user.home")), AppLocal.APP_ID + ".properties"));        
      m_config.load();
      String receiptSize =(m_config.getProperty("till.receiptsize"));
      String receiptPrefix =(m_config.getProperty("till.receiptprefix"));
// we have finished with m_config so unload it      
      m_config =null;


        if (m_iTicketId > 0) {
            String tmpTicketId=Integer.toString(m_iTicketId);
            if (receiptSize == null || (Integer.parseInt(receiptSize) <= tmpTicketId.length())){
                if (receiptPrefix != null){
                    tmpTicketId=receiptPrefix+tmpTicketId;
                } 
                return tmpTicketId;
            }            
            while (tmpTicketId.length()<Integer.parseInt(receiptSize)){
                tmpTicketId="0"+tmpTicketId;
            }
            if (receiptPrefix != null){
                    tmpTicketId=receiptPrefix+tmpTicketId;
            }             
            return tmpTicketId;
        } else {
            return "";
        }
    }
 
开发者ID:gnoopy,项目名称:wifepos,代码行数:34,代码来源:TicketInfo.java

示例13: loadProperties

import com.openbravo.pos.forms.AppConfig; //导入方法依赖的package包/类
/**
 *
 * @param config
 */
@Override
public void loadProperties(AppConfig config) {
    String sCommerceID = config.getProperty("payment.commerceid");
    String sCommercePass = config.getProperty("payment.commercepassword");
    
    if (sCommerceID != null && sCommercePass != null && sCommercePass.startsWith("crypt:")) {
        jtxtCommerceID.setText(config.getProperty("payment.commerceid"));
        AltEncrypter cypher = new AltEncrypter("cypherkey" + config.getProperty("payment.commerceid"));
        jtxtCommercePwd.setText(cypher.decrypt(config.getProperty("payment.commercepassword").substring(6)));
    }
}
 
开发者ID:herbiehp,项目名称:unicenta,代码行数:16,代码来源:ConfigPaymentPanelGeneric.java

示例14: loadProperties

import com.openbravo.pos.forms.AppConfig; //导入方法依赖的package包/类
/**
 *
 * @param config
 */
@Override
public void loadProperties(AppConfig config) {
    String sCommerceID = config.getProperty("payment.commerceid");
    String sCertificatePass = config.getProperty("payment.certificatePassword");
    String sCertificatePath = config.getProperty("payment.certificatePath");
    
    if (sCommerceID!=null && sCertificatePath!=null && sCertificatePass!=null && sCertificatePass.startsWith("crypt:")) {
        jtxtStoreName.setText(config.getProperty("payment.commerceid"));
        AltEncrypter cypher = new AltEncrypter("cypherkey");
        jtxtCertificatePass.setText(cypher.decrypt(config.getProperty("payment.certificatePassword").substring(6)));
        jtxtCertificatePath.setText(config.getProperty("payment.certificatePath"));
    }
}
 
开发者ID:herbiehp,项目名称:unicenta,代码行数:18,代码来源:ConfigPaymentPanelLinkPoint.java

示例15: loadProperties

import com.openbravo.pos.forms.AppConfig; //导入方法依赖的package包/类
/**
     *
     * @param config
     */
    public void loadProperties(AppConfig config) {
         
        db_url=(config.getProperty("db.url"));
        db_user=(config.getProperty("db_user"));
        db_password=(config.getProperty("db.password"));
       //catch (BasicException){
         // Session s = new Session(db_url,db_user,"epos");
        
}
 
开发者ID:herbiehp,项目名称:unicenta,代码行数:14,代码来源:CompanyDetails.java


注:本文中的com.openbravo.pos.forms.AppConfig.getProperty方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。