Constructor with type of calling instance.