Robert McGovern (duemoko) wrote in lj_clients,
Robert McGovern
duemoko
lj_clients

Adding Mode to server response.

I am currently writing a client for LJ in ruby for the heck of learning and more experience of following specs. At the moment I am simply working on the inner core and forgetting about the user interface side of things.

One thing that has come up from testing so far is that the server responses do not include the mode they are for. This would be very useful for determining what should parse the response and would prevent the need to possibly parse the response straight away.

My plan is have a request queue and a response queue and do it that when a response is get from the server it is passed to a method of the Request object (i.e LoginRequest) which will spit out a "proper" response object i.e. LoginResponse or GetFriendsResponse which will then be plopped into the queue to be dealt with at some point.

Does anyone else think a mode entry in the server response would be helpful?
Subscribe
  • Post a new comment

    Error

    Comments allowed for members only

    Anonymous comments are disabled in this journal

    default userpic

    Your reply will be screened

  • 7 comments