public Open construct(Object underlying)
{
if(underlying instanceof List)
{
List list = (List) underlying;
Open obj = new Open();
int position = 0;
final int size = list.size();
if(position < size)
{
Object val = list.get(position);
position++;
if(val != null)
{
try
{
obj.setContainerId( (String) val );
}
catch(ClassCastException e)
{
// TODO Error
}
}
}
else
{
return obj;
}
if(position < size)
{
Object val = list.get(position);
position++;
if(val != null)
{
try
{
obj.setHostname( (String) val );
}
catch(ClassCastException e)
{
// TODO Error
}
}
}
else
{
return obj;
}
if(position < size)
{
Object val = list.get(position);
position++;
if(val != null)
{
try
{
obj.setMaxFrameSize( (UnsignedInteger) val );
}
catch(ClassCastException e)
{
// TODO Error
}
}
}
else
{
return obj;
}
if(position < size)
{
Object val = list.get(position);
position++;
if(val != null)
{
try
{
obj.setChannelMax( (UnsignedShort) val );
}
catch(ClassCastException e)
{
// TODO Error
}
}
}
else
{
return obj;
}
if(position < size)
{
Object val = list.get(position);
position++;
if(val != null)
{
try
{
obj.setIdleTimeOut( (UnsignedInteger) val );
}
catch(ClassCastException e)
{
// TODO Error
}
}
}
else
{
return obj;
}
if(position < size)
{
Object val = list.get(position);
position++;
if(val != null)
{
if (val instanceof Symbol[] )
{
obj.setOutgoingLocales( (Symbol[]) val );
}
else
{
try
{
obj.setOutgoingLocales( new Symbol[] { (Symbol) val } );
}
catch(ClassCastException e)
{
// TODO Error
}
}
}
}
else
{
return obj;
}
if(position < size)
{
Object val = list.get(position);
position++;
if(val != null)
{
if (val instanceof Symbol[] )
{
obj.setIncomingLocales( (Symbol[]) val );
}
else
{
try
{
obj.setIncomingLocales( new Symbol[] { (Symbol) val } );
}
catch(ClassCastException e)
{
// TODO Error
}
}
}
}
else
{
return obj;
}
if(position < size)
{
Object val = list.get(position);
position++;
if(val != null)
{
if (val instanceof Symbol[] )
{
obj.setOfferedCapabilities( (Symbol[]) val );
}
else
{
try
{
obj.setOfferedCapabilities( new Symbol[] { (Symbol) val } );
}
catch(ClassCastException e)
{
// TODO Error
}
}
}
}
else
{
return obj;
}
if(position < size)
{
Object val = list.get(position);
position++;
if(val != null)
{
if (val instanceof Symbol[] )
{
obj.setDesiredCapabilities( (Symbol[]) val );
}
else
{
try
{
obj.setDesiredCapabilities( new Symbol[] { (Symbol) val } );
}
catch(ClassCastException e)
{
// TODO Error
}
}
}
}
else
{
return obj;
}
if(position < size)
{
Object val = list.get(position);
position++;
if(val != null)
{
try
{
obj.setProperties( (Map) val );
}
catch(ClassCastException e)
{
// TODO Error