You are viewing a plain text version of this content. The canonical link for it is here.
Posted to c-dev@axis.apache.org by "Fred Preston (JIRA)" <ax...@ws.apache.org> on 2005/09/28 11:01:47 UTC

[jira] Created: (AXISCPP-836) Generated stubs of array types have additional overloaded constructor in which you pass the size of the array to be created.

Generated stubs of array types have additional overloaded constructor in which you pass the size of the array to be created.
----------------------------------------------------------------------------------------------------------------------------

         Key: AXISCPP-836
         URL: http://issues.apache.org/jira/browse/AXISCPP-836
     Project: Axis-C++
        Type: Improvement
  Components: Client - Stub  
 Environment: n/a
    Reporter: Fred Preston
    Priority: Minor


>From a user perspective, it would be good to get the generated stubs of array types to have an additional overloaded constructor in which you pass the size of the array to be created.  For example:-

For a string array:-

stringArrayType::stringArrayType( int iSize)
{
    stringItem.m_Size = iSize;

    stringItem.m_Array = new xsd__string [iSize];

    for( int iIndex = 0; iIndex < iSize; iIndex++)
    {
        stringItem.m_Array[iIndex] = "";
    }
}

Or/And:

longArrayType::longArrayType( int iSize)
{
    longItem.m_Size = iSize;

    longItem.m_Array = (xsd__long **) new xsd__long * [iSize];

    for( int iIndex = 0; iIndex < iSize; iIndex++)
    {
        longItem.m_Array[iIndex] = new xsd__long();
        *longItem.m_Array[iIndex] = (xsd__long) 0;
    }
}

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


[jira] Updated: (AXISCPP-836) Generated stubs of array types have additional overloaded constructor in which you pass the size of the array to be created.

Posted by "Chinthana Danapala (JIRA)" <ax...@ws.apache.org>.
     [ http://issues.apache.org/jira/browse/AXISCPP-836?page=all ]

Chinthana Danapala updated AXISCPP-836:
---------------------------------------

    Attachment: BeanParamWriter.java
                ParmHeaderFileWriter.java

I have able to generate the constructor as requested by modifying BeanParamWriter.java and ParmHeaderFileWriter.java classes. I have attached the modified files for literal type. But I get failing following tests. 

ExtensibilityQuery 
NestedComplex 
UnboundedChoice 
UnboundedStringChoice 


> Generated stubs of array types have additional overloaded constructor in which you pass the size of the array to be created.
> ----------------------------------------------------------------------------------------------------------------------------
>
>          Key: AXISCPP-836
>          URL: http://issues.apache.org/jira/browse/AXISCPP-836
>      Project: Axis-C++
>         Type: Improvement
>   Components: Client - Stub
>  Environment: n/a
>     Reporter: Fred Preston
>     Priority: Minor
>  Attachments: BeanParamWriter.java, ParmHeaderFileWriter.java
>
> From a user perspective, it would be good to get the generated stubs of array types to have an additional overloaded constructor in which you pass the size of the array to be created.  For example:-
> For a string array:-
> stringArrayType::stringArrayType( int iSize)
> {
>     stringItem.m_Size = iSize;
>     stringItem.m_Array = new xsd__string [iSize];
>     for( int iIndex = 0; iIndex < iSize; iIndex++)
>     {
>         stringItem.m_Array[iIndex] = "";
>     }
> }
> Or/And:
> longArrayType::longArrayType( int iSize)
> {
>     longItem.m_Size = iSize;
>     longItem.m_Array = (xsd__long **) new xsd__long * [iSize];
>     for( int iIndex = 0; iIndex < iSize; iIndex++)
>     {
>         longItem.m_Array[iIndex] = new xsd__long();
>         *longItem.m_Array[iIndex] = (xsd__long) 0;
>     }
> }

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira