Skip to end of metadata
Go to start of metadata

<ac:macro ac:name="unmigrated-inline-wiki-markup"><ac:plain-text-body><![CDATA[

<ac:macro ac:name="unmigrated-inline-wiki-markup"><ac:plain-text-body><![CDATA[

Zend Framework: Zend_Service_Trim Component Proposal

Proposed Component Name Zend_Service_Trim
Developer Notes http://framework.zend.com/wiki/display/ZFDEV/Zend_Service_Trim
Proposers Sudheer Satyanarayana
Zend Liaison TBD
Revision 1.0 - 1 November 2009: Initial Draft. (wiki revision: 21)

Table of Contents

1. Overview

Zend_Service_Trim implements the tr.im API. It allows you to create short URLs. The component also provides convenient methods to access other features of tr.im.

2. References

3. Component Requirements, Constraints, and Acceptance Criteria

  • This component will support trim_url, trim_simple, trim_reference, trim_claim, trim_destination, url_visits, account_urls, account_visits, verify, shorteners, shorten and expand API methods
  • This component will not support pic.im API in the initial release
  • This component will allow subclassing
  • This component will validate input data against formats supported by ZF component Zend_Uri.
  • This component will not save any data using Zend_Cache or the filesystem. The user is responsible to manage the data storage in their applications.

4. Dependencies on Other Framework Components

  • Zend_Exception
  • Zend_Http_Client

5. Theory of Operation

6. Milestones / Tasks

  • Milestone 1: [DONE] complete writing this proposal
  • Milestone 2: Working prototype checked into the incubator supporting use cases #1 and #2
  • Milestone 3: Unit tests exist, work, and are checked into SVN.
  • Milestone 4: Initial documentation exists.

7. Class Index

  • Zend_Service_Trim_Exception
  • Zend_Service_Trim

8. Use Cases

If you have to print URLs to your users, URL shortening is the way to go.

UC-01

Development project like ZF. When an issue is created or updated in your issue tracker, send a notification to your mailing lists and IRC channels. Get a shortened URL of your issue tracker URL and publish them in the IRC channel or mailing list. Hypothetical example
1. Project BizSense issue tracker is hosted by code.google.com. User creates an issue. The issue URL is http://code.google.com/p/bizsense/issues/detail?id=488
2. Create a short url using the Zend_Service_Trim component. The component returns http://tr.im/DNRN
3. In your notification email and IRC message, use http://tr.im/DNRN instead of http://code.google.com/p/bizsense/issues/detail?id=488

UC-02

When posting messages with URLs to twitter, mobile phones, etc, the number of characters play an important role. Almost all desktop Twitter clients out there support shortening the URLs on the fly. Use Zend_Service_Trim in your twitter clients.

9. Class Skeletons

]]></ac:plain-text-body></ac:macro>

]]></ac:plain-text-body></ac:macro>

Labels:
None
Enter labels to add to this page:
Please wait 
Looking for a label? Just start typing.
  1. Nov 19, 2009

    <p>At the time of writing the proposal, I did not know about the Zend_Service_ShortenUrl interface being developed. tr.im service can be an adapter to Zend_Service_ShortenUrl component.</p>

    <p>See <a class="external-link" href="http://framework.zend.com/wiki/display/ZFPROP/Zend_Service_ShortenUrl+-+Martin+Hujer">http://framework.zend.com/wiki/display/ZFPROP/Zend_Service_ShortenUrl+-+Martin+Hujer</a></p>

    1. Aug 03, 2010

      <p>May this proposal RIP <ac:emoticon ac:name="smile" /></p>

  2. Aug 03, 2010

    <p><a href="http://tr.im/">tr.im R.I.P.</a></p>

  3. Feb 07, 2011

    <p>Archiving this proposal, feel free to recover it when you want to work on it again. For more details see <a href="http://framework.zend.com/wiki/display/ZFDEV/Archiving+of+abandoned+proposals+(Feb+5+2011)">this email</a>.</p>