norisatir/go-dbus — pull request #5 by bmatsuo (2012-01-11 13:53:16+00:00)
Title: Message cleanup

This does various things to improve the Message interface.

- The MessageType and MessageFlag constants are properly typed (no longer int types). This wasn't causing problems. But, it's cleaner and it formats the `godoc` documentation better.
- The MessageType and MessageFlag constant names are more idiomatic Go names. The MessageType names are prefixed with "Type" (to be more explicit and to avoid naming conflicts). The MessageFlag names have not been prefixed. They seem unambiguous enough to me. Any thoughts about that?
- The MessageType now uses method String, instead of _ToString. This is more idiomatic Go. It also allows fmt.Printf to format it better with the flag "%v".
- The Message type's field, Type, is now a MessageType. This speeds up comparison operations. It's also a little clearer than the previous string-based approach (not that it was overly complicated before).

I'm always open to feedback. Let me know what you think

Bryan