Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings
Discussion options

Sorry, I'm new to using MessagePack, so maybe this is obvious, but my searches haven't found anything.

Using AllowPrivate doesn't make any difference. When I have any class with private or internal set, VS reports that this is a partial class. It looks like that may work, but I want to make sure that's the right thing to do.

[MessagePackObject(keyAsPropertyName: true, AllowPrivate = true)]
public class LocationData
{                
    public List<double> xValues { get; private set; }       
    public List<double> yValues { get; private set; }        
    public List<double> zValues { get; private set; }
 }

CS0260: Missing partial modifier on declaration of type; another partial declaration of this type exists

Thanks!

You must be logged in to vote

Replies: 1 comment

Comment options

Please apply this change to your code:

 [MessagePackObject(keyAsPropertyName: true, AllowPrivate = true)]
-public class LocationData
+public partial class LocationData
 {                
    public List<double> xValues { get; private set; }       
    public List<double> yValues { get; private set; }        
    public List<double> zValues { get; private set; }
 }
You must be logged in to vote
0 replies
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants
Morty Proxy This is a proxified and sanitized view of the page, visit original site.