@Test public void testEquals() { ViewInfo vi = new ViewInfo(TestView.class, "tv", ViewType.INSPECTOR); ViewInfo vi2 = new ViewInfo(OtherTestView.class, "tv", ViewType.LAYOUT); Assert.assertTrue (vi.equals(new ViewInfo(TestView.class, "tv", ViewType.INSPECTOR))); Assert.assertTrue (vi.equals(new ViewInfo(TestView.class, "tv", ViewType.CENTER))); Assert.assertFalse(vi.equals(vi2)); Assert.assertFalse(vi.equals(null)); Assert.assertFalse(vi.equals(Integer.valueOf(7))); }
@Override public boolean equals(Object obj) { return obj instanceof ViewInfo && ((ViewInfo)obj).getType().equals(getType()) && ((ViewInfo)obj).getPreferredComponentType() == preferredComponentType; }
ViewInfo extends TypeInfo<View> { @Override public boolean equals(Object obj) { return obj instanceof ViewInfo && ((ViewInfo)obj).getType().equals(getType()) && ((ViewInfo)obj).getPreferredComponentType() == preferredComponentType; } }
ViewInfo extends TypeInfo<View> { @Override public boolean equals(Object obj) { return obj instanceof ViewInfo && ((ViewInfo)obj).getType().equals(getType()) && ((ViewInfo)obj).getPreferredComponentType() == preferredComponentType; } ViewInfo(Class<? extends View> aViewClass, String viewName, ViewType viewType);  ViewInfo(Class<? extends View> aViewClass, String name, String aType, ViewType viewType); @Deprecated  ViewInfo(Class<? extends View> aViewClass, String name, ViewType viewType, javax.swing.ImageIcon icon); @Deprecated  ViewInfo(Class<? extends View> aViewClass, String name, String aType, ViewType viewType, javax.swing.ImageIcon icon); @Deprecated  ViewInfo(Class<? extends View> aViewClass, String name, String aType, ViewType viewType, javax.swing.ImageIcon icon, javax.swing.ImageIcon selectedIcon);  ViewInfo(Class<? extends View> aViewClass, String name, String aType, ViewType viewType, boolean shouldExpandCenterPaneInWindow, Class<? extends AbstractComponent> preferredComponentType); @Deprecated  ViewInfo(Class<? extends View> aViewClass, String name, String aType, ViewType viewType, javax.swing.ImageIcon icon, javax.swing.ImageIcon selectedIcon, boolean shouldExpandCenterPaneInWindow, Class<? extends AbstractComponent> preferredComponentType); }
ViewInfo extends TypeInfo<View> { @Override public boolean equals(Object obj) { return obj instanceof ViewInfo && ((ViewInfo)obj).getType().equals(getType()) && ((ViewInfo)obj).getPreferredComponentType() == preferredComponentType; } ViewInfo(Class<? extends View> aViewClass, String viewName, ViewType viewType);  ViewInfo(Class<? extends View> aViewClass, String name, String aType, ViewType viewType); @Deprecated  ViewInfo(Class<? extends View> aViewClass, String name, ViewType viewType, javax.swing.ImageIcon icon); @Deprecated  ViewInfo(Class<? extends View> aViewClass, String name, String aType, ViewType viewType, javax.swing.ImageIcon icon); @Deprecated  ViewInfo(Class<? extends View> aViewClass, String name, String aType, ViewType viewType, javax.swing.ImageIcon icon, javax.swing.ImageIcon selectedIcon);  ViewInfo(Class<? extends View> aViewClass, String name, String aType, ViewType viewType, boolean shouldExpandCenterPaneInWindow, Class<? extends AbstractComponent> preferredComponentType); @Deprecated  ViewInfo(Class<? extends View> aViewClass, String name, String aType, ViewType viewType, javax.swing.ImageIcon icon, javax.swing.ImageIcon selectedIcon, boolean shouldExpandCenterPaneInWindow, Class<? extends AbstractComponent> preferredComponentType); Class<? extends AbstractComponent> getPreferredComponentType(); Class<? extends View> getViewClass(); String getType(); String getViewName(); ViewType getViewType(); @Override int hashCode(); @Override boolean equals(Object obj); @Override String toString(); View createView(final AbstractComponent component); @Deprecated javax.swing.ImageIcon getIcon(); @Deprecated javax.swing.ImageIcon getSelectedIcon(); boolean shouldExpandCenterPaneInWindow(); }
ViewInfo extends TypeInfo<View> { @Override public boolean equals(Object obj) { return obj instanceof ViewInfo && ((ViewInfo)obj).getType().equals(getType()) && ((ViewInfo)obj).getPreferredComponentType() == preferredComponentType; } ViewInfo(Class<? extends View> aViewClass, String viewName, ViewType viewType);  ViewInfo(Class<? extends View> aViewClass, String name, String aType, ViewType viewType); @Deprecated  ViewInfo(Class<? extends View> aViewClass, String name, ViewType viewType, javax.swing.ImageIcon icon); @Deprecated  ViewInfo(Class<? extends View> aViewClass, String name, String aType, ViewType viewType, javax.swing.ImageIcon icon); @Deprecated  ViewInfo(Class<? extends View> aViewClass, String name, String aType, ViewType viewType, javax.swing.ImageIcon icon, javax.swing.ImageIcon selectedIcon);  ViewInfo(Class<? extends View> aViewClass, String name, String aType, ViewType viewType, boolean shouldExpandCenterPaneInWindow, Class<? extends AbstractComponent> preferredComponentType); @Deprecated  ViewInfo(Class<? extends View> aViewClass, String name, String aType, ViewType viewType, javax.swing.ImageIcon icon, javax.swing.ImageIcon selectedIcon, boolean shouldExpandCenterPaneInWindow, Class<? extends AbstractComponent> preferredComponentType); Class<? extends AbstractComponent> getPreferredComponentType(); Class<? extends View> getViewClass(); String getType(); String getViewName(); ViewType getViewType(); @Override int hashCode(); @Override boolean equals(Object obj); @Override String toString(); View createView(final AbstractComponent component); @Deprecated javax.swing.ImageIcon getIcon(); @Deprecated javax.swing.ImageIcon getSelectedIcon(); boolean shouldExpandCenterPaneInWindow();  }