Details

    • Type: New Feature New Feature
    • Status: Resolved Resolved
    • Priority: Minor Minor
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 0.6
    • Component/s: Boo.Lang.Useful
    • Labels:
      None
    • Number of attachments :
      6

      Description

      An attribute that automates the Singleton design pattern; seals the class, generates the "instance" property, thread-safe, and hides the constructors.

      1. SingletonAttribute.boo
        6 kB
        Sorin Ionescu
      2. SingletonAttribute.patch
        10 kB
        Sorin Ionescu
      3. SingletonAttribute.patch
        14 kB
        Sorin Ionescu
      4. SingletonAttribute.patch
        6 kB
        Arron Washington
      5. SingletonAttributeTest.boo
        2 kB
        Sorin Ionescu
      6. SingletonAttributeTest.patch
        3 kB
        Arron Washington

        Activity

        Hide
        Sorin Ionescu added a comment -
        • Simplified the code.
        • Added a private variable for lock to lock on.
        • Removed vertical allignment of fields/operators.
        • Other small fixes.

        Hopefully, It won't require anymore changes.

        Show
        Sorin Ionescu added a comment - Simplified the code. Added a private variable for lock to lock on. Removed vertical allignment of fields/operators. Other small fixes. Hopefully, It won't require anymore changes.
        Hide
        Sorin Ionescu added a comment -

        I have completely removed vertical alignment. The code looks like the Boo samples Rodrigo writes.

        Show
        Sorin Ionescu added a comment - I have completely removed vertical alignment. The code looks like the Boo samples Rodrigo writes.

          People

          • Assignee:
            Rodrigo B. de Oliveira
            Reporter:
            Arron Washington
          • Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: