خرید بک لینک

Vote count: 0

I have a bunch of classes and I want their string representation to have symbols in it, unfortunately I can't put symbols in their class names so i've been using .replaces to edit this.

e.g.

" " + getClass().getSimpleName().replace("Flat", "_b").replace("Sharp", "_#");

However, I think it would be more eloquent if I could just override the getSimpleName method inside each class. Unfortunately this retus an error:

@Override
public String getSimpleName() {

    retu "Dorian_b2";
}

on the @Override line because the method is not in the super class. If I remove the @Override line, the function is not called.

Thanks in advance. :)

asked 1 min ago

برچسب: نویسنده: استخدام کار تاريخ: شنبه 9 مرداد 1395 ساعت: 11:40

صفحه بندی