Examples of PBKey


Examples of org.apache.ojb.broker.PBKey

   
    public void init()
    throws Exception
    {
        ConnectionRepository cr = MetadataManager.getInstance().connectionRepository();
        JdbcConnectionDescriptor jcd = cr.getDescriptor(new PBKey(jcdAlias));
        if (jcd == null)
        {
            jcd = new JdbcConnectionDescriptor();
            jcd.setJcdAlias(jcdAlias);
            cr.addDescriptor(jcd);
View Full Code Here

Examples of org.apache.ojb.broker.PBKey

    private JdbcConnectionDescriptor findJcd()
    {
        // Try to find JCD
        ConnectionRepository cr = MetadataManager.getInstance().connectionRepository();
        return cr.getDescriptor(new PBKey(JCD_ALIAS));
    }
View Full Code Here

Examples of org.apache.ojb.broker.PBKey

    public void afterPropertiesSet () throws Exception
    {
        // Try to find JCD
        ConnectionRepository cr = MetadataManager.getInstance().connectionRepository();
        JdbcConnectionDescriptor jcd = cr.getDescriptor(new PBKey(jcdAlias));
        if (jcd == null)
        {
            jcd = new JdbcConnectionDescriptor();
            jcd.setJcdAlias(jcdAlias);
            cr.addDescriptor(jcd);
View Full Code Here

Examples of org.apache.ojb.broker.PBKey

   
    public void init()
    throws Exception
    {
        ConnectionRepository cr = MetadataManager.getInstance().connectionRepository();
        JdbcConnectionDescriptor jcd = cr.getDescriptor(new PBKey(jcdAlias));
        if (jcd == null)
        {
            jcd = new JdbcConnectionDescriptor();
            jcd.setJcdAlias(jcdAlias);
            cr.addDescriptor(jcd);
View Full Code Here

Examples of org.apache.ojb.broker.PBKey

            {
                System.setProperty("OJB.properties", _propertiesFile);
            }

            ConnectionRepository connRep = MetadataManager.getInstance().connectionRepository();
            PBKey                pbKey   = null;

            if ((_jcdAlias == null) || (_jcdAlias.length() == 0))
            {
                pbKey = PersistenceBrokerFactory.getDefaultKey();
            }
View Full Code Here

Examples of org.apache.ojb.broker.PBKey

        }
        if(user != null && passwd == null)
        {
            passwd = "";
        }
        return new PBKey(dbName, user, passwd);
    }
View Full Code Here

Examples of org.apache.ojb.broker.PBKey

     */
    public static PBKey crossCheckPBKey(PBKey key)
    {
        if(key.getUser() == null)
        {
            PBKey defKey = MetadataManager.getInstance().connectionRepository().getStandardPBKeyForJcdAlias(key.getAlias());
            if(defKey != null)
            {
                return defKey;
            }
        }
View Full Code Here

Examples of org.apache.ojb.broker.PBKey

    {
      m_log.info("No enviroment entry was found, use default repository");
      ojbRepository = "repository.xml";
    }
    m_log.info("Use OJB repository file: " + ojbRepository);
    m_pbKey = new PBKey(ojbRepository);

    // Lookup the PBF implementation
    try
    {
      context = new InitialContext();
View Full Code Here

Examples of org.apache.ojb.broker.PBKey

  {
    Util.log("In OTMJCAManagedConnectionFactory.createManagedConnection");
    try
    {
      Kit kit = getKit();
      PBKey key = ((OTMConnectionRequestInfo) info).getPbKey();
      OTMConnection connection = kit.acquireConnection(key);
      return new OTMJCAManagedConnection(this, connection, key);
    }
    catch (ResourceException e)
    {
View Full Code Here

Examples of org.apache.ojb.broker.PBKey

                {
                    JdbcConnectionDescriptor descriptor = (JdbcConnectionDescriptor)it.next();

                    if (descriptor.isDefaultConnection())
                    {
                        metadataManager.setDefaultPBKey(new PBKey(descriptor.getJcdAlias(), descriptor.getUserName(), descriptor.getPassWord()));
                        break;
                    }
                }
            }
            return metadataManager;
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.