Package org.jboss.ws

Examples of org.jboss.ws.WSException


         Style style = (attrStyle == SOAPBinding.Style.RPC ? Style.RPC : Style.DOCUMENT);
         epMetaData.setStyle(style);

         SOAPBinding.Use attrUse = anSoapBinding.use();
         if (attrUse == SOAPBinding.Use.ENCODED)
            throw new WSException("SOAP encoding is not supported for JSR-181 deployments");

         epMetaData.setEncodingStyle(Use.LITERAL);

         ParameterStyle paramStyle = anSoapBinding.parameterStyle();
         epMetaData.setParameterStyle(paramStyle);
View Full Code Here


    *    (ex: bar/handlerfile1.xml)
    */
   protected void processHandlerChain(EndpointMetaData epMetaData, Class<?> wsClass)
   {
      if (wsClass.isAnnotationPresent(SOAPMessageHandlers.class))
         throw new WSException("Cannot combine @HandlerChain with @SOAPMessageHandlers");

      if (wsClass.isAnnotationPresent(HandlerChain.class))
      {
         HandlerChain anHandlerChain = wsClass.getAnnotation(HandlerChain.class);
         String filename = anHandlerChain.file();
View Full Code Here

               encoder.setOutput(ios);
               encoder.write((BufferedImage)obj);
            }
            catch (IOException e)
            {
               throw new WSException("Failed to convert " + obj.getClass());
            }
         }
         else
         {
            throw new WSException("Unable to convert " + obj.getClass());
         }

      }
View Full Code Here

         }
         fileURL = wsClass.getClassLoader().getResource(resourcePath);
      }

      if (fileURL == null)
         throw new WSException("Cannot resolve handler file '" + filename + "' on " + wsClass.getName());

      log.debug("Loading handler chain: " + fileURL);
     
      UnifiedHandlerChainsMetaData handlerChainsMetaData = null;
      try
      {
         InputStream is = fileURL.openStream();
         try
         {
            Unmarshaller unmarshaller = UnmarshallerFactory.newInstance().newUnmarshaller();
            unmarshaller.setValidation(true);
            unmarshaller.setSchemaValidation(true);
            unmarshaller.setEntityResolver(new JBossWSEntityResolver());
            ObjectModelFactory factory = new HandlerChainsObjectFactory();
            handlerChainsMetaData = (UnifiedHandlerChainsMetaData)unmarshaller.unmarshal(is, factory, null);
         }
         finally
         {
            is.close();
         }

      }
      catch (RuntimeException rte)
      {
         throw rte;
      }
      catch (Exception ex)
      {
         throw new WSException("Cannot process handler chain: " + filename, ex);
      }

      return handlerChainsMetaData;
   }
View Full Code Here

         return returnType;
      }
      catch (SecurityException e)
      {
         throw new WSException("Unexpected security exception: " + e.getMessage(), e);
      }
      catch (NoSuchMethodException e)
      {
         return null;
      }
View Full Code Here

            }
         }
      }

      if (webMethodCount == 0)
         throw new WSException("No exposable methods found");
   }
View Full Code Here

            {
               IOUtils.copyStream(out, s.getInputStream());
            }
            catch (IOException e)
            {
               throw new WSException("Failed to convert " + obj.getClass());
            }
         }
         else
         {
            throw new WSException("Unable to convert " + obj.getClass());
         }
      }
View Full Code Here

            }
            converted = out.toString();
         }
         catch (IOException e)
         {
            throw new WSException("Failed to convert java.lang.String");
         }

         return converted;
      }
View Full Code Here

            {
               out.write(s.getBytes("UTF-8"));
            }
            catch (IOException e)
            {
               throw new WSException("Failed to convert " + obj.getClass());
            }
         }
         else
         {
            throw new WSException("Unable to convert " + obj.getClass());
         }
      }
View Full Code Here

            converted = baos.toByteArray();
         }
         catch (IOException e)
         {
            throw new WSException("Failed to convert byte[]");
         }

         return converted;
      }
View Full Code Here

TOP

Related Classes of org.jboss.ws.WSException

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.