Beispiel #1
0
        private AbstractSmellPanel SelectPanel()
        {
            AbstractSmellPanel panel = null;

            if (cmbSmells.SelectedItem.Equals("Long Methods"))
            {
                panel = new LongMethodPanel();
            }
            else if (cmbSmells.SelectedItem.Equals("Message Chains"))
            {
                panel = new MessageChainsPanel();
            }
            else if (cmbSmells.SelectedItem.Equals("Temporary Field"))
            {
                panel = new TemporaryFieldPanel();
            }
            else if (cmbSmells.SelectedItem.Equals("Switch Statements"))
            {
                panel = new SwitchStatementsPanel();
            }
            else if (cmbSmells.SelectedItem.Equals("PIH"))
            {
                panel = new ParallelInheritanceHierarchyPanel();
            }
            else if (cmbSmells.SelectedItem.Equals("Hack"))
            {
                panel = new HackPanel();
            }
            return(panel);
        }
Beispiel #2
0
		private AbstractSmellPanel SelectPanel()
		{
			AbstractSmellPanel panel = null;
			if( cmbSmells.SelectedItem.Equals( "Long Methods" ) )
			{
				panel = new LongMethodPanel();
			}
			else if( cmbSmells.SelectedItem.Equals( "Message Chains" ) )
			{
				panel = new MessageChainsPanel();
			}
			else if( cmbSmells.SelectedItem.Equals( "Temporary Field" ) )
			{
				panel = new TemporaryFieldPanel();
			}
			else if( cmbSmells.SelectedItem.Equals( "Switch Statements") )
			{
				panel = new SwitchStatementsPanel();
			}
			else if( cmbSmells.SelectedItem.Equals( "PIH") )
			{
				panel = new ParallelInheritanceHierarchyPanel();
			}
			else if( cmbSmells.SelectedItem.Equals( "Hack") )
			{
				panel = new HackPanel();
			}
			return panel;
		}