Package java.beans

Examples of java.beans.PropertyVetoException


    {
        Object val = evt.getNewValue();
        if ( "jndiName".equals( evt.getPropertyName() ) )
      {
          if (! (val instanceof Name || val instanceof String) )
        throw new PropertyVetoException("jndiName must be a String or a javax.naming.Name", evt);
      }
    }
      };
  this.addVetoableChangeListener( l );
View Full Code Here


        {
            //e.printStackTrace();
            if ( logger.isLoggable( MLevel.WARNING ) )
          logger.log( MLevel.WARNING, "Failed to create ConnectionTester of class " + val, e );
           
            throw new PropertyVetoException("Could not instantiate connection tester class with name '" + val + "'.", evt);
        }
      }
        else if ("userOverridesAsString".equals( propName ))
      {
          try
        { WrapperConnectionPoolDataSource.this.userOverrides = C3P0ImplUtils.parseUserOverridesAsString( (String) val ); }
          catch (Exception e)
        {
            if ( logger.isLoggable( MLevel.WARNING ) )
          logger.log( MLevel.WARNING, "Failed to parse stringified userOverrides. " + val, e );
           
            throw new PropertyVetoException("Failed to parse stringified userOverrides. " + val, evt);
        }
      }
    }
      };
  this.addVetoableChangeListener( setConnectionTesterListener );
View Full Code Here

                    "that does not belong to this collection.");
        }
        // check if the new series name already exists for another series
        Comparable key = (Comparable) e.getNewValue();
        if (getSeriesIndex(key) >= 0) {
            throw new PropertyVetoException("Duplicate key", e);
        }
    }
View Full Code Here

                    "that does not belong to this collection.");
        }
        // check if the new series name already exists for another series
        Comparable key = (Comparable) e.getNewValue();
        if (getSeriesIndex(key) >= 0) {
            throw new PropertyVetoException("Duplicate key2", e);
        }
    }
View Full Code Here

        if(args==null || args.length==0) {
            // getter
            return getter(p, method.getGenericReturnType());
        } else {
            throw new PropertyVetoException("Instance of " + getImplementation() + " named '" + getKey() +
                    "' is not locked for writing when invoking method " + method.getName()
                    + " you must use transaction semantics to access it.", null);
        }
    }
View Full Code Here

TOP

Related Classes of java.beans.PropertyVetoException

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.