Jump to content
OpenSplice DDS Forum

Search the Community

Showing results for tags 'array'.

More search options

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


  • About OpenSplice DDS
    • News and Events
    • Site Feedback
  • Using OpenSplice DDS
    • General
    • Troubleshooting
  • Understanding OpenSplice DDS
    • OpenSplice DDS Slideshows
    • OpenSplice DDS Movies
  • Community
    • Project: SIMD
    • Project: CamelOS
    • Project: DDS Touchstone
    • Project: RESTful DDS
    • Mac OS X


  • Community Calendar

Found 1 result

  1. Using: VortexOpenSplice-6.7.170912OSS-HDE-x86_64.win-vs2015 I've received some IDL that utilizes sequence<char> for passing strings (rather than char[] or string); it appears that in C# this doesn't actually pass the value through. (Note that this works fine in C++) This can be easily reproduced in the HelloWorld sample as follows: Change the HelloWorldData.idl: Replace: string message; With: sequence<char,16> message; Change the HellowWorldDataPublisher.cs: Replace: msgInstance.message = "Hello World"; With: string str = "Hello World"; char[] array = new char[16]; Array.Copy(str.ToCharArray(), array, str.Length); msgInstance.message = array; Run the HelloWorld sample app and you'll see that the received message in the HelloWorldDataSubscriber has no content (is of length 0) Note that in the IDL if you use a char<16> rather than a sequence<char,16> it works as expected and you get the "Hello World" in the subscriber. Can you please advise on whether this is a usage problem, code generation problem or something else? (and if there's a workaround short of changing the IDL) Thank you very much.