Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/yugui/ioable
A library to help you to implement IO-like objects
https://github.com/yugui/ioable
Last synced: 26 days ago
JSON representation
A library to help you to implement IO-like objects
- Host: GitHub
- URL: https://github.com/yugui/ioable
- Owner: yugui
- Created: 2012-07-16T10:17:27.000Z (over 12 years ago)
- Default Branch: master
- Last Pushed: 2012-09-27T02:49:25.000Z (about 12 years ago)
- Last Synced: 2023-04-11T17:16:04.104Z (over 1 year ago)
- Language: Ruby
- Size: 156 KB
- Stars: 11
- Watchers: 4
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.rd
- Changelog: History.txt
Awesome Lists containing this project
README
= ioable
* http://github.com/yugui/ioable
== DESCRIPTION:
IOable helps you to implement IO-like class.
Sometimes you need to write a IO-like object, e.g. StringIO or a network
protocol wrapper. But IO has many methods to implement. So this library implies
those methods from a limited number of basic methods.== FEATURES/PROBLEMS:
-- IOable
All-in-one module to define the methods.-- IOable::CharInput
Wrapper class to define character-wise, line-wise and encoding-aware input
methods from byte-wide input methods.-- IOable::CharOutput
Ditto, but for outputs.== SYNOPSIS:
require 'ioable'
class YourCharacterStream
include IOabledef getc
# ...
end
def syswrite(buf)
# ...
end
end== INSTALL:
% gem install ioable
== LICENSE:
(The MIT License)
Copyright (c) 2010 FIXME full name
Permission is hereby granted, free of charge, to any person obtaining
a copy of this software and associated documentation files (the
'Software'), to deal in the Software without restriction, including
without limitation the rights to use, copy, modify, merge, publish,
distribute, sublicense, and/or sell copies of the Software, and to
permit persons to whom the Software is furnished to do so, subject to
the following conditions:The above copyright notice and this permission notice shall be
included in all copies or substantial portions of the Software.THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND,
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.