Now, I can obviously make that code more reusable by defining a
Trait-- such asTranslate-- with a default method implementation similar to what's above.
Can you? That default implementation can't assume the existence of the translation field.
Now, I can obviously make that code more reusable by defining a
Trait-- such asTranslate-- with a default method implementation similar to what's above.
Can you? That default implementation can't assume the existence of the translation field.