Alternative to c# User-Defined Conversions in Java
<p>Is there something like <a href="http://msdn.microsoft.com/en-us/library/aa288476%28v=vs.71%29.aspx" rel="nofollow">User-Defined conversions</a> in Java or any suggestion on how can I acchive same effect in java without adding tens of <code>.toXXXX</code> methods</p>

<p>I haven't used c# for a while so I can't remember right name for it but I also remember that in c# I was able to pass first parameter to function without using notation</p>

<pre><code>Foo(MyClass instance)
</code></pre>

<p>but rather</p>

<pre><code>instance.Foo()
</code></pre>

<p>If I remember correctly I had to use this keyword before MyClass something like <code>Foo(this MyClass instance)</code> but as I said I haven't used c# for a while so I cant remember</p>

<p>Can anyone tell me what are the alternatives to this two "methods" in Java</p>
