| DOSE: |
30 mg |
smoked |
DMT |
(powder / crystals) |
I recently acquired a gram of DMT as the result of a rather happy accident. The person who gave it to me gave me an informed, but slightly hyped rundown of the whole experience. Next, I got online to research the substance further. Almost every article I found about what to expect from DMT was filled with accounts of EXTREME INTENSITY and how NOTHING CAN PREPARE YOU FOR THIS EXPERIENCE, etc. etc. Although I had extensive experience with LSD and psilocybin, I must admit I became pretty anxious about the potential dangers of this substance, especially considering the history of schizophrenia/bipolar disorder in my family.
A friend of mine who had more experience with the substance agreed to guide me through the first-time process. I started out with a very small dosage (approximately 15-20mg). Nothing except a very faint physical sensation. About 20 minutes later I tried a larger amount and found myself smack dab in the middle of my first DMT experience.
Wow, how underwhelming. Not bad, mind you, but just nothing like I expected based on what I had read. I was expecting to be instantaneously transported to an alien mother ship speaking in radioactive high-frequency dialects, etc... At least, that's how the trip reports made it out to be.
Nothing could have been farther from the truth. It was simply a rapid thrust into a standard psychedlic state. General visual hallucinations, full-body physical sensations, and rapid-fire thought processes. Intense, sure, I guess... Perhaps only due to how quickly it kicked it, otherwise, it was a totally familiar feeling, based on my experience with other psychoactives.
To make a long story short, DMT is a very nice substance that throws the user into a psychedelic state within seconds of inhaling and fades within 10-15 minutes.
In my opinion, the whole 'EXTREME INTENSITY' side of it is merely how quickly it kicks in. Otherwise, it is an extremely managable and convenient substance for me. Of course, levels of intensity can vary greatly depending on the size of the dosage.
Experience Reports are the writings and opinions of the individual authors who submit them.
Some of the activities described are dangerous and/or illegal and none are recommended by Erowid.


CosmoGRaPH is a c++ code used to explore cosmological problems in a fully general relativistic setting. The code implements various novel methods for numerically solving the Einstein field equations, including an N-body solver, full AMR capabilities via SAMRAI, and raytracing.
You may access the source code for the full AMR version on github below. Please see the README file for details regarding the code. Note that no support is currently offered for the code, and it is still under development.
You may also access the source code for the original, unigrid code on github. Please see the README file for details regarding the code. Note that no support is currently offered for the code, and it is still under development.
CosmoGRaPH documentation is limited, but available for some of the unigrid version of the code. You may build documentation using doxygen, or view a (possibly outdated) documentation build by clicking below.
Below is a list of papers that have used this code.


Comments
-
Greg Hurrell
Thanks for the report. Looks like this only happens when run as a Launch Agent. I suspect the cause is no
LANG
environment variable being set, causingpbcopy
to revert to default C encoding (see thepbcopy
man page).We might be able to get around this by tweaking the launchd plist file to set an appropriate
LANG
setting. -
Greg Hurrell
Yep, looks like you can get it to work by modifying the plist, adding a section like:
diff --git a/com.wincent.clipper.plist b/com.wincent.clipper.plist index d37bb09..921eb1d 100644 --- a/com.wincent.clipper.plist +++ b/com.wincent.clipper.plist @@ -12,6 +12,11 @@ <string>--port</string> <string>8377</string> </array> + <key>EnvironmentVariables</key> + <dict> + <key>LANG</key> + <string>en_US.UTF-8</string> + </dict> <key>KeepAlive</key> <true/> <key>LimitLoadToSessionType</key>
Where this file is depends on how you installed. If you installed using Homebrew, it's at
/usr/local/Cellar/clipper/0.1/homebrew.mxcl.clipper.plist
and you'll be able to fix things by stopping Clipper:$ launchctl unload /usr/local/Cellar/clipper/0.1/homebrew.mxcl.clipper.plist
Editing the property list:
$ vim /usr/local/Cellar/clipper/0.1/homebrew.mxcl.clipper.plist
And restarting Clipper:
$ launchctl load -w -S Aqua /usr/local/Cellar/clipper/0.1/homebrew.mxcl.clipper.plist
If you installed it yourself, the steps are much the same but the property list most likely is at
~/Library/LaunchAgents/com.wincent.clipper.plist
.UTF-8 seems like a reasonable default — and it's what the
pbcopy
man page recommends — so I'll push an update to the Clipper repo that includes this in the sample plist file, and probably also a pull request to update the Homebrew recipe as well. -
Greg Hurrell
0.2 is released, and here is the matching Homebrew pull request.
-
Greg Hurrell
Status changed:
- From: new
- To: closed
Add a comment
Comments are now closed for this issue.


BMSClient
public class BMSClient
A singleton that serves as the entry point to Bluemix client-server communication.
-
The region where your Bluemix service is hosted.
See moreDeclaration
Swift
public struct Region
-
The singleton that is used for all
BMSClient
activity.Declaration
Swift
public static let sharedInstance = BMSClient()
-
Specifies the base Bluemix application backend URL.
Declaration
Swift
public private(set) var bluemixAppRoute: String?
-
Specifies the region where the Bluemix service is hosted.
Declaration
Swift
public private(set) var bluemixRegion: String?
-
Specifies the Bluemix application backend identifier.
Declaration
Swift
public private(set) var bluemixAppGUID: String?
-
Specifies the allowed timeout (in seconds) for all
Request
network requests.Declaration
Swift
public var requestTimeout: Double = 20.0
-
The required intializer for the
BMSClient
class.Call this method on
BMSClient.sharedInstance
.Note
The
backendAppRoute
andbackendAppGUID
parameters are not required; they are only used for making network requests to the Bluemix server using theRequest
class.Declaration
Swift
public func initialize(bluemixAppRoute: String? = nil, bluemixAppGUID: String? = nil, bluemixRegion: String...)
Parameters
backendAppRoute
(Optional) The base URL for the authorization server.
backendAppGUID
(Optional) The GUID of the Bluemix application.
bluemixRegion
The region where your Bluemix application is hosted. Use one of the
BMSClient.Region
constants.


HOME
ABOUT
OPPORTUNITY
INTERACTIVE
TECHNOLOGY
TRAINING
CONTACT
iNau
offers fun events using digital technology that brings Te Reo Māori into your life. We welcome speakers of all levels to participate and encourage the growth of Reo speaking communities.


Voice Ready is Enterprise software that enables a Voice and Conversation platform. Our core pillars are Interoperability, Intelligent insights, and Easy Onboarding.Founded by industry leaders with experience from GE, Microsoft, Amazon, Motorola and AT&T. It is aimed at elevating the domains of Retail, Healthcare, Travel and Education to plug into the Voice Ecosystem.Voice Ready's elaborate network in the technology and Voice space combined with its strong engineering teams, Voice Ready an active player in the North American and Indian markets.


Working With Time in Postgres
A massive amount of reporting queries, whether really intensive data analysis, or just basic insights into your business involving looking at data over a certain time period. Postgres has really rich support for dealing with time out of the box, something that’s often very underweighted when dealing with a database. Sure, if you have a time-series database it’s implied, but even then how flexible and friendly is it from a query perspective? With Postgres there’s a lot of key items available to you, let’s dig in at the things that make your life easier when querying.
Date math
The most common thing I find myself doing is looking at users that have done something within some specific time window. If I’m executing this all from my app I can easily inject specific dates, but Postgres makes this really easy for you. Within Postgres you have a type called an interval that is some window of time. And fortunately Postgres takes care of the heavy lifting of how might something translate to or from hours/seconds/milliseconds/etc. Here’s just a few examples of things you could do with interals:
- ‘1 day’::interval
- ‘5 days’::interval
- ‘1 week’::interval
- ‘30 days’::interval
- ‘1 month’::interval
A note that if you’re looking to remove something like a full month, you actually want to use 1 month instead of trying to calculate yourself.
With a given interval you can easily shift some window of time, such as finding all users that have signed up for your service within the past week:
1 2 3 |
|
Date functions
Date math makes it pretty easy for you to go and find some specific set of data that applies, but what do you do when you want a broader report around time? There’s a few options here. One is to leverage the built-in Postgres functions that help you work with dates and times. date_trunc
is one of the most used ones that will truncate a date down to some interval level. Here you can use the same general values as the above, but simply pass in the type of interval it will be. So if we wanted to find the count of users that signed up per week:
1 2 3 4 5 |
|
This gives us a nice roll-up of how many users signed up each week. What’s missing here though is if you have a week that has no users. In that case because no users signed up there is no count of 0, it just simply doesn’t exist. If you did want something like this you could generate some range of time and then do a cross join with it against users to see which week they fell into. To do this first you’d generate a series of dates:
1
|
|
Then we’re going to join this against the actual users table and check that the created_at
falls within the right range.
1 2 3 4 5 6 7 8 9 10 11 12 13 |
|
Timestamp vs. Timestamptz
What about storing the times themselves? Postgres has two types of timestamps. It has a generic timestamp and one with timezone embedded in it. In most cases you should generally opt for timestamptz. Why not timestamp? What happens if you move a server, or your server somehow swaps its configuration. Or perhaps more practically what about daylight savings time? In general you might think that you can simply just put in the time as you see it, but when different countries around the world observe things like daylight savings time differently it introduces complexities into your application.
With timestamptz it’ll be aware of the extra parts of your timezone as it comes in. Then when you query from one timezone that accounts for daylights savings you’re all covered. There’s a number of articles that cover a bit more in depth on the logic between timestamp and timestamp with timezone, so if you’re curious I encourage you to check them out, but by default you mostly just need to use timestamptz.
More
There’s a number of other functions and capabilities when it comes to dealing with time in Postrges. You can extract
various parts of a timesetamp or interval such as hour of the day or the month. You can grab the day of the week with dow
. And one of my favorites which is when we celebrate happy hour at Citus, there’s a literal for UTC 00:00:00 00:00:00 which is allballs()
. If you need to work with dates and times in Postgres I encourage you to check out the docs before you try to re-write something of your own, chances are what you need may already be there.


As long as you have no title to display, your organization will not appear on the marketplace.
You can either add several titles at once through bulk import, or just one at a time.
N.B.: Only submitted projects will appear on the marketplace, not drafts.
You haven't imported titles yet.
You may add several titles at once through bulk import, or just one at a time.


{% extends 'foirequest/base.html' %} {% load i18n %} {% load static %} {% block title %}{% trans "Your request has been sent" %}{% endblock %} {% block body %}
{% blocktrans with title=foirequest.title url=foirequest.get_absolute_url %} Your request “{{ title }}” has been sent. {% endblocktrans %}
{% trans "We will send you an email when you receive a reply from the public body." %}
{% endif %} {% if foiproject %}{% blocktrans with title=foiproject.title url=foiproject.get_absolute_url %} Your project “{{ title }}” has been created and its requests are being sent out now. {% endblocktrans %}
{% endif %}


