Factory was made generic
Added check if annotation is presented
Added simple maven configuration for project