Package nexj.core.meta

Examples of nexj.core.meta.MetadataValidationException


      {
         state.removeAdapter(m_adapter, this);
      }
      else
      {
         MetadataValidationException e = new MetadataValidationException(
            "err.meta.upgrade.sql.adapterDuplicateStart", new Object[]{m_adapter.getName()});

         setProperties(e);
         eh = addException(eh, e);
      }
View Full Code Here


         m_create.validate(m_schema, null, null);
         m_drop.validate(m_schema, null, null);
      }
      catch (UncheckedException e)
      {
         MetadataValidationException x = new MetadataValidationException(e);

         setProperties(x);

         throw x;
      }
View Full Code Here

         func = compiler.compile(body, m_posMap, m_urlMap, machine, false);
      }
      catch (CompilerException e)
      {
         MetadataValidationException x = new MetadataValidationException(e);

         setProperties(x);

         String sURL = ((CompilerException)e).getURL();

         if (sURL != null)
         {
            int i = URL_PREFIX.length() + getName().length() + 1;
            int k = sURL.indexOf('.', i);

            if (k >= 0)
            {
               x.setProperty("testcase", sURL.substring(k + 1));
            }
            else if (i < sURL.length())
            {
               x.setProperty("script", sURL.substring(i));
            }
         }

         throw x;
      }
View Full Code Here

            IOUtil.copy(dataStream, istream);

            return new Binary(dataStream.toByteArray());
         }

         throw new MetadataValidationException("err.meta.invalidFilePath", new Object[] { sName });
      }
      catch (Exception e)
      {
         throw new MetadataException("err.meta.fileLookup", new Object[] { sName, this }, e);
      }
View Full Code Here

      if (warnings != null)
      {
         if (m_genericRPCPrivilege == null)
         {
            MetadataValidationException e = new MetadataValidationException(
               "err.meta.missingRPCPrivilege", new Object[]{m_sName});

            setProperties(e);
            e.setProperty("item", "rpcPrivilege");

            if (m_configURL != null)
            {
               e.setResourceName(m_configURL.toString());
            }

            warnings.addException(e);
         }
      }
View Full Code Here

      {
         addException((MetadataValidationException)e);
      }
      else
      {
         MetadataValidationException x = new MetadataValidationException(e);

         setMarker(x);
         getException().addException(x);
      }
   }
View Full Code Here

      {
         throw new MetadataException("err.meta.resourceOpen", new Object[]{m_sMetadataFileName}, e);
      }
      catch (UncheckedException e)
      {
         MetadataValidationException x = new MetadataValidationException(e);
         setMarker(x);

         throw x;
      }
      finally
View Full Code Here

            String sElName = getResourceName(sResName);
            Object oldResName = resourceMap.put(sElName, sResName);

            if (oldResName != null && !sResName.equals(oldResName))
            {
               MetadataValidationException e = new MetadataValidationException("err.meta.multiPathResource",
                  new Object[]{sResName, oldResName});

               e.setResourceName(sResName);
               e.setTypeName(sMarkerTypeName);
               e.setProperty(sMarkerPropertyName, sElName);

               addException(e);
            }
         }
      }
View Full Code Here

         catch (MetadataCompoundValidationException e)
         {
            for (Iterator xitr = e.getExceptionIterator(); xitr.hasNext();)
            {
               UncheckedException ux = (UncheckedException)xitr.next();
               MetadataValidationException x;

               if (ux instanceof MetadataValidationException)
               {
                  x = (MetadataValidationException)ux;

                  if (x.getResourceName() == null)
                  {
                     fixup.setMarker(x);
                  }
               }
               else
               {
                  x = new MetadataValidationException(ux);
                  fixup.setMarker(x);
               }

               addException(x);
            }
         }
         catch (MetadataValidationException e)
         {
            if (e.getResourceName() == null)
            {
               fixup.setMarker(e);
            }

            addException(e);
         }
         catch (UncheckedException e)
         {
            MetadataValidationException x = new MetadataValidationException(e);
            fixup.setMarker(x);
            addException(x);
         }
      }
View Full Code Here

         {
         }

         public void handleCircularReference(XMLMixin mixin)
         {
            throw new MetadataValidationException("err.meta.mixinCycle", new Object[]{mixin.getName()});
         }

         public void handleLinkFailure(XMLMixin ref, Exception e)
         {
            throw new MetadataException("err.meta.mixin", new Object[]{ref}, e);
View Full Code Here

TOP

Related Classes of nexj.core.meta.MetadataValidationException

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.