Update str.h

Changes in APIs. Needs test!