I think the cleanest solution is, as some others have suggested is to create a ClientId class. I don't think this is necessarily bad, as this post explains in a pretty good way:
Many classes have a tendency to consume or expose primitive values
like integers and strings. While such primitive types exist on any
platform, they tend to lead to procedural code. Furthermore they often
break encapsulation by allowing invalid values to be assigned.
Having a seperate class gives you different sorts of possibilities to validate the the id as well, if that is a requirement. In the end, it is all about encapsulation.
Something like this should get you started:
//auto-property for your class
public ClientId ClientID
{
get; set;
}
And the ClientId class:
public class ClientId
{
private int _id;
public ClientId(int id) { _id = id; }
public ClientId(string id) { //convert id to int, throw exception if invalid }
public int Value { return _id; }
}
Don't forget to implement Equals and GetHashCode as well, which can be done trivially for this class.