{if $wa->get('list') == 'viewed_products'} {$title = '[`Viewed products`]'} {$wa->title($title)} {$pages_count = 1} {$viewed_products = waRequest::cookie('viewed_products')} {if !empty($viewed_products)} {$products = $wa->shop->products("id/`$viewed_products`")} {else} {$products = null} {/if} {elseif $wa->get('list') == 'wishlist'} {$title = '[`Wish List`]'} {$wa->title($title)} {$pages_count = 1} {$wishlist = waRequest::cookie('shop_wishlist')} {if !empty($wishlist)} {$products = $wa->shop->products("id/`$wishlist`")} {else} {$products = null} {/if} {elseif $wa->get('query')} {$is_products_pers = true} {$title = "[`Search by query`] «`$wa->get('query')|escape`»"} {/if} {$compare = waRequest::cookie('shop_compare', array(), waRequest::TYPE_ARRAY_INT)} {$wishlist = waRequest::cookie('shop_wishlist', array(), waRequest::TYPE_ARRAY_INT)}


|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object javax.xml.transform.Transformer org.apache.xalan.transformer.TransformerIdentityImpl
public class TransformerIdentityImpl
This class implements an identity transformer for
SAXTransformerFactory.newTransformerHandler()
and TransformerFactory.newTransformer()
. It
simply feeds SAX events directly to a serializer ContentHandler, if the
result is a stream. If the result is a DOM, it will send the events to
DOMBuilder
. If the result is another
content handler, it will simply pass the events on.
| Field Summary | |
|---|---|
private javax.xml.transform.ErrorListener |
m_errorListener
The error listener for TrAX errors and warnings. |
(package private) boolean |
m_flushedStartDoc
|
(package private) boolean |
m_foundFirstElement
Flag to set if we've found the first element, so we can tell if we have to check to see if we should create an HTML serializer. |
private boolean |
m_isSecureProcessing
State of the secure processing feature. |
private OutputProperties |
m_outputFormat
The output properties. |
private java.io.FileOutputStream |
m_outputStream
This is null unless we own the stream. |
private java.util.Hashtable |
m_params
The parameters, which is unused, but must be returned to fullfill the Transformer interface. |
private javax.xml.transform.Result |
m_result
The Result object. |
private org.xml.sax.ContentHandler |
m_resultContentHandler
The content handler where result events will be sent. |
private org.xml.sax.ext.DeclHandler |
m_resultDeclHandler
The Decl handler where result events will be sent. |
private org.xml.sax.DTDHandler |
m_resultDTDHandler
The DTD handler where result events will be sent. |
private org.xml.sax.ext.LexicalHandler |
m_resultLexicalHandler
The lexical handler where result events will be sent. |
private Serializer |
m_serializer
The Serializer, which may or may not be null. |
private java.lang.String |
m_systemID
The system ID, which is unused, but must be returned to fullfill the TransformerHandler interface. |
(package private) javax.xml.transform.URIResolver |
m_URIResolver
The URIResolver, which is unused, but must be returned to fullfill the TransformerHandler interface. |
| Constructor Summary | |
|---|---|
TransformerIdentityImpl()
Constructor TransformerIdentityImpl creates an identity transform. |
|
TransformerIdentityImpl(boolean isSecureProcessing)
Constructor TransformerIdentityImpl creates an identity transform. |
| Method Summary | |
|---|---|
void |
attributeDecl(java.lang.String eName,
java.lang.String aName,
java.lang.String type,
java.lang.String valueDefault,
java.lang.String value)
Report an attribute type declaration. |
void |
characters(char[] ch,
int start,
int length)
Receive notification of character data inside an element. |
void |
clearParameters()
Clear all parameters set with setParameter. |
void |
comment(char[] ch,
int start,
int length)
Report an XML comment anywhere in the document. |
private void |
createResultContentHandler(javax.xml.transform.Result outputTarget)
Create a result ContentHandler from a Result object, based on the current OutputProperties. |
void |
elementDecl(java.lang.String name,
java.lang.String model)
Report an element type declaration. |
void |
endCDATA()
Report the end of a CDATA section. |
void |
endDocument()
Receive notification of the end of the document. |
void |
endDTD()
Report the end of DTD declarations. |
void |
endElement(java.lang.String uri,
java.lang.String localName,
java.lang.String qName)
Receive notification of the end of an element. |
void |
endEntity(java.lang.String name)
Report the end of an entity. |
void |
endPrefixMapping(java.lang.String prefix)
Receive notification of the end of a Namespace mapping. |
void |
externalEntityDecl(java.lang.String name,
java.lang.String publicId,
java.lang.String systemId)
Report a parsed external entity declaration. |
protected void |
flushStartDoc()
|
javax.xml.transform.ErrorListener |
getErrorListener()
Get the error event handler in effect for the transformation. |
java.util.Properties |
getOutputProperties()
Get a copy of the output properties for the transformation. |
java.lang.String |
getOutputProperty(java.lang.String name)
Get an output property that is in effect for the transformation. |
java.lang.Object |
getParameter(java.lang.String name)
Get a parameter that was explicitly set with setParameter or setParameters. |
java.lang.String |
getSystemId()
Get the base ID (URI or system ID) from where relative URLs will be resolved. |
javax.xml.transform.Transformer |
getTransformer()
Get the Transformer associated with this handler, which is needed in order to set parameters and output properties. |
javax.xml.transform.URIResolver |
getURIResolver()
Get an object that will be used to resolve URIs used in document(), etc. |
void |
ignorableWhitespace(char[] ch,
int start,
int length)
Receive notification of ignorable whitespace in element content. |
void |
internalEntityDecl(java.lang.String name,
java.lang.String value)
Report an internal entity declaration. |
void |
notationDecl(java.lang.String name,
java.lang.String publicId,
java.lang.String systemId)
Receive notification of a notation declaration. |
void |
processingInstruction(java.lang.String target,
java.lang.String data)
Receive notification of a processing instruction. |
void |
reset()
Reset the status of the transformer. |
void |
setDocumentLocator(org.xml.sax.Locator locator)
Receive a Locator object for document events. |
void |
setErrorListener(javax.xml.transform.ErrorListener listener)
Set the error event listener in effect for the transformation. |
void |
setOutputProperties(java.util.Properties oformat)
Set the output properties for the transformation. |
void |
setOutputProperty(java.lang.String name,
java.lang.String value)
Set an output property that will be in effect for the transformation. |
void |
setParameter(java.lang.String name,
java.lang.Object value)
Add a parameter for the transformation. |
void |
setResult(javax.xml.transform.Result result)
Enables the user of the TransformerHandler to set the to set the Result for the transformation. |
void |
setSystemId(java.lang.String systemID)
Set the base ID (URI or system ID) from where relative URLs will be resolved. |
void |
setURIResolver(javax.xml.transform.URIResolver resolver)
Set an object that will be used to resolve URIs used in document(). |
void |
skippedEntity(java.lang.String name)
Receive notification of a skipped entity. |
void |
startCDATA()
Report the start of a CDATA section. |
void |
startDocument()
Receive notification of the beginning of the document. |
void |
startDTD(java.lang.String name,
java.lang.String publicId,
java.lang.String systemId)
Report the start of DTD declarations, if any. |
void |
startElement(java.lang.String uri,
java.lang.String localName,
java.lang.String qName,
org.xml.sax.Attributes attributes)
Receive notification of the start of an element. |
void |
startEntity(java.lang.String name)
Report the beginning of an entity in content. |
void |
startPrefixMapping(java.lang.String prefix,
java.lang.String uri)
Receive notification of the start of a Namespace mapping. |
void |
transform(javax.xml.transform.Source source,
javax.xml.transform.Result outputTarget)
Process the source tree to the output result. |
void |
unparsedEntityDecl(java.lang.String name,
java.lang.String publicId,
java.lang.String systemId,
java.lang.String notationName)
Receive notification of an unparsed entity declaration. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
boolean m_flushedStartDoc
private java.io.FileOutputStream m_outputStream
private org.xml.sax.ContentHandler m_resultContentHandler
private org.xml.sax.ext.LexicalHandler m_resultLexicalHandler
private org.xml.sax.DTDHandler m_resultDTDHandler
private org.xml.sax.ext.DeclHandler m_resultDeclHandler
private Serializer m_serializer
private javax.xml.transform.Result m_result
private java.lang.String m_systemID
private java.util.Hashtable m_params
private javax.xml.transform.ErrorListener m_errorListener
javax.xml.transform.URIResolver m_URIResolver
private OutputProperties m_outputFormat
boolean m_foundFirstElement
private boolean m_isSecureProcessing
| Constructor Detail |
|---|
public TransformerIdentityImpl(boolean isSecureProcessing)
public TransformerIdentityImpl()
| Method Detail |
|---|
public void setResult(javax.xml.transform.Result result) throws java.lang.IllegalArgumentException
setResult
in interface javax.xml.transform.sax.TransformerHandler
result
- A Result instance, should not be null.
java.lang.IllegalArgumentException
- if result is invalid for some reason.public void setSystemId(java.lang.String systemID)
setSystemId
in interface javax.xml.transform.sax.TransformerHandler
systemID
- Base URI for the source tree.public java.lang.String getSystemId()
getSystemId
in interface javax.xml.transform.sax.TransformerHandler
setSystemId(java.lang.String)
.public javax.xml.transform.Transformer getTransformer()
getTransformer
in interface javax.xml.transform.sax.TransformerHandler
public void reset()
reset
in class javax.xml.transform.Transformer
private void createResultContentHandler(javax.xml.transform.Result outputTarget) throws javax.xml.transform.TransformerException
outputTarget
- Where the transform result should go,
should not be null.
javax.xml.transform.TransformerException
public void transform(javax.xml.transform.Source source, javax.xml.transform.Result outputTarget) throws javax.xml.transform.TransformerException
transform
in class javax.xml.transform.Transformer
source
- The input for the source tree.outputTarget
- The output target.
javax.xml.transform.TransformerException
- If an unrecoverable error occurs
during the course of the transformation.public void setParameter(java.lang.String name, java.lang.Object value)
Pass a qualified name as a two-part string, the namespace URI enclosed in curly braces ({}), followed by the local name. If the name has a null URL, the String only contain the local name. An application can safely check for a non-null URI by testing to see if the first character of the name is a '{' character.
For example, if a URI and local name were obtained from an element defined with <xyz:foo xmlns:xyz="http://xyz.foo.com/yada/baz.html"/>, then the qualified name would be "{http://xyz.foo.com/yada/baz.html}foo". Note that no prefix is used.
setParameter
in class javax.xml.transform.Transformer
name
- The name of the parameter, which may begin with a namespace URI
in curly braces ({}).value
- The value object. This can be any valid Java object. It is
up to the processor to provide the proper object coersion or to simply
pass the object on for use in an extension.public java.lang.Object getParameter(java.lang.String name)
This method does not return a default parameter value, which cannot be determined until the node context is evaluated during the transformation process.
getParameter
in class javax.xml.transform.Transformer
name
- Name of the parameter.
public void clearParameters()
clearParameters
in class javax.xml.transform.Transformer
public void setURIResolver(javax.xml.transform.URIResolver resolver)
If the resolver argument is null, the URIResolver value will be cleared, and the default behavior will be used.
setURIResolver
in class javax.xml.transform.Transformer
resolver
- An object that implements the URIResolver interface,
or null.public javax.xml.transform.URIResolver getURIResolver()
getURIResolver
in class javax.xml.transform.Transformer
public void setOutputProperties(java.util.Properties oformat) throws java.lang.IllegalArgumentException
If argument to this function is null, any properties previously set are removed, and the value will revert to the value defined in the templates object.
Pass a qualified property key name as a two-part string, the namespace URI enclosed in curly braces ({}), followed by the local name. If the name has a null URL, the String only contain the local name. An application can safely check for a non-null URI by testing to see if the first character of the name is a '{' character.
For example, if a URI and local name were obtained from an element defined with <xyz:foo xmlns:xyz="http://xyz.foo.com/yada/baz.html"/>, then the qualified name would be "{http://xyz.foo.com/yada/baz.html}foo". Note that no prefix is used.
setOutputProperties
in class javax.xml.transform.Transformer
oformat
- A set of output properties that will be
used to override any of the same properties in affect
for the transformation.
java.lang.IllegalArgumentException
- if any of the argument keys are not
recognized and are not namespace qualified.OutputKeys
,
Properties
public java.util.Properties getOutputProperties()
The properties returned should contain properties set by the user,
and properties set by the stylesheet, and these properties
are "defaulted" by default properties specified by section 16 of the
XSL Transformations (XSLT) W3C Recommendation. The properties that
were specifically set by the user or the stylesheet should be in the base
Properties list, while the XSLT default properties that were not
specifically set should be the default Properties list. Thus,
getOutputProperties().getProperty(String key) will obtain any
property in that was set by setOutputProperty(java.lang.String, java.lang.String)
,
setOutputProperties(java.util.Properties)
, in the stylesheet, or the default
properties, while
getOutputProperties().get(String key) will only retrieve properties
that were explicitly set by setOutputProperty(java.lang.String, java.lang.String)
,
setOutputProperties(java.util.Properties)
, or in the stylesheet.
Note that mutation of the Properties object returned will not effect the properties that the transformation contains.
If any of the argument keys are not recognized and are not namespace qualified, the property will be ignored. In other words the behaviour is not orthogonal with setOutputProperties.
getOutputProperties
in class javax.xml.transform.Transformer
OutputKeys
,
Properties
public void setOutputProperty(java.lang.String name, java.lang.String value) throws java.lang.IllegalArgumentException
Pass a qualified property name as a two-part string, the namespace URI enclosed in curly braces ({}), followed by the local name. If the name has a null URL, the String only contain the local name. An application can safely check for a non-null URI by testing to see if the first character of the name is a '{' character.
For example, if a URI and local name were obtained from an element defined with <xyz:foo xmlns:xyz="http://xyz.foo.com/yada/baz.html"/>, then the qualified name would be "{http://xyz.foo.com/yada/baz.html}foo". Note that no prefix is used.
The Properties object that was passed to setOutputProperties(java.util.Properties)
won't
be effected by calling this method.
setOutputProperty
in class javax.xml.transform.Transformer
name
- A non-null String that specifies an output
property name, which may be namespace qualified.value
- The non-null string value of the output property.
java.lang.IllegalArgumentException
- If the property is not supported, and is
not qualified with a namespace.OutputKeys
public java.lang.String getOutputProperty(java.lang.String name) throws java.lang.IllegalArgumentException
getOutputProperty
in class javax.xml.transform.Transformer
name
- A non-null String that specifies an output
property name, which may be namespace qualified.
java.lang.IllegalArgumentException
- If the property is not supported.OutputKeys
public void setErrorListener(javax.xml.transform.ErrorListener listener) throws java.lang.IllegalArgumentException
setErrorListener
in class javax.xml.transform.Transformer
listener
- The new error listener.
java.lang.IllegalArgumentException
- if listener is null.public javax.xml.transform.ErrorListener getErrorListener()
getErrorListener
in class javax.xml.transform.Transformer
public void notationDecl(java.lang.String name, java.lang.String publicId, java.lang.String systemId) throws org.xml.sax.SAXException
By default, do nothing. Application writers may override this method in a subclass if they wish to keep track of the notations declared in a document.
notationDecl
in interface org.xml.sax.DTDHandler
name
- The notation name.publicId
- The notation public identifier, or null if not
available.systemId
- The notation system identifier.
org.xml.sax.SAXException
- Any SAX exception, possibly
wrapping another exception.
org.xml.sax.SAXException
DTDHandler.notationDecl(java.lang.String, java.lang.String, java.lang.String)
public void unparsedEntityDecl(java.lang.String name, java.lang.String publicId, java.lang.String systemId, java.lang.String notationName) throws org.xml.sax.SAXException
By default, do nothing. Application writers may override this method in a subclass to keep track of the unparsed entities declared in a document.
unparsedEntityDecl
in interface org.xml.sax.DTDHandler
name
- The entity name.publicId
- The entity public identifier, or null if not
available.systemId
- The entity system identifier.notationName
- The name of the associated notation.
org.xml.sax.SAXException
- Any SAX exception, possibly
wrapping another exception.
org.xml.sax.SAXException
DTDHandler.unparsedEntityDecl(java.lang.String, java.lang.String, java.lang.String, java.lang.String)
public void setDocumentLocator(org.xml.sax.Locator locator)
By default, do nothing. Application writers may override this method in a subclass if they wish to store the locator for use with other document events.
setDocumentLocator
in interface org.xml.sax.ContentHandler
locator
- A locator for all SAX document events.ContentHandler.setDocumentLocator(org.xml.sax.Locator)
,
Locator
public void startDocument() throws org.xml.sax.SAXException
By default, do nothing. Application writers may override this method in a subclass to take specific actions at the beginning of a document (such as allocating the root node of a tree or creating an output file).
startDocument
in interface org.xml.sax.ContentHandler
org.xml.sax.SAXException
- Any SAX exception, possibly
wrapping another exception.
org.xml.sax.SAXException
ContentHandler.startDocument()
protected final void flushStartDoc() throws org.xml.sax.SAXException
org.xml.sax.SAXException
public void endDocument() throws org.xml.sax.SAXException
By default, do nothing. Application writers may override this method in a subclass to take specific actions at the end of a document (such as finalising a tree or closing an output file).
endDocument
in interface org.xml.sax.ContentHandler
org.xml.sax.SAXException
- Any SAX exception, possibly
wrapping another exception.
org.xml.sax.SAXException
ContentHandler.endDocument()
public void startPrefixMapping(java.lang.String prefix, java.lang.String uri) throws org.xml.sax.SAXException
By default, do nothing. Application writers may override this method in a subclass to take specific actions at the start of each Namespace prefix scope (such as storing the prefix mapping).
startPrefixMapping
in interface org.xml.sax.ContentHandler
prefix
- The Namespace prefix being declared.uri
- The Namespace URI mapped to the prefix.
org.xml.sax.SAXException
- Any SAX exception, possibly
wrapping another exception.
org.xml.sax.SAXException
ContentHandler.startPrefixMapping(java.lang.String, java.lang.String)
public void endPrefixMapping(java.lang.String prefix) throws org.xml.sax.SAXException
By default, do nothing. Application writers may override this method in a subclass to take specific actions at the end of each prefix mapping.
endPrefixMapping
in interface org.xml.sax.ContentHandler
prefix
- The Namespace prefix being declared.
org.xml.sax.SAXException
- Any SAX exception, possibly
wrapping another exception.
org.xml.sax.SAXException
ContentHandler.endPrefixMapping(java.lang.String)
public void startElement(java.lang.String uri, java.lang.String localName, java.lang.String qName, org.xml.sax.Attributes attributes) throws org.xml.sax.SAXException
By default, do nothing. Application writers may override this method in a subclass to take specific actions at the start of each element (such as allocating a new tree node or writing output to a file).
startElement
in interface org.xml.sax.ContentHandler
uri
- The Namespace URI, or the empty string if the
element has no Namespace URI or if Namespace
processing is not being performed.localName
- The local name (without prefix), or the
empty string if Namespace processing is not being
performed.qName
- The qualified name (with prefix), or the
empty string if qualified names are not available.attributes
- The specified or defaulted attributes.
org.xml.sax.SAXException
- Any SAX exception, possibly
wrapping another exception.
org.xml.sax.SAXException
ContentHandler.startElement(java.lang.String, java.lang.String, java.lang.String, org.xml.sax.Attributes)
public void endElement(java.lang.String uri, java.lang.String localName, java.lang.String qName) throws org.xml.sax.SAXException
By default, do nothing. Application writers may override this method in a subclass to take specific actions at the end of each element (such as finalising a tree node or writing output to a file).
endElement
in interface org.xml.sax.ContentHandler
uri
- The Namespace URI, or the empty string if the
element has no Namespace URI or if Namespace
processing is not being performed.localName
- The local name (without prefix), or the
empty string if Namespace processing is not being
performed.qName
- The qualified name (with prefix), or the
empty string if qualified names are not available.
org.xml.sax.SAXException
- Any SAX exception, possibly
wrapping another exception.
org.xml.sax.SAXException
ContentHandler.endElement(java.lang.String, java.lang.String, java.lang.String)
public void characters(char[] ch, int start, int length) throws org.xml.sax.SAXException
By default, do nothing. Application writers may override this method to take specific actions for each chunk of character data (such as adding the data to a node or buffer, or printing it to a file).
characters
in interface org.xml.sax.ContentHandler
ch
- The characters.start
- The start position in the character array.length
- The number of characters to use from the
character array.
org.xml.sax.SAXException
- Any SAX exception, possibly
wrapping another exception.
org.xml.sax.SAXException
ContentHandler.characters(char[], int, int)
public void ignorableWhitespace(char[] ch, int start, int length) throws org.xml.sax.SAXException
By default, do nothing. Application writers may override this method to take specific actions for each chunk of ignorable whitespace (such as adding data to a node or buffer, or printing it to a file).
ignorableWhitespace
in interface org.xml.sax.ContentHandler
ch
- The whitespace characters.start
- The start position in the character array.length
- The number of characters to use from the
character array.
org.xml.sax.SAXException
- Any SAX exception, possibly
wrapping another exception.
org.xml.sax.SAXException
ContentHandler.ignorableWhitespace(char[], int, int)
public void processingInstruction(java.lang.String target, java.lang.String data) throws org.xml.sax.SAXException
By default, do nothing. Application writers may override this method in a subclass to take specific actions for each processing instruction, such as setting status variables or invoking other methods.
processingInstruction
in interface org.xml.sax.ContentHandler
target
- The processing instruction target.data
- The processing instruction data, or null if
none is supplied.
org.xml.sax.SAXException
- Any SAX exception, possibly
wrapping another exception.
org.xml.sax.SAXException
ContentHandler.processingInstruction(java.lang.String, java.lang.String)
public void skippedEntity(java.lang.String name) throws org.xml.sax.SAXException
By default, do nothing. Application writers may override this method in a subclass to take specific actions for each processing instruction, such as setting status variables or invoking other methods.
skippedEntity
in interface org.xml.sax.ContentHandler
name
- The name of the skipped entity.
org.xml.sax.SAXException
- Any SAX exception, possibly
wrapping another exception.
org.xml.sax.SAXException
ContentHandler.processingInstruction(java.lang.String, java.lang.String)
public void startDTD(java.lang.String name, java.lang.String publicId, java.lang.String systemId) throws org.xml.sax.SAXException
Any declarations are assumed to be in the internal subset
unless otherwise indicated by a startEntity
event.
Note that the start/endDTD events will appear within the start/endDocument events from ContentHandler and before the first startElement event.
startDTD
in interface org.xml.sax.ext.LexicalHandler
name
- The document type name.publicId
- The declared public identifier for the
external DTD subset, or null if none was declared.systemId
- The declared system identifier for the
external DTD subset, or null if none was declared.
org.xml.sax.SAXException
- The application may raise an
exception.endDTD()
,
startEntity(java.lang.String)
public void endDTD() throws org.xml.sax.SAXException
endDTD
in interface org.xml.sax.ext.LexicalHandler
org.xml.sax.SAXException
- The application may raise an exception.startDTD(java.lang.String, java.lang.String, java.lang.String)
public void startEntity(java.lang.String name) throws org.xml.sax.SAXException
NOTE: entity references in attribute values -- and the start and end of the document entity -- are never reported.
The start and end of the external DTD subset are reported using the pseudo-name "[dtd]". All other events must be properly nested within start/end entity events.
Note that skipped entities will be reported through the
skippedEntity
event, which is part of the ContentHandler interface.
startEntity
in interface org.xml.sax.ext.LexicalHandler
name
- The name of the entity. If it is a parameter
entity, the name will begin with '%'.
org.xml.sax.SAXException
- The application may raise an exception.endEntity(java.lang.String)
,
DeclHandler.internalEntityDecl(java.lang.String, java.lang.String)
,
DeclHandler.externalEntityDecl(java.lang.String, java.lang.String, java.lang.String)
public void endEntity(java.lang.String name) throws org.xml.sax.SAXException
endEntity
in interface org.xml.sax.ext.LexicalHandler
name
- The name of the entity that is ending.
org.xml.sax.SAXException
- The application may raise an exception.startEntity(java.lang.String)
public void startCDATA() throws org.xml.sax.SAXException
The contents of the CDATA section will be reported through
the regular characters
event.
startCDATA
in interface org.xml.sax.ext.LexicalHandler
org.xml.sax.SAXException
- The application may raise an exception.endCDATA()
public void endCDATA() throws org.xml.sax.SAXException
endCDATA
in interface org.xml.sax.ext.LexicalHandler
org.xml.sax.SAXException
- The application may raise an exception.startCDATA()
public void comment(char[] ch, int start, int length) throws org.xml.sax.SAXException
This callback will be used for comments inside or outside the document element, including comments in the external DTD subset (if read).
comment
in interface org.xml.sax.ext.LexicalHandler
ch
- An array holding the characters in the comment.start
- The starting position in the array.length
- The number of characters to use from the array.
org.xml.sax.SAXException
- The application may raise an exception.public void elementDecl(java.lang.String name, java.lang.String model) throws org.xml.sax.SAXException
The content model will consist of the string "EMPTY", the string "ANY", or a parenthesised group, optionally followed by an occurrence indicator. The model will be normalized so that all whitespace is removed,and will include the enclosing parentheses.
elementDecl
in interface org.xml.sax.ext.DeclHandler
name
- The element type name.model
- The content model as a normalized string.
org.xml.sax.SAXException
- The application may raise an exception.public void attributeDecl(java.lang.String eName, java.lang.String aName, java.lang.String type, java.lang.String valueDefault, java.lang.String value) throws org.xml.sax.SAXException
Only the effective (first) declaration for an attribute will be reported. The type will be one of the strings "CDATA", "ID", "IDREF", "IDREFS", "NMTOKEN", "NMTOKENS", "ENTITY", "ENTITIES", or "NOTATION", or a parenthesized token group with the separator "|" and all whitespace removed.
attributeDecl
in interface org.xml.sax.ext.DeclHandler
eName
- The name of the associated element.aName
- The name of the attribute.type
- A string representing the attribute type.valueDefault
- A string representing the attribute default
("#IMPLIED", "#REQUIRED", or "#FIXED") or null if
none of these applies.value
- A string representing the attribute's default value,
or null if there is none.
org.xml.sax.SAXException
- The application may raise an exception.public void internalEntityDecl(java.lang.String name, java.lang.String value) throws org.xml.sax.SAXException
Only the effective (first) declaration for each entity will be reported.
internalEntityDecl
in interface org.xml.sax.ext.DeclHandler
name
- The name of the entity. If it is a parameter
entity, the name will begin with '%'.value
- The replacement text of the entity.
org.xml.sax.SAXException
- The application may raise an exception.externalEntityDecl(java.lang.String, java.lang.String, java.lang.String)
,
DTDHandler.unparsedEntityDecl(java.lang.String, java.lang.String, java.lang.String, java.lang.String)
public void externalEntityDecl(java.lang.String name, java.lang.String publicId, java.lang.String systemId) throws org.xml.sax.SAXException
Only the effective (first) declaration for each entity will be reported.
externalEntityDecl
in interface org.xml.sax.ext.DeclHandler
name
- The name of the entity. If it is a parameter
entity, the name will begin with '%'.publicId
- The declared public identifier of the entity, or
null if none was declared.systemId
- The declared system identifier of the entity.
org.xml.sax.SAXException
- The application may raise an exception.internalEntityDecl(java.lang.String, java.lang.String)
,
DTDHandler.unparsedEntityDecl(java.lang.String, java.lang.String, java.lang.String, java.lang.String)
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |


| Officiant |
O Lord, show your mercy upon us; |
| People |
And grant us your salvation. |
| Officiant |
O Lord, guide those who govern us; |
| People |
And lead us in the way of justice and truth. |
| Officiant |
Clothe your ministers with righteousness; |
| People |
And let your people sing with joy. |
| Officiant |
O Lord, save your people; |
| People |
And bless your inheritance. |
| Officiant |
Give peace in our time, O Lord; |
| People |
And defend us by your mighty power. |
| Officiant |
Let not the needy, O Lord, be forgotten; |
| People |
Nor the hope of the poor be taken away. |
| Officiant |
Create in us clean hearts, O God; |
| People |
And take not your Holy Spirit from us. |


David Lee Roth claims he "structured" guitar solos on Van Halen's debut album
by Rob LaingDavid Lee Roth claims he "structured" guitar solos on Van Halen's debut album
David Lee Roth is not a man we would associate with understatement, and his proclamations during interviews with the press are never less than entertaining – particularly on the subject of Van Halen. But his latest claim regarding his involvement with Eddie Van Halen's guitar solos on the band's debut album is particularly interesting.
In a recent interview with Missouri radio station KSHE 95 to discuss his upcoming Las Vegas residency, Roth was asked about performing Van Halen songs – specifically whether he sought permission from his current / former (nobody is sure) bandmates to perform songs from their back catalogue, and his response was bullish to say the least…
“No, because I wrote the songs.  "I structured out, even the guitar solos on that first album.
“Why do you think the solos [later] changed so radically? I sang the solos for Jamie’s Cryin and Runnin With The Devil etc…"
But that wasn't all.
Even before that claim, Roth wasn't holding back in the interview from reminding us of his role in Van Halen when talking about Vegas residency plans with new backing band Horses Of God…
"Van Halen live is lead / bass / drums, here we start with three / four guitars, and we bring it with an unforgiving attitude. We're not up here strumming with the devil, this is not some tribute band. I wrote those songs, structured those songs.
"I designed the backgrounds on the stage. I came up with the album covers. I thought of the stripes on the guitar. I’m the one who said, ‘Call it Van Halen'. And we take it with that attitude. We ain't talking about love…"
You can hear the full interview below.
David Lee Roth's Las Vegas residency begins in January. For more info head to Davidleeroth.com


Who are we?
Let’s Be The Change (LBTC) is a non-profit organization which aims to build a cleaner and healthier society by working with the people and the Government. LBTC was started by Anirudh S Dutt on 5th July 2013. We have been growing ever since, with over 250 successful events, including cleanliness drives, awareness programmes, spot fixes, pet adoption drives and so on. We are mainly comprised of energetic youngsters whose only aim is to make Bengaluru a better place for the society. We are a bridge connection between the Municipal Corporation (BBMP) and the Citizens.
"We are the change people have been waiting for."
"We are the change people have been waiting for."
Vision
Mission
"To make our society a happier and better place by being the change that is needed."
What we do
- • We host “Cleanathon” drives (eradication and beautification of garbage dumps) in Bengaluru. We work towards making Bengaluru free from garbage dumps, one stretch at a time.
- • We conduct free Clay Ganapathi Workshops. In the past 2 years, over 3500 people have made their own Ganapathi Idols, for worship during the festival season.
- • We have tied-up with Precious Paws Foundation to organize fundraising events for injured stray dogs, pet adoption (stray, homeless pups).
- • On Television, Radio, and Social Media, we spread awareness about the importance of waste segregation and things that the average citizen can do to keep their localities clean.
- • In our YouTube channel, we demonstrate simple steps to keep your surroundings clean, various segregation techniques, and also have videos about traffic rules, common traffic conventions that people should follow, chain-snatching etc.
Our Team
Anirudh S Dutt
Founder, President
Prajwal GV
Vice President
Srivatsa Gargesh
General Secretary
Lohit B N
Treasurer
Vyshak Iyengar
Secretary
Amar Prabhu
Secretary
Nidhish Kudwalli
Secretary
Vinay Vasist
Secretary
Avinaasha Shastry
Board Member
Yoshita Ramesh
Board Member
Bhuvan Surya Purushothama B N
Board Member
Srinidhi Chandra
Board Member


Opposition protest in Assam Assembly as onion prices reach Rs 100 per kg
They asserted that they will continue to protest in the same manner till the state government takes measures to control the price of onions, which is selling at Rs 100 and more per kg in the state
by Press Trust of IndiaOpposition Congress MLAs of Assam reached the Assembly wearing garlands of onions on Friday as a mark of protest against the skyrocketing price of the bulb.
The legislators sported the garlands till the entrance of the House but did not wear them inside it.
They asserted that they will continue to protest in the same manner till the state government takes measures to control the price of onions, which is selling at Rs 100 and more per kg in the state.
AIUDF MLA Aminul Islam too protested wearing an onion garland and said he was looking to put it around political leaders who had protested when the price of the vegetable had risen to Rs 60, an oblique reference to some BJP members who did so during the Congress government.
Talking to reporters at the entrance of the House, Islam demanded that the government sell onions at controlled price through fair price shops to give relief to the people.
Food Supply Minister Phani Bhusan Chowdhury told journalists that the rise in the price of onion is being felt across the country and Assam being a consuming state was feeling the brunt of it.


After you complete this section, you should be able to:
Note that everything in “{}” is to be replaced. For example, {fileName} –> iLovePeanuts.txt
Interaction with the supercomputer is typically performed with command line tools. The command line tools can be run via a command prompt, also known as a shell. SSH is used to establish a secure shell with the supercomputer. In general, users should log in via the hostname ssh.fsl.byu.edu.
where {username} is your NetID. Programs can be tested from the interactive nodes, but anything left running for more than an hour will be killed automatically.
First make sure you are apart of the fslg_byustudent
group. You can check which groups you belong to by typing:
Create an apps directory in your home directory and go to that directory. First make sure you are in your home directory:
Next, make the new directory and go to that directory:
The apps can be found in the fslg_byustudent group:
I always like to add the option --dry-run
before submitting an rsync to make sure the files I want to copy are the ones being copied.
Check to make sure you have all the correct applications:
Every time a shell window opens, a process takes place to gather and compile information that needs to be available for all processes and child processes in that shell window. Many programs require certain environmental variables to be available in order to decipher the specifics of how to operate. In its simplest form, an environment variable is a variable with a name and a corresponding value. In most cases, it is simply the location of all the executable files for an application.
Since many of the programs in this class do not have the standard GUI (window) based application, if you want to “launch” the application you have to first set the environmental variable to tell the computer where the executable files for that application are located. Otherwise, when you run the program, you will get an error that the program does not exist.
Every time you open a shell window, if you have not permanently set the environmental variable, you will need to set it temporarily. The moment you close this window, the environmental variables are no longer set. If you run the program often, consider permanently setting the environment variable.
Download an example bash_profile to use on the FSL supercomputer.
You can edit text files directly within the shell window.
This will launch a text editor. The UNIX vi
has two modes of operation:
To begin insert mode to add text, press a
and then type in the following information.
Once you’ve typed the code, press esc
. Pressing the escape turns off insert mode and returns you to command mode. To save the file and exit out of vi
text editor, type :wq<Return>
. This command will quit vi
, writing out modified file to file named in original invocation.
For more information on the basics of using vi
go here:
http://www.cs.colostate.edu/helpdocs/vi.html
When writing bash commands, lines of code can get really, really long and sometimes leave you scrolling right and left for extended amounts of time. Although there are no hard and fast rules about formatting code, good coding practices involve more human-friendly methods of organization. Take the following one-line of code as an example:
You are a lot more likely to make a mistake in your code (i.e., dropping a variable, making typos, etc.) when your code is all jumbled up like this. There’s a solution to make the code more human-readable, but does not change how the shell terminal reads the command. Remember that pressing <Return> in the shell terminal says, “run command”. How then do you take a long line of code and wrap it across multiple lines? Backslash!
The backslash, \, in the shell window is called an escape character. It preserves the literal value of the next character that follows. In the case of a newline, the backslash marks the continuation of a line when the line of code is longer than the width of the terminal; when the command is finally submitted, the backslash that precedes a newline character is removed from the input stream and effectively ignored. In other words, the one line of code wrapped across multiple lines is run as if it was a single line of code.
Test it out…
Now press the up arrow in your terminal. The previous command will appear and it should look something like this now.
The terminal will remove the backslash and run the code as normal. Now what does the above code look like when it has been wrapped:
For this class, I will try to make the code as human-readable as possible.


Simple State Manager (SSM for short) is a javascript state manager for responsive websites. It is built to be light weight, has no dependencies (except javascript of course) and aims to be really easy to simply drop into your project ready to use.
As a state manager, SSM allows you to target different javascript towards different states of your site. It allows you to define as many states as your site requires and allows you to have independent Enter, Leave and Resize events for each of the states.
Why should I use SSM
- You require different javascript events dependant on your users being on mobile or desktop
- You need to provide a different resize event to the mobile view of your site than your desktop view
- You need to adjust your site using JS after it switches between states (mobile, tablet, desktop)
Getting started
To get started with SSM the first step is to include it in your project, you can do this in two ways
- Download and add the ssm.js (or ssm.min.js) file to your site
Add States
With Simple State Manager you can add multiple states based on your needs, the most simple way to add a state is to simply pass the information about your state to SSM using ssm.addState
. It is important to remember that the width you provide is the upper limit of your responsive state width, the lower limit is defined simply by defining another state with a width which is lower.
ssm.addState({id: 'mobile', width: 767, onEnter: function(){console.log('enter mobile')}}); ssm.addState({width: 1023, onEnter: function(){console.log('enter tablet')}}); ssm.addState({width: 9999, onEnter: function(){console.log('enter desktop')}});
If you wish to use one command to add multiple states using one command you can use ssm.addStates to which you should pass an array of states.
ssm.addStates([ {id: 'mobile', width: 767, onEnter: function(){console.log('enter mobile')}}, {id: 'tablet',width: 1023, onEnter: function(){console.log('enter tablet')}}, {id: 'desktop',width: 9999, onEnter: function(){console.log('enter desktop')}} ]);
Remove States
Sometimes it may be necessary to remove a state, if we have the id for the state we can easily remove the state, to remove the mobile state from our above example we simply use:
ssm.removeState('mobile');
Or if you want to remove multiple at the same time
ssm.removeStates(['tablet', 'mobile']);
Ready
Once you have finished setting up your states you should run ssm.ready()
which will setup the states.
ssm.ready()
As SSM is chaninable you can even fire the ssm.ready()
method by simply adding .ready()
onto your original command
ssm.addStates([ {id: 'mobile', width: 767, onEnter: function(){console.log('enter mobile')}}, {id: 'tablet',width: 1023, onEnter: function(){console.log('enter tablet')}}, {id: 'desktop',width: 9999, onEnter: function(){console.log('enter desktop')}} ]).ready();
Debug Mode
To enable the debug mode you simply need to run ssm.enableDebug()
, this will add a width meter to the bottom right corner of the viewport area.
ssm.enableDebug();
Full API
| Method | Description |
|---|---|
| ssm.addState | Add a new state, expects an object literal, properties avaliable - id (optional), width (required), onEnter (optional), onResize (optional), onLeave (optional) |
| ssm.addStates | Add multiple new states, expects an array of object literals, properties avaliable - id (optional), width (required), onEnter (optional), onResize (optional), onLeave (optional) |
| ssm.removeState | Remove a state, expects one property, the id of the state to be removed. |
| ssm.removeStates | Remove multiple states, expects an array of strings |
| ssm.removeAllStates | Clears all states from SSM |
| ssm.getState | Gets the current state |
| ssm.ready | Tells the page that states have been added and we can fire the onEnter event for the current state. |
| ssm.enableDebug | Enables a debug mode which shows a width meter to the corner of the page. |
Browser Support
There are a number of browsers that we have tested support, as we test more browsers we will update this list
- Chrome
- Firefox
- Internet Explorer 7+
- Safari
- Opera
Release Log
SimpleStateManager follows Semantic Versioning 2.0.0
1.3.0 - August 10, 2013
- Added .removeStates method
- Added unit tests using QUnit
- Integrated Travis CI
1.2.0 - August 9, 2013
- Added .getState method
1.1.0 - August 9, 2013
- Added .removeAllStates method
1.0.2 - August 6, 2013
- AMD Support
- Performance tweaks
- New Site
1.0.1 - Jun 24, 2013
- Added Debounce
1.0.0 - Jun 22, 2013
- Initial release
Planned Features
- Enable multiple methods to be attached to each state
- Allow overlapping states so that JS can span multiple states
Contribute
Anybody is welcome to contribute to this project, this is a community led library and you can get involved in the following ways
- Create Issues for bugs or new feature requests
- Fix any issues you have found and create a pull request
Typically master is the latest version of SSM, new features are pushed into branches and when a branch has been fully tested and all the features are complete it will be merged into master. The milestone assigned in GitHub should be used for the branch name.
Contributors
Licence
License: MIT (http://www.opensource.org/licenses/mit-license.php)


| Documentation Contents |
pack200 [ options ] output-file JAR-file
Options may be in any order. The last option on the command line or in a properties file supersedes all previously specified options.
options
- Command-line options.
output-file
- Name of the output file.
JAR-file
- Name of the input file.
The
pack200
tool is a Java application that transforms a JAR file into a compressedpack200
file using the Javagzip
compressor. Thepack200
files are highly compressed files that can be directly deployed, saving bandwidth and reducing download time.The
pack200
tool uses several options to fine-tune and set the compression engine.Typical usage:
% pack200 myarchive.pack.gz myarchive.jar
In this example,
myarchive.pack.gz
is produced using the defaultpack200
settings.
-r --repack
Produces a JAR file by packing the file
myarchive.jar
and unpacking it. The resulting file can be used as an input to thejarsigner(1)
tool.
% pack200 --repack myarchive-packer.jar myarchive.jar
% pack200 --repack myarchive.jar
-g --no-gzip
Produces a
pack200
file. With this option a suitable compressor must be used, and the target system must use a corresponding decompresser.
% pack200 --no-gzip myarchive.pack myarchive.jar
-G --strip-debug
Strips attributes used for debugging from the output. These include
SourceFile
,LineNumberTable
,LocalVariableTable
andLocalVariableTypeTable
. Removing these attributes reduces the size of both downloads and installations but reduces the usefulness of debuggers.
-O --no-keep-file-order
The packer will reorder and transmit all elements. Additionally, the packer may remove JAR directory names. This will reduce the download size; however, certain JAR file optimizations, such as indexing, may not work correctly.
-Svalue --segment-limit=value
The value is the estimated target size N (in bytes) of each archive segment. If a single input file requires
more than N bytes, it will be given its own archive segment. As a special case, a value of-1
will produce a single large segment with all input files, while a value of0
will produce one segment for each class. Larger archive segments result in less fragmentation and better compression, but processing them requires more memory.The size of each segment is estimated by counting the size of each input file to be transmitted in the segment, along with the size of its name and other transmitted properties.
The default is
1000000
(a million bytes). This allows input JAR files of moderate size to be transmitted in one segment. It also puts a limit on memory requirements for packers and unpackers.A 10MB JAR packed without this limit will typically pack about 10% smaller, but the packer may require a larger Java heap (about ten times the segment limit).
-Evalue --effort=value
If the value is set to a single decimal digit, the packer will use the indicated amount of effort in compressing the archive. Level
1
may produce somewhat larger size and faster compression speed, while level9
will take much longer but may produce better compression. The special value0
instructs the packer to copy through the original JAR file directly with no compression. The JSR 200 standard requires any unpacker to understand this special case as a pass-through of the entire archive.The default is
5
, investing a modest amount of time to produce reasonable compression.
-Hvalue --deflate-hint=value
Overrides the default, which preserves the input information, but may cause the transmitted archive to be larger. The possible values are:
true
false
- In either case, the packer will set the deflation hint accordingly in the output archive, and will not transmit the individual deflation hints of archive elements.
keep
- Preserve deflation hints observed in the input JAR. (This is the default.)
-mvalue --modification-time=value
The possible values are:
latest
- The packer will attempt to determine the latest modification time, among all the available entries in the original archive, or the latest modification time of all the available entries in that segment. This single value will be transmitted as part of the segment and applied to all the entries in each segment. This can marginally decrease the transmitted size of the archive at the expense of setting all installed files to a single date.
keep
- Preserves modification times observed in the input JAR. (This is the default.)
-Pfile --pass-file=file
Indicates that a file should be passed through bytewise with no compression. By repeating the option, multiple files may be specified. There is no pathname transformation, except that the system file separator is replaced by the JAR file separator "
/
". The resulting file names must match exactly as strings with their occurrences in the JAR file. If file is a directory name, all files under that directory will be passed.
-Uaction --unknown-attribute=action
Overrides the default behavior; i.e., the classfile containing the unknown attribute will be passed through with the specified action. The possible values for actions are:
error
- The
pack200
operation as a whole will fail with a suitable explanation.strip
- The attribute will be dropped. Note: Removing the required VM attributes may cause Class Loader failures.
pass
- Upon encountering this attribute, the entire class will be transmitted as though it is a resource.
-Cattribute-name=layout --class-attribute=attribute-name=action
-Fattribute-name=layout --field-attribute=attribute-name=action
-Mattribute-name=layout --method-attribute=attribute-name=action
-Dattribute-name=layout --code-attribute=attribute-name=action
With the above four options, the attribute layout can be specified for a class entity, such as Class attribute, Field attribute, Method attribute, and Code attribute. The attribute-name is the name of the attribute for which the layout or action is being defined. The possible values for action are:
some-layout-string
- The layout language is defined in the JSR 200 specification.
Example:
--class-attribute=SourceFile=RUH
error
- Upon encountering this attribute, the pack200 operation will fail with a suitable explanation.
strip
- Upon encountering this attribute, the attribute will be removed from the output. Note: removing VM-required attributes may cause Class Loader failures.
Example:
--class-attribute=CompilationID=pass
will cause the class file containing this attribute to be passed through without further action by the packer.
-f pack.properties --config-file=pack.properties
A configuration file, containing Java properties to initialize the packer, may be specified on the command line.
% pack200 -f pack.properties myarchive.pack.gz myarchive.jar
% more pack.properties
# Generic properties for the packer.
modification.time=latest
deflate.hint=false
keep.file.order=false
# This option will cause the files bearing new attributes to
# be reported as an error rather than passed uncompressed.
unknown.attribute=error
# Change the segment limit to be unlimited.
segment.limit=-1
-v --verbose
Outputs minimal messages. Multiple specification of this option will output more verbose messages.
-q --quiet
Specifies quiet operation with no messages.
-lfilename --log-file=filename
Specifies a log file to output messages.
-Joption
Passes option to the Java launcher called by
pack200
. For example,-J-Xms48m
sets the startup memory to 48 megabytes. Although it does not begin with-X
, it is not a standard option ofpack200
. It is a common convention for-J
to pass options to the underlying VM executing applications written in Java.
The following exit values are returned:
0
for successful completion;
>0
if an error occurs.
jar
- Java
Archive Tooljarsigner
- JAR Signer toolattributes(5)
man pageThis command should not be confused with
pack(1)
. They are distinctly separate products.The Java SE API Specification provided with the JDK is the superseding authority, in case of discrepancies.
Copyright © 1993, 2011, Oracle and/or its affiliates. All rights reserved. Please send comments using this Feedback page. |
Java Technology |


Integrate an Android Application with Custom Services Running in OpenShift
This document describes the steps needed to configure the Aerogear Android SDK to allow your Android app to interact with:
-
Your own backend services in OpenShift
-
External backend services
Procedure
For demonstration, this guide uses the example Python application which can be found in the OpenShift Service Catalog. The same steps can be followed any HTTP web service running in OpenShift that has a publicly accessible route.
Pictured below is the example Python application, and the Android mobile app record provisioned in OpenShift.
Provision the Custom Runtime Connector
We can connect our mobile app record to our backend service by provisioning a Custom Runtime Connector from the OpenShift Service Catalog.
-
Select the Custom Runtime Connector from the Service Catalog.
-
Put the service name in the service name field. This name will be used in the SDK to retrieve details about the service.
-
Put the publicly accessible url of the service in the Service URL field.
-
In the Service Config field, place any additional configuration that might be needed by the mobile app in order to communicate with the backend service. This must be a valid JSON format.
-
Click 'Create'.
Note that provisioning the Custom Runtime Connector simply creates a Config Map that is used to populate the mobile-services.json
file which is consumed by your mobile application. It does not deploy any new services.
Add the Custom Runtime Connector Service to the mobile app record
-
Click the mobile app record to reveal the JSON configuration. The 'services' list is empty.
-
Click the 'Add Service' button and select 'custom-runtime-connector' from the dropdown menu.
-
The 'services' list in the mobile app record Configuration now includes a configuration object that contains details related to your backend service such as the name, uri and custom configuration.
Integrate your Android Application with the Custom Service
Take a copy of the JSON configuration from the mobile app record and save it in app/src/main/assets/mobile-services.json
in your Android application’s source code.
Now the Aerogear SDK can be used to get the configuration for your custom service and it is possible to make requests. Please look at the example code below:
// get the service URL
final ServiceConfiguration serviceConfiguration = mobileCore.getServiceConfiguration("custom-runtime-connector");
final String serviceUrl = serviceConfiguration.getUrl();
// make the request
HttpRequest httpRequest = mobileCore.getHttpLayer().newRequest();
httpRequest.get(serviceUrl);
HttpResponse httpResponse = httpRequest.execute();
httpResponse.onError(() -> {
// handle error
});
httpResponse.onSuccess(() -> {
// handle success
});
httpResponse.onComplete(() -> {
// called regardless success or error
});


Web Developer
"Nothing is certain in this life. What’s certain is that if you do nothing out of the ordinary, nothing out of the ordinary will ever happen to you."
AboutMy admiration for computers was conceived at the age of eight, when my father purchased my first laptop. The internet was only in its inceptive stages, yet I grew very fond of it. I began to explore HTML and CSS, but never pursued learning of full stack programming language. After working in the IT industry as a business manager, I chose to switch career paths to full stack web development. I was fully aware of the challenges this may pose. I initially began by applying to Coding Dojo; it was an amazing experience. I quickly grasped the various elements of Web Fundamentals, Python/Django, and MEAN Angular JS. Programming was, and continues to be, a never ending adventure. Personal development is continuous, and very fulfilling, in this field. My advice to readers even remotely considering this career - do it! It will change the way you look at the modern world with endless possibiltiies to integrate your skills into the web.
Python/Django application: Login and Registration with validations. The app displays the logged user's created travel plans; Also displays other users' travel plans. The travel plans are specific to user. User can join other users' travel plans. Once the user clicks join, the record moves to the main Travel Schedule table. The data is stored and retrieved from SQLite Database, which has 3 models (User, Travel, UserTravel). User and Travel models has many-to-many relationship.
Github LinkPython/Django application: A mini-game that helps a ninja make some money! When you start the game, your ninja has 0 gold. The ninja can go to different places (farm, cave, house, casino) and earn different amounts of gold. In the case of a casino, ninja can earn or lose up to 50 golds. The app allows ninja to earn gold and display past activities of this ninja. Activity logs are saved in session
Github LinkFlask + MySQL application: Login and Registration with Validations. A wall/forum page where users will are able to post a message and see the message displayed by other users. Stores the messages in a table called 'messages' and retrieves the messages from the MySQL database.
Github LinkAngular app which presents the user with 6 different views, each different url/view present the user with a city. Within each of these views, the user can see current weather information. This assignment required an API Key retrieval from https://openweathermap.org/api
Github Link


Tesco's Christmas Ad Causes a Stir Before It Even Airs
by Shabana ArifIt turns out that popping a van on the roof of a house garners a bit of attention.
The people of Knutsford, an hilariously named town on the outskirts of Manchester, had a little bit of excitement this week with the appearance of a Tesco delivery van decked out in Christmas lights on the roof. Upon further investigation it seems that the event wasn't tied to a directionally challenged driver, but part of a Christmas ad for the supermarket.
"Seeing one of our Tesco delivery vans sat on the roof of a cottage caught everyone by surprise this morning," said Tesco chief customer officer, Alessandra Bellini. "It is certainly not something you see every day, but I suspect that anyone watching ITV this Sunday night will have all their questions answered.”
The advert will reportedly run this Sunday night, during I’m a Celebrity. Presumably Santa loses his reindeer in a close brush with a plane engine, and commandeered a Tesco van at candy cane point because someone has got to get those presents out.


Introduction
Welcome to the HelloBooks API! You can use our API to access HelloBooks API endpoints, which can get information on various books and users in our database.
You can view code examples in the dark area to the right.
HTTP Request url must be prepended with the base url
BASE URL = http://hellobooks.herokuapp.com/api/v1
Authentication
To authorize,
add `authenticate-token` to your request header.
Its value must be a valid signed JWT token.
HelloBooks uses JWT to authenticate a user. The JWT token must be signed by the application and it has an expiry time of 24hours.
HelloBooks expects that the token is included in every request like:
authenticate-token: eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9...
Login
Request body
{
"email"<EMAIL_ADDRESS>"password": "password"
}
Response body (application/json)
{
"message": "Successfully validated",
"user": {
"token": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9...",
"userId": 1,
"group": "user"
}
}
This endpoint logs a user into the application. The token should be included in subsequent request header.
HTTP Request
POST /users/signin
HTTP Response
200 OK
Users
Create a user
Request body
{
"email"<EMAIL_ADDRESS>"password": "password",
"confirmPassword": "password",
"name": "name"
}
Response body (application/json)
{
"message": "Your account has been created successfully",
"user": {
"token": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9...",
"userId": 1,
"group": "user"
}
}
This endpoint creates a user record.
HTTP Request
POST /users/signup
HTTP Response
201 Created
Send reset password
Request body
{
"email"<EMAIL_ADDRESS>}
Response body (application/json)
{
"message": "A password reset link has been sent to<EMAIL_ADDRESS>It may take upto 5 mins for the mail to arrive."
}
This endpoint sends a reset password link to the user associated with the provided email address
HTTP Request
POST /users/reset-password
HTTP Response
200 OK
Change password on reset
Request body
{
"email"<EMAIL_ADDRESS>"password": "new password",
"confirmPassword": "new password",
"validationKey": "dfghjkhg32ft4678u9dihbrfvbi3r"
}
Response body (application/json)
{
"message": "Password successfully changed. Please login to your account."
}
This endpoint changes a user's password after the user has click on the reset password link
HTTP Request
POST /users/reset-password/verify
HTTP Response
200 OK
Change password in profile
Request body
{
"oldPassword": "old password",
"password": "new password",
"confirmPassword": "new password"
}
Response body (application/json)
{
"message": "Your password has been changed successfully"
}
This endpoint is for authenticated users to changes their password
HTTP Request
PUT /users/:userId
HTTP Response
200 OK
Get all users
Request body
{ }
Response body (application/json)
{
"users": [
{
"createdAt": "2017-12-11T16:27:39.497Z"
"email"<EMAIL_ADDRESS>"id": 1
"name": "John Doe"
"updatedAt": "2017-12-11T16:27:39.497Z"
"userRank": "beginner"
}
]
}
This endpoint gets all users or a particular user by id
HTTP Request
GET /users/[,:userId]
HTTP Response
200 OK
URL Parameters
| Parameter | Description |
|---|---|
| userId | The ID of the user |
Categories
Create a category
Request body
{
"name": "African Fiction"
}
Response body (application/json)
{
"message": ["Category added successfully"],
"id": 1,
"category":
{
"id": 1,
"name": "African Fiction",
"createdAt": "2017-12-12T16:27:39.497Z",
"updatedAt": "2017-12-12T16:27:39.497Z"
}
}
This endpoint creates a category.
HTTP Request
POST /books/categories
HTTP Response
201 Created
Edit a category
Request body
{
"name": "African Fiction & tales"
}
Response body (application/json)
{
"message": ["Category updated successfully"],
"category":
{
"id": 1,
"name": "African Fiction & tales",
"createdAt": "2017-12-12T16:27:39.497Z",
"updatedAt": "2017-12-12T16:27:39.497Z"
}
}
This endpoint updates a category.
HTTP Request
PUT /books/:categoryId
HTTP Response
200 OK
URL Parameters
| Parameter | Description |
|---|---|
| categoryId | The ID of the book |
Get categories
Request body
{ }
Response body (application/json)
{
"categories": [
{
"id": 1,
"name": "African Fiction and tales",
"createdAt": "2017-12-12T16:27:39.497Z",
"updatedAt": "2017-12-12T16:27:39.497Z"
}
]
}
This endpoint get all categiories or by category id.
HTTP Request
GET /books/categiories/[,:categoryId]
HTTP Response
200 OK
URL Parameters
| Parameter | Description |
|---|---|
| categoryId | The ID of the category |
Delete a category
Request body
{ }
Response body (application/json)
{
"message": ["Category deleted successfully"]
}
This endpoint deletes a category by id
HTTP Request
DELETE /books/categories/:categoryId
HTTP Response
200 OK
URL Parameters
| Parameter | Description |
|---|---|
| categoryId | The ID of the category |
Books
Create a book
Request body
{
"title": "Half of a yellow sun",
"description": "A sweet book from Chimamanda Adichie",
"bookCategoryId": 1,
"ISBN": "1234567890",
"stockQuantity": 3,
"publishedYear": 2015,
"author": "Chimanmanda Adichie",
"bookURL": "",
"coverPhotoPath": "",
"documentPath": "",
"userId": 1
}
Response body (application/json)
{
"message": ["Book added successfully"],
"id": 1,
"book":
{
"id": 1,
"title": "Half of a yellow sun",
"description": "A sweet book from Chimamanda Adichie",
"bookCategoryId": 1,
"ISBN": "1234567890",
"stockQuantity": 3,
"publishedYear": 2015,
"author": "Chimanmanda Adichie",
"bookURL": "",
"coverPhotoPath": "",
"documentPath": "",
"userId": 1,
"createdAt": "2017-12-12T16:27:39.497Z",
"updatedAt": "2017-12-12T16:27:39.497Z"
}
}
This endpoint creates a book.
HTTP Request
POST /books
HTTP Response
201 Created
Edit a book
Request body
{
"title": "Half of a yellow sun",
"description": "A sweet book from Chimamanda Adichie",
"bookCategoryId": 1,
"ISBN": "1234567890",
"publishedYear": 2015,
"author": "Chimanmanda Adichie",
"bookURL": "",
"coverPhotoPath": "http://res.cloudinary.com/johndoe/image/upload/v1512654679/qclzzr...mwf8ktc.png",
"documentPath": "",
"userId": 1
}
Response body (application/json)
{
"message": ["Book successfully editted"],
"book":
{
"id": 1,
"title": "Half of a yellow sun",
"description": "A sweet book from Chimamanda Adichie",
"bookCategoryId": 1,
"ISBN": "1234567890",
"stockQuantity": 3,
"publishedYear": 2015,
"author": "Chimanmanda Adichie",
"bookURL": "",
"coverPhotoPath": "http://res.cloudinary.com/johndoe/image/upload/v1512654679/qclzzr...mwf8ktc.png",
"documentPath": "",
"userId": 1,
"createdAt": "2017-12-12T16:27:39.497Z",
"updatedAt": "2017-12-12T16:27:39.497Z"
}
}
This endpoint edits a book.
HTTP Request
PUT /books/:bookId
HTTP Response
200 OK
URL Parameters
| Parameter | Description |
|---|---|
| bookId | The ID of the book |
Query Parameters
| Parameter | Default | Description |
|---|---|---|
| fields | undefined | If defined, it will set the columns to update to the ones specified in the query parameter. It's an array of fields |
Get books
Request body
{ }
Response body (application/json)
{
"books": [
{
"id": 1,
"title": "Half of a yellow sun",
"description": "A sweet book from Chimamanda Adichie",
"bookCategoryId": 1,
"ISBN": "1234567890",
"stockQuantity": 3,
"publishedYear": 2015,
"author": "Chimanmanda Adichie",
"bookURL": "",
"coverPhotoPath": "http://res.cloudinary.com/johndoe/image/upload/v1512654679/qclzzr...mwf8ktc.png",
"documentPath": "",
"userId": 1,
"createdAt": "2017-12-12T16:27:39.497Z",
"updatedAt": "2017-12-12T16:27:39.497Z"
}
],
"pagination": {
"pageSize": 1,
"totalCount": 1,
"page": 0,
"pageCount": 0,
"limit": 12
}
}
This endpoint get all books or by book id.
HTTP Request
GET /books/[,:bookId]
HTTP Response
200 OK
URL Parameters
| Parameter | Description |
|---|---|
| bookId | The ID of the book |
Query Parameters
| Parameter | Default | Description |
|---|---|---|
| offset | 0 | Sets the offset for pagination |
| limit | 12 | The number of books to display per page |
| author | undefined | Filter by author name |
| title | undefined | Filter by book title |
| bookCategoryId | undefined | Filter by book category |
Search for books
Request body
{ }
Response body (application/json)
{
"message": ["Book found"],
"books": [
{
"id": 1,
"title": "Half of a yellow sun",
"description": "A sweet book from Chimamanda Adichie",
"bookCategoryId": 1,
"ISBN": "1234567890",
"stockQuantity": 3,
"publishedYear": 2015,
"author": "Chimanmanda Adichie",
"bookURL": "",
"coverPhotoPath": "http://res.cloudinary.com/johndoe/image/upload/v1512654679/qclzzr...mwf8ktc.png",
"documentPath": "",
"userId": 1,
"createdAt": "2017-12-12T16:27:39.497Z",
"updatedAt": "2017-12-12T16:27:39.497Z"
}
]
}
This endpoint searches for a book
HTTP Request
GET /search
HTTP Response
200 OK
Query Parameters
| Parameter | Default | Description |
|---|---|---|
| type | undefined | Sets the type of searching that is being done. Possible parameters is 'books' |
| q | undefined | The search query string |
Delete a book
Request body
{ }
Response body (application/json)
{
"message": ["Book deleted successfully"]
}
This endpoint get all books or by book id.
HTTP Request
DELETE /books/{,:bookId}
HTTP Response
200 OK
URL Parameters
| Parameter | Description |
|---|---|
| bookId | The ID of the book |
Borrowed Books
Borrow a book
Request body
{
"bookId": 1
}
Response body (application/json)
{
"message": ["You have successfully borrowed this book"],
"id": 1
}
This endpoint allows a user to borrow a book
HTTP Request
POST /users/:userId/books
HTTP Response
201 Created
URL Parameters
| Parameter | Description |
|---|---|
| userId | The ID of the user |
Return a borrowed book
Request body
{ }
Response body (application/json)
{
"message": ["You have successfully returned this book"]
}
This endpoint returns a borrowed book
HTTP Request
PUT /users/:userId/books/:borrowedBookId
HTTP Response
200 OK
URL Parameters
| Parameter | Description |
|---|---|
| userId | The ID of the user |
| borrowedBookId | The ID of the borrowed book |
Query Parameters
| Parameter | Default | Description |
|---|---|---|
| bookId | undefined | If defined, it will set the bookId of the book that is being returned. |
Get borrowed books
Request body
{ }
Response body (application/json)
{
"books": [
{
"id": 1,
"title": "Half of a yellow sun",
"description": "A sweet book from Chimamanda Adichie",
...
"createdAt": "2017-12-12T16:27:39.497Z",
"updatedAt": "2017-12-12T16:27:39.497Z"
}
],
"message": ["Success"]
}
This endpoint gets all the books that have been borrowed but are yet to be returned
HTTP Request
GET /users/:userId/books
HTTP Response
200 OK
URL Parameters
| Parameter | Description |
|---|---|
| userId | The ID of the user |
Query Parameters
| Parameter | Default | Description |
|---|---|---|
| bookId | 0 | Sets the id of the book that has been borrowed |
| returned | false | The return status of the book |
Get borrowed books history
Request body
{ }
Response body (application/json)
{
"books": [
{
"id": 1,
"title": "Half of a yellow sun",
"description": "A sweet book from Chimamanda Adichie",
...
"createdAt": "2017-12-12T16:27:39.497Z",
"updatedAt": "2017-12-12T16:27:39.497Z"
}
...
],
"pagination": {
"pageSize": 1,
"totalCount": 1,
"page": 0,
"pageCount": 0,
"limit": 12
}
}
This endpoint gets borrowed book histories based on some criteria
HTTP Request
GET /books/histories/:userId
HTTP Response
200 OK
URL Parameters
| Parameter | Description |
|---|---|
| userId | The ID of the user |
Query Parameters
| Parameter | Default | Description |
|---|---|---|
| offset | 0 | Sets the offset for pagination |
| limit | 12 | The number of histories to display per page |
| isReturned | undefined | Sets the returned status of the borrowed book |
| updatedAt | undefined | Filter by updatedAt |
Delete a book
Request body
{ }
Response body (application/json)
{
"message": ["Book deleted successfully"]
}
This endpoint get all books or by book id.
HTTP Request
DELETE /books/[,:bookId]
HTTP Response
200 OK
URL Parameters
| Parameter | Description |
|---|---|
| bookId | The ID of the book |
Stocks
Create a stock
Request body
{
"bookId": 1,
"quantity": 5
}
Response body (application/json)
{
"message": ["Stock added successfully"],
"id": 1,
"stock":
{
"id": 1,
"bookId": 1,
"quantity": 8
"createdAt": "2017-12-12T16:27:39.497Z",
"updatedAt": "2017-12-12T16:27:39.497Z",
"book": {
"id": 1,
"title": "Half of a yellow sun",
"description": "A sweet book from Chimamanda Adichie",
"bookCategoryId": 1,
"ISBN": "1234567890",
...
"userId": 1,
"createdAt": "2017-12-12T16:27:39.497Z",
"updatedAt": "2017-12-12T16:27:39.497Z"
}
}
}
This endpoint creates a stock.
HTTP Request
POST /books/stocks
HTTP Response
201 Created
Get stocks
Request body
{ }
Response body (application/json)
{
"stocks": [
{
"bookId": 1,
"quantity": 8
"createdAt": "2017-12-12T16:27:39.497Z",
"updatedAt": "2017-12-12T16:27:39.497Z"
}
]
}
This endpoint get all stocks or by book id.
HTTP Request
GET /books/stocks/[,:bookId]
HTTP Response
200 OK
Query Parameters
| Parameter | Default | Description |
|---|---|---|
| bookId | undefined | If defined, gets stock by book Id |
Delete a stock
Request body
{ }
Response body (application/json)
{
"message": ["Stock deleted successfully"]
}
This endpoint delete stock by stock id
HTTP Request
DELETE /stocks/[,:stockId]
HTTP Response
200 OK
URL Parameters
| Parameter | Description |
|---|---|
| stockId | The ID of the stock |
Notifications
Get notifications
Request body
{ }
Response body (application/json)
{
"notifications": [
{
"id": 1,
"bookId": 1,
"userId": 1,
"notificationType": "BOOK_RETURNED",
"createdAt": "2017-12-12T16:27:39.497Z",
"updatedAt": "2017-12-12T16:27:39.497Z",
"Book": {
...
},
"User": {
...
},
}
]
}
This endpoint get all notifications and can filter the result
HTTP Request
GET /notifications
HTTP Response
200 OK
Query Parameters
| Parameter | Default | Description |
|---|---|---|
| offset | 0 | Sets the offset for pagination |
| limit | 12 | The number of books to display per page |
| notificationType | undefined | Filter by the type of notification; BOOK_RETURNED or BOOK_BORROWED |
| name | undefined | Filter by user's name |
Handling Errors
All response messages are returned as an array with a message
key in the response body.
Sample validation error
Status code = 400 Bad Request
{
"message": [
"The name field is required",
"The email field is required",
"The password and confirm password fields is required"
]
}
Sample server error
Status code = 500 Internal Server Error
{
"message": [
"There was an error processing your request. \
You don't need to do anything else. \
Our engineers are on it. "
]
}
Status Code References
The HelloBooks API uses the following status codes:
| Error Code | Meaning |
|---|---|
| 400 | Bad Request -- Validation errors. |
| 401 | Unauthorized -- Your API key is wrong. |
| 403 | Forbidden -- Either the resource requested is meant for authenticated user or administrator only. |
| 404 | Not Found -- The specified resource could not be found. |
| 409 | Conflict -- The resource you are updating or creating already exist. |
| 500 | Internal Server Error -- We had a problem with our server. Try again later. |


This demo illustrates how D3 leverages quantitative scales to translate from a continuous data-domain to a continuous output range. It is also an opportunity to practice rendering axis components to indicate the
meaning of the scale, and walk through the standard data-join process for D3. In your js/main.js
file, do the following:
d3.min
and d3.max
to determine the domain of your scalemy-svg
and assign it a width of 600 and a height of 100g
element with class axis
to your svg. Shift it down 50 pixels by setting the transform
property, and then use the .call
method to render your axis in the g
element.


{% extends "layout/base.html" %} {% block content %}
Company Detail View
> list of created games
{{ object.name }}
{{ i.name }}


"What you are seeing in Iraq is a Second Amendment War."
I disagree with the author’s claim that combat robotics are somehow fundamentally any different from any other weapon. However, the analysis of the 2nd Amendment in practice is spot-on.
I disagree with the author’s claim that combat robotics are somehow fundamentally any different from any other weapon. However, the analysis of the 2nd Amendment in practice is spot-on.


class AdminUser extends SiteUser
HealthCareAbroad\UserBundle\Entity\AdminUser
Constants
| STATUS_INACTIVE |
|
| STATUS_ACTIVE |
|
Methods
|
setAccountId(bigint $accountId)
Set account id |
from SiteUser | |
| bigint |
getAccountId()
Get accountId |
from SiteUser |
| setEmail($email) | from SiteUser | |
| getEmail() | from SiteUser | |
| setPassword($password) | from SiteUser | |
| getFirstName() | from SiteUser | |
| setFirstName($firstName) | from SiteUser | |
| getMiddleName() | from SiteUser | |
| setMiddleName($middleName) | from SiteUser | |
| getLastName() | from SiteUser | |
| setLastName($lastName) | from SiteUser | |
|
getPassword()
UserInterface |
from SiteUser | |
| getSalt() | from SiteUser | |
| getUsername() | from SiteUser | |
| getRoles() | from SiteUser | |
| eraseCredentials() | from SiteUser | |
| __toString() | from SiteUser | |
| getFullName() | from SiteUser | |
| AdminUser |
setStatus(boolean $status)
Set status |
|
| boolean |
getStatus()
Get status |
|
| AdminUser |
setAdminUserType(AdminUserType $adminUserType = null)
Set adminUserType |
|
| AdminUserType |
getAdminUserType()
Get adminUserType |
Details
in SiteUser at line 29
public
setAccountId(bigint $accountId)
Set account id
in SiteUser at line 39
public bigint
getAccountId()
Get accountId
in SiteUser at line 44
public
setEmail($email)
in SiteUser at line 51
public
getEmail()
in SiteUser at line 56
public
setPassword($password)
in SiteUser at line 63
public
getFirstName()
in SiteUser at line 68
public
setFirstName($firstName)
in SiteUser at line 75
public
getMiddleName()
in SiteUser at line 80
public
setMiddleName($middleName)
in SiteUser at line 87
public
getLastName()
in SiteUser at line 92
public
setLastName($lastName)
in SiteUser at line 103
public
getPassword()
UserInterface
in SiteUser at line 108
public
getSalt()
in SiteUser at line 113
public
getUsername()
in SiteUser at line 118
public
getRoles()
in SiteUser at line 123
public
eraseCredentials()
in SiteUser at line 128
public
__toString()
in SiteUser at line 133
public
getFullName()
at line 28
public AdminUser
setStatus(boolean $status)
Set status
at line 39
public boolean
getStatus()
Get status
at line 50
public AdminUser
setAdminUserType(AdminUserType $adminUserType = null)
Set adminUserType
at line 61
public AdminUserType
getAdminUserType()
Get adminUserType


>>
<<
Usr
Pri
JfC
LJ
Phr
Dic
Voc
!:
Help
Primer
J way of adding lists
J knows how to do things to single numbers, but it also knows how to do things with lists.
Since J knows how to add lists, you can write a third, simpler version of the definition.
addb =: 4 : 'x + y'
Add this definition to your temporary script file, run the script, and test it.
2 3 4 addb 4 5 6
6 8 10
At this point you probably realize that addb is so simple as to be unnecessary.
2 3 4 + 4 5 6
6 8 10
In J you can just add the lists of numbers because the + verb knows all about lists of numbers.
Years of research and thought have gone into how J verbs work with lists. For example, if you wanted to add 1 to each number in a list.
1 adda 2 3 4
3
The Basic style adda verb gives an answer, but it is the wrong answer. What happens is that the while. uses the count of the left argument (which is 1) to determine how many elements to generate in the result, and so calculates only the first result number.
2 3 4 adda 1
|index error
| r=.r,(i{x.)+(i {y.)
This gives an error because the while. uses a count of 3 (the count of numbers in the left argument) but the right argument doesn't have that many so you get an error.
But the J + handles both these cases the way you would like, and would expect!
1 + 2 3 4
3 4 5
2 3 4 + 1
3 4 5
Thank goodness the addlists and adda verbs are in a temporary file and are easy to get rid of, because clearly you don't need them in J. Close and delete that temporary script now.
The simple concept of working with lists, instead of just single things, extends throughout J.
2 4 6 * 7 8 9
14 32 54
2 * 2 3 4
4 6 8
2 3 4 * 2
4 6 8
5 6 7 % 2
2.5 3 3.5
2 3 4 - 3
_1 0 1
It works for the comparatives as well.
2 3 4 = 7 3 8
0 1 0
2 < 0 1 2 3 4 5
0 0 0 1 1 1
't' = 'testing'
1 0 0 1 0 0 0
If this works for primitives, what about verbs such as centigrade?
Run your cf.ijs script to define your verbs and see what happens.
centigrade _40 32 212
_40 0 100
You can apply your centigrade verb to a list of numbers and get a list of results. This also work for fahrenheit.
fahrenheit _40 0 100
_40 32 212
What about your dyad convert?
'c' convert _40 32 212
_40 0 100
'f' convert _40 0 32 100 212
_40 32 89.6 212 413.6
The extension of verbs to work consistently on lists is very powerful and significantly distinguishes J from most other languages. It is important that you assimilate this into the way you think about solving problems.
>>
<<
Usr
Pri
JfC
LJ
Phr
Dic
Voc
!:
Help
Primer


| Total net profit | -89.0 | Gross profit | 9.77 | Gross loss | -98.77 |
| Profit factor | 0.1 | Expected payoff | -2.23 | ||
| Absolute drawdown | -89.0 | Maximal drawdown (%) | 85.54 (-2472.25%) | ||
| Total trades | 40 | Profit trades (% of total) | 2 (5.0%) | Loss trades (% of total) | 38 (95.0%) |
| Long positions (won %) | 20 (5.0%) | Short positions (won %) | 20 (5.0%) | ||
| Largest | profit trade | 6.36 | loss trade | -3.75 | |
| Average | profit trade | 4.88 | loss trade | -2.6 | |
| Minimum | profit trade | 3.41 | loss trade | -0.87 | |
| Maximum | take profit in pips | 178.2 | stop loss in pips | -45.9 | |
| Average | take profit in pips | 172.1 | stop loss in pips | -27.8 | |
| Minimum | take profit in pips | 154.9 | stop loss in pips | -20.5 | |
| Maximum | Reward-Risk | 8.6 | Duration in minutes | 2975 | |
| Average | Reward-Risk | 6.5 | Duration in minutes | 385.3 | |
| Minimum | Reward-Risk | 3.4 | Duration in minutes | 0 | |
| Maximum | consecutive wins (profit in money) | 1.0 (3.41) | consecutive losses (loss in money) | 17.0 (-48.24) | |
| Average | consecutive wins | 1.0 | consecutive losses | 12.0 |
| Total net profit | -37.93 | Gross profit | 6.36 | Gross loss | -44.29 |
| Profit factor | 0.14 | Expected payoff | -1.9 | ||
| Absolute drawdown | -37.93 | Maximal drawdown (%) | 34.58 (-1032.24%) | ||
| Total trades | 20 | Profit trades (% of total) | 1 (5.0%) | Loss trades (% of total) | 19 (95.0%) |
| Largest | profit trade | 6.36 | loss trade | -3.53 | |
| Average | profit trade | 6.36 | loss trade | -2.33 | |
| Minimum | profit trade | 6.36 | loss trade | -0.87 | |
| Maximum | take profit in pips | 178.2 | stop loss in pips | -34.8 | |
| Average | take profit in pips | 173.6 | stop loss in pips | -26.4 | |
| Minimum | take profit in pips | 167.9 | stop loss in pips | -21.3 | |
| Maximum | Reward-Risk | 8.2 | Duration in minutes | 2975.0 | |
| Average | Reward-Risk | 6.8 | Duration in minutes | 383.4 | |
| Minimum | Reward-Risk | 5.0 | Duration in minutes | 1.0 | |
| Maximum | consecutive wins (profit in money) | 1.0 (6.36) | consecutive losses (loss in money) | 10.0 (-18.16) | |
| Average | consecutive wins | 1.0 | consecutive losses | 9.0 |
| Total net profit | -51.07 | Gross profit | 3.41 | Gross loss | -54.48 |
| Profit factor | 0.06 | Expected payoff | -2.55 | ||
| Absolute drawdown | -51.07 | Maximal drawdown (%) | 47.61 (-1376.01%) | ||
| Total trades | 20 | Profit trades (% of total) | 1 (5.0%) | Loss trades (% of total) | 19 (95.0%) |
| Largest | profit trade | 3.41 | loss trade | -3.75 | |
| Average | profit trade | 3.41 | loss trade | -2.87 | |
| Minimum | profit trade | 3.41 | loss trade | -2.06 | |
| Maximum | take profit in pips | 175.9 | stop loss in pips | -45.9 | |
| Average | take profit in pips | 170.5 | stop loss in pips | -29.3 | |
| Minimum | take profit in pips | 154.9 | stop loss in pips | -20.5 | |
| Maximum | Reward-Risk | 8.6 | Duration in minutes | 1321.0 | |
| Average | Reward-Risk | 6.1 | Duration in minutes | 387.2 | |
| Minimum | Reward-Risk | Duration in minutes | 0.0 | ||
| Maximum | consecutive wins (profit in money) | 1.0 (3.41) | consecutive losses (loss in money) | 12.0 (-31.66) | |
| Average | consecutive wins | 1.0 | consecutive losses | 7.0 |