Added invalid view exception
Added view factory