var Error = {
    Show1: function( title, content )
    {
        alert(title + "\r\n" + content);
    },
    Show2: function( title, content )
    {
        CreateContentMessage( title, content );
        LeftPannel.SetError2();
        if( LeftPannel.IsUnansweredLinksExists() )
        {
            CreateButtons([{
                text: "Перейти к следующему заданию",
                handler: function(){ LeftPannel.NextTask(); }
            }]);
        }
    },
    Show3: function( title, content )
    {
        CreateContentMessage( title, content );
        LeftPannel.SetError3();
    },
    Show: function( oError )
    {
        var iLevel = this.GetLevel(oError);
        var sTitle = oError.getAttribute('title');
        var sContent = oError.getAttribute('content');
        
        switch( iLevel )
        {
            case 1:
                this.Show1( sTitle, sContent );
                break;
            case 2:
                this.Show2( sTitle, sContent );
                break;
            case 3:
                this.Show3( sTitle, sContent );
                break;
        }
        
    },
    
    GetLevel: function( oError )
    {
        return parseInt(oError.getAttribute('level'));
    }
};