if (editor == null && editor.getSite() != null) return;  IWorkbenchPage page= editor.getSite().getPage(); if (page != null)
IWorkbenchPartSite site; IWorkbenchPage page; if (editor != null && (site = editor.getSite()) != null && (page = site.getPage()) != null)
	public static void closeEditor(IEditorPart editor) {		if (editor == null && editor.getSite() != null)			return;				IWorkbenchPage page= editor.getSite().getPage();		if (page != null)			page.closeEditor(editor, false);	}