old methods to new methods

newField() -> addField()
datatype() -> type()