Skip to content

Commit

Permalink
updating readme
Browse files Browse the repository at this point in the history
  • Loading branch information
imonroe committed Apr 22, 2018
1 parent e18177b commit 90aefc0
Showing 1 changed file with 2 additions and 8 deletions.
10 changes: 2 additions & 8 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,16 +1,10 @@
# crps

[![Latest Version on Packagist][ico-version]][link-packagist]
[![Build Status][ico-travis]][link-travis]
[![Coverage Status][ico-scrutinizer]][link-scrutinizer]
[![Quality Score][ico-code-quality]][link-code-quality]
[![Total Downloads][ico-downloads]][link-downloads]

CRPS is the Coldreader Persistent Storage system. On its own, you may not find it very useful; it doesn't have any front-end information in it at all. For a working implementation, please [install the full Coldreader project.](https://github.com/imonroe/coldreader)
CRPS is the Coldreader Persistent Storage system. On its own, you may not find it very useful; it doesn't have any front-end information in it at all. For a working, real-world implementation, please [install the full Coldreader project.](https://github.com/imonroe/coldreader)

CRPS is designed to be a databasing system for when you don't know in advance what kind of information you want to store. It implments a data model where you have a bunch of arbitrary subjects, each of which has an arbitrary number of Aspects.

Aspects can be thought of as some kind of fact or content that is relevant to its Subject. Aspect data is stored in the database as text, in the broad sense. JSON counts as text, for instance, as do hyperlinks, markup, etc. In addition to storing data, Aspects can be purely functional--a call to an external API, a web scraper to grab a bit of content from elsewhere, and so forth. Each type of Aspect has a display method that produces the markup for use in templates. Additionally, each type of Aspect also has a parse() function that it automatically called by a scheduled task once every five minutes. From this function, an Aspect may perform actions on the data model; updating its own value, or creating/updating other Subjects or Aspects.
Aspects can be thought of as some kind of fact or content that is relevant to its Subject. Aspect data is stored in the database as text, in the broad sense. JSON counts as text, for instance, as do hyperlinks, markup, etc. In addition to storing data, Aspects can be purely functional--a call to an external API, a web scraper to grab a bit of content from elsewhere, and so forth. Each type of Aspect has a display method that produces the markup for use in templates. Additionally, each type of Aspect also has a parse() function which can be called automatically by scheduled jobs. From this function, an Aspect may perform actions on the data model; fetching new data from an external source, updating its own value, or creating/updating other Subjects or Aspects.

New Aspect Types are easy and quick to build. Upon creation, the new Aspect Type will automatically add new boilerplate code for the necessary GUI forms (via the Laravel Collective Form API) and override methods; an Aspect Type definition is an OOP child class of the parent Aspect Type and inherits its methods. Custom Aspect Types can also be child classes of other custom Aspect Types, so if you build an APIResultsAspect class, you can make a FacebookAPIResultsAspect class that inherits the work you've already done for APIResultsAspect, for instance.

Expand Down

0 comments on commit 90aefc0

Please sign in to comment.