MrLoick / staff

Automatically exported from code.google.com/p/staff
Apache License 2.0
0 stars 0 forks source link

Generate wsdl namespace error #185

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
What steps will reproduce the problem?
1. The file "device_alarm.h" as follow:
#include "device.h"

namespace cspws
{
namespace csp
{
namespace device
{
   struct AlarmControl
  {
    enum Type
    {
      DISARMED = 1,
      ARMED_OUT = 2,
      ARMED_STAY = 3,
      BYPASS = 6,
      SHOW_INVALID_DEF_AREA = 10
    };
    unsigned long id; 
    Type type; 
}
}
}
2.staff_codegen -u -twsdl -cinclude device_alarm.h
3.the wsdl file as follow:
<schema
    xmlns="http://www.w3.org/2001/XMLSchema"
    xmlns:ns_cspws_csp_device="http://tempui.org/cspws.csp.device"
    targetNamespace="http://tempui.org/cspws.csp.device"
    xmlns:ns_cspws_csp_device="http://tempui.org/cspws.csp.device"
    xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"
    xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/">

      <!-- imports -->
      <import namespace="http://tempui.org/cspws.csp.device" schemaLocation="cspws.csp.device.device.xsd" />

<element name="type" type="ns_cspws_csp_device:AlarmControl.Type">

What is the expected output? What do you see instead?
(1)The namespace should be cspws.csp.device.alarm
The Lines Should be:
xmlns:ns_cspws_csp_device_alarm="http://tempui.org/cspws.csp.device.alarm"
targetNamespace="http://tempui.org/cspws.csp.device.alarm"

<element name="type" type="ns_cspws_csp_device_alarm:AlarmControl.Type">

What version of the product are you using? On what operating system?

r709, windows xp

Please provide any additional information below.

Original issue reported on code.google.com by bingqing...@gmail.com on 8 Sep 2012 at 7:30

GoogleCodeExporter commented 8 years ago
Please attach you device_alarm.h and device.h

Original comment by loentar on 18 Sep 2012 at 9:56

GoogleCodeExporter commented 8 years ago
As I see generated namespace is right.

Original comment by loentar on 19 Apr 2013 at 1:24

Attachments: