我正在尝试添加装饰器(例如,向文件添加后缀)每当在当前打开的文件中单击保存按钮时,我都会搜索但很难弄清楚这是我的代码
public void decorate(Object resource, IDecoration decoration) {
    if () //I'm having trouble with this check
    {
    decoration.addSuffix("--Modified");
    }
    }
帮助将不胜感激
我正在尝试添加装饰器(例如,向文件添加后缀)每当在当前打开的文件中单击保存按钮时,我都会搜索但很难弄清楚这是我的代码
public void decorate(Object resource, IDecoration decoration) {
    if () //I'm having trouble with this check
    {
    decoration.addSuffix("--Modified");
    }
    }
帮助将不胜感激