Base64 encoder/decoder and tests

As described in the draft 21, section 2 of JWT, the Base64 string should
be safe and trailing = have to be omitted

(http://tools.ietf.org/html/draft-ietf-oauth-json-web-token-21#section-2).

- Base64 class added to encode and decode according to the
draft
- Tests added: test coverage is now 100%
- Test added to verify that old token will be correctly loaded
- Moved isExpired method from JWS to JWT
- constructors modified to use setHeader and setPayload methods