New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

sub-setter

Package Overview
Dependencies
Maintainers
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

sub-setter

0.0.2
Rubygems
Version published
Maintainers
1
Created
Source

SubSetter Pattern implementation for Ruby

As described in SubSetter Pattern for Ruby.

Installation

Not yet

This implementation creates

  • The SubSetter Module, containing three methods (and three more aliases) that are included into Object.
  • The SubSetter::Object Class, implementation (empty right now) of a generic subsetter for Object.

New methods in Object

Public

  • subsetter: returns an instance of the designated subsetter for the class of this instance.
  • _subsetter, by and filter: aliases for subsetter. by and filter are added for legibility, and _subsetter in the remote case that all other method names are overriden, in order to not jeopardize the subsetting functionality

_subsetter is the recommended form to be used when developing a library on top of the sub-setter gem.

Private

  • _subsetter_for(Class): returns an instance of the designated subsetting class for the given Class
  • _has_subsetter_for(Class): returns true if for the passed class a corresponding subsetter class exists, false otherwise

License

GPL

FAQs

Package last updated on 06 Apr 2012

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts