If it expects four digits, then its input cannot be in the form of an int. It must be a string. The number of decimal digits has no meaning in the 'int' type - it's not natively an decimal type. (It's actually a 32-digit binary type. It's just that C# lets you specify numeric constants as decimal text for convenience - nobody wants to type a 32-digit binary number...)
You say your "my method accepts integers onli", but that contradicts what you say here: "it accepts only 4 digits in the Year field"
One of those statements must be untrue. The 'int' type in C# and also Java (presumably Java is somehow involved if you have a JAR file) doesn't have any mechanism for representing leading zeroes.
So if your method only accepts integers, then by definition it can't care about leading zeroes because the 'int' type doesn't actually support that concept. And if your method accepts only 4 digits, then by defintion the data you're passing it can't be an 'int' because if it was, it wouldn't be able to tell whether there was a leading digit or not.
As far as the 'int' type is concerned, 999, 0999, 0000999, 0x3E7, and 0x00003E7 are all exactly the same thing. These different textual representations are completely indistingiushable in an 'int' because they all have the same binary representation: 0000001111100111.
Note that the leading zeroes are always present in the underlying representation. 'int' is 32-bits. If the number you wish to represnet doesn't need all 32 bits, the leading digits are all 0. That's why you can't add them - they're already there, whether you specified them or not.
Since you are going to have to sort the digits that make up the numbers it's easier to convert them to strings, manipulate the digits then convert them back to numbers. With the conversion to string you can specify that it have leading zeros, so that will make it easy.