| Property starting with A |
| Name |
Caption |
Description |
Type |
Mandatory |
Name (known in REST) |
Available since release |
Introduced by which team |
Introduced for which project |
Additional remarks |
|
AddExtraReceiptToOrder
|
Add extra receipt to sales order
|
Add extra receipt to sales order
|
Boolean
|
|
AddExtraReceiptToOrder
|
|
|
|
|
|
Assortment
|
Assortment
|
Assortment
|
Number
|
|
Assortment
|
|
|
|
|
|
AvailableFrom
|
Active from
|
Active from
|
Date
|
|
AvailableFrom
|
|
|
|
|
|
AvailableUntil
|
Active To
|
Active To
|
Date
|
|
AvailableUntil
|
|
|
|
|
| Property starting with C |
| Name |
Caption |
Description |
Type |
Mandatory |
Name (known in REST) |
Available since release |
Introduced by which team |
Introduced for which project |
Additional remarks |
|
CommissionMethod
|
Commission Method
|
Commission Method
|
String
|
|
CommissionMethod
|
|
|
|
|
|
CommissionValue
|
Commission Value
|
Commission Value
|
Number
|
|
CommissionValue
|
|
|
|
|
|
CompanyCode
|
|
|
String
|
|
CompanyCode
|
|
|
|
|
|
CompanyName
|
|
|
String
|
|
CompanyName
|
|
|
|
|
|
Condition
|
Status
|
Status
|
String
|
|
Condition
|
|
|
|
|
|
CostPriceStandard
|
Cost price
|
Cost price
|
Number
|
|
CostPriceStandard
|
|
|
|
|
| Property starting with F |
| Name |
Caption |
Description |
Type |
Mandatory |
Name (known in REST) |
Available since release |
Introduced by which team |
Introduced for which project |
Additional remarks |
|
FreeValue1
|
Free value 1
|
Free value 1
|
Number
|
|
FreeValue1
|
|
|
|
|
|
FreeValue2
|
Free value 2
|
Free value 2
|
Number
|
|
FreeValue2
|
|
|
|
|
| Property starting with G |
| Name |
Caption |
Description |
Type |
Mandatory |
Name (known in REST) |
Available since release |
Introduced by which team |
Introduced for which project |
Additional remarks |
|
GLAccountAsset
|
|
|
String
|
|
GLAccountAsset
|
|
|
|
|
|
GLAccountAssetDescription
|
|
|
String
|
|
GLAccountAssetDescription
|
|
|
|
|
|
GLAccountCost
|
G/L Account
|
G/L Account
|
String
|
|
GLAccountCost
|
|
|
|
|
|
GLAccountCostDescription
|
|
|
String
|
|
GLAccountCostDescription
|
|
|
|
|
|
GLAccountDiscount
|
Account for discount
|
Account for discount
|
String
|
|
GLAccountDiscount
|
|
|
|
|
|
GLAccountDistribution
|
G/L Account
|
G/L Account
|
String
|
|
GLAccountDistribution
|
|
|
|
|
|
GLAccountDistributionDescription
|
|
|
String
|
|
GLAccountDistributionDescription
|
|
|
|
|
|
GLAccountRevenue
|
G/L Account
|
G/L Account
|
String
|
|
GLAccountRevenue
|
|
|
|
|
|
GLAccountRevenueDescription
|
|
|
String
|
|
GLAccountRevenueDescription
|
|
|
|
|
|
GLAccountStkChange
|
|
|
String
|
|
GLAccountStkChange
|
|
|
|
|
|
GLAccountStkCoverage
|
|
|
String
|
|
GLAccountStkCoverage
|
|
|
|
|
| Property starting with I |
| Name |
Caption |
Description |
Type |
Mandatory |
Name (known in REST) |
Available since release |
Introduced by which team |
Introduced for which project |
Additional remarks |
|
ID
|
|
|
Number
|
|
ID
|
|
|
|
|
|
IncrementFactor
|
Increment factor
|
Increment factor
|
Number
|
|
IncrementFactor
|
|
|
|
|
|
IntrastatEnabled
|
Intrastat enabled
|
Intrastat enabled
|
Boolean
|
|
IntrastatEnabled
|
|
|
|
|
|
IsAssembled
|
Make
|
Make
|
Boolean
|
|
IsAssembled
|
|
|
|
|
|
IsBackOrderItem
|
From stock
|
From stock
|
Boolean
|
|
IsBackOrderItem
|
|
|
|
|
|
IsBatchItem
|
Batch
|
Batch
|
Boolean
|
|
IsBatchItem
|
|
|
|
|
|
IsCommissionable
|
Commissionable
|
Commissionable
|
Boolean
|
|
IsCommissionable
|
|
|
|
|
|
IsDiscount
|
No discount
|
No discount
|
Boolean
|
|
IsDiscount
|
|
|
|
|
|
IsExplode
|
Explode
|
Explode
|
Boolean
|
|
IsExplode
|
|
|
|
|
|
IsFractionAllowedItem
|
Divisible
|
Divisible
|
Boolean
|
|
IsFractionAllowedItem
|
|
|
|
|
|
IsPurchaseItem
|
IsPurchaseItem
|
IsPurchaseItem
|
Boolean
|
|
IsPurchaseItem
|
|
|
|
|
|
IsSalesItem
|
Sales
|
Sales
|
Boolean
|
|
IsSalesItem
|
|
|
|
|
|
IsSerialNumberItem
|
Serial number
|
Serial number
|
Boolean
|
|
IsSerialNumberItem
|
|
|
|
|
|
IsServiceItem
|
Service
|
Service
|
Boolean
|
|
IsServiceItem
|
|
|
|
|
|
IsStockItem
|
Stock controlled
|
Stock controlled
|
Boolean
|
|
IsStockItem
|
|
|
|
|
|
IsSubAssemblyItem
|
Part
|
Part
|
Boolean
|
|
IsSubAssemblyItem
|
|
|
|
|
|
IsTextItem
|
Text
|
Text
|
Boolean
|
|
IsTextItem
|
|
|
|
|
|
ItemCode
|
|
|
String
|
|
ItemCode
|
|
|
|
|
|
ItemDescription
|
|
|
String
|
|
ItemDescription
|
|
|
|
|
|
ItemReplacementCode
|
Replacement
|
Replacement
|
String
|
|
ItemReplacementCode
|
|
|
|
|
| Property starting with L |
| Name |
Caption |
Description |
Type |
Mandatory |
Name (known in REST) |
Available since release |
Introduced by which team |
Introduced for which project |
Additional remarks |
|
LinkItemCode
|
Extra charges
|
Extra charges
|
String
|
|
LinkItemCode
|
|
|
|
|
| Property starting with N |
| Name |
Caption |
Description |
Type |
Mandatory |
Name (known in REST) |
Available since release |
Introduced by which team |
Introduced for which project |
Additional remarks |
|
NetWeight
|
Weight
|
Weight
|
Number
|
|
NetWeight
|
|
|
|
|
| Property starting with O |
| Name |
Caption |
Description |
Type |
Mandatory |
Name (known in REST) |
Available since release |
Introduced by which team |
Introduced for which project |
Additional remarks |
|
OrderPolicyCode
|
Order Policy Code
|
Order Policy Code
|
String
|
|
OrderPolicyCode
|
|
|
|
|
| Property starting with P |
| Name |
Caption |
Description |
Type |
Mandatory |
Name (known in REST) |
Available since release |
Introduced by which team |
Introduced for which project |
Additional remarks |
|
PurchaseVATCode
|
|
|
String
|
|
PurchaseVATCode
|
|
|
|
|
| Property starting with R |
| Name |
Caption |
Description |
Type |
Mandatory |
Name (known in REST) |
Available since release |
Introduced by which team |
Introduced for which project |
Additional remarks |
|
RequiresApprovedSupplier
|
Requires approved supplier
|
Requires approved supplier
|
Boolean
|
|
RequiresApprovedSupplier
|
|
|
|
|
| Property starting with S |
| Name |
Caption |
Description |
Type |
Mandatory |
Name (known in REST) |
Available since release |
Introduced by which team |
Introduced for which project |
Additional remarks |
|
SalesPrice
|
Sales Price
|
Sales Price
|
Number
|
|
SalesPrice
|
|
|
|
|
|
SalesVATCode
|
|
|
String
|
|
SalesVATCode
|
|
|
|
|
|
SalesVATCodeDescription
|
|
|
String
|
|
SalesVATCodeDescription
|
|
|
|
|
|
SerialBatchMask
|
Mask
|
Mask
|
String
|
|
SerialBatchMask
|
|
|
|
|
|
Shelflife
|
Shelf life
|
Shelf life
|
Number
|
|
Shelflife
|
|
|
|
|
|
StatisticalNumber
|
Statistical code
|
Statistical code
|
String
|
|
StatisticalNumber
|
|
|
|
|
|
StatisticalUnits
|
Statistical Units
|
Statistical Units
|
Number
|
|
StatisticalUnits
|
|
|
|
|
| Property starting with T |
| Name |
Caption |
Description |
Type |
Mandatory |
Name (known in REST) |
Available since release |
Introduced by which team |
Introduced for which project |
Additional remarks |
|
TaxItemClassification
|
Tax Item Classification
|
Tax Item Classification
|
Number
|
|
TaxItemClassification
|
|
|
|
|
|
TextDescription
|
|
|
String
|
|
TextDescription
|
|
|
|
|
|
Type
|
Type
|
Type
|
String
|
|
Type
|
|
|
|
|
| Property starting with W |
| Name |
Caption |
Description |
Type |
Mandatory |
Name (known in REST) |
Available since release |
Introduced by which team |
Introduced for which project |
Additional remarks |
|
Warehouse
|
Warehouse
|
Warehouse
|
String
|
|
Warehouse
|
|
|
|
|
|
Warranty
|
Warranty period
|
Warranty period
|
Number
|
|
Warranty
|
|
|
|
|


an as-is basis.
Disclaimer 1:
-
DirtyBeans assumes no responsibility with regard to the selection, performance, or use of these products or services. All understandings, agreements, or warranties, if any, take place directly between the vendor and prospective users.
Disclaimer 2:
-
- This website is not owned by, licensed by or a subsidiary of Apple Computer, Inc. Apple iPhone are trademarks of Apple Computer, Inc., registered in the U.S. and other countries. The content of this website is not supplied or reviewed by Apple Computer, Inc.
- All articles, images, logos and trademarks in this site are property of their respective owners. Comments are property of their posters.
- Use of any information available on this website is at your own risk, you are 100% responsible for what you do or don’t do with it.
- If any information on this website is inappropriate or violates or infringes any of your copyright protection do leave a comment and appropriate action will be taken as soon as possible. All the information available on this site is for informational purposes only.
- I as the owner of DirtyBeans, DirtyBeans.com, DBs, am not responsible if you void your warranty or damage your device. The information on the "site, repo, help, blog", may be changed without notice and is not guaranteed to be complete, correct or up to date.
- Links to external sources are provided solely as a courtesy to our visitors. We are not responsible for and do not endorse or warrant in any way any materials, information, goods or services available through such linked sites or any privacy or other practices of such sites.
- All data and information provided on this site is for informational purposes only. DirtyBeans.com makes no representations as to accuracy, completeness, currentness, suitability, or validity of any information on this site and will not be liable for any errors, omissions, or delays in this information or any losses, injuries, or damages arising from its display or use. All information is provided on
an as-is basis.


{% blocktrans %}This page provides information from {{ service_name }}, requiring you to allow access from {{ site_name }} to your {{ service_name }} account.{% endblocktrans %}
{% blocktrans %}Select Proceed… to be redirected to {{ service_name }} to confirm that you agree that access should be granted. If this page is not what you expected, selectCancel.{% endblocktrans %}
{% blocktrans %}To revoke access from {{ site_name }} in the future, you can do so from within {{ service_name }} (refer to the {{ service_name }} documentation for information on how to do this). If you wish to remove access from one of your devices, head to Security preferences at the bottom of any authenticated page on {{ site_name }}.{% endblocktrans %}


Key: = Must support, = QICore-defined extension, = Is-Modifier
| Field | Card. | Type and Description |
|---|---|---|
| allergyIntolerance |
0..*
|
List<AllergyIntolerance>
|
| dateTime |
1..1
|
DateTime
|
| encounter |
0..1
|
Encounter
|
| enteralFormula |
0..1
|
EnteralFormula
|
| excludeFoodModifier |
0..*
|
List<Concept>
|
| foodPreferenceModifier |
0..*
|
List<Concept>
|
| identifier |
0..*
|
List<Identifier>
|
| oralDiet |
0..1
|
OralDiet
|
| orderer |
0..1
|
Practitioner
|
| patient |
1..1
|
Patient
|
| status |
0..1
|
code
|
| supplement |
0..*
|
List<Supplement>
|
Key: = Must support, = QICore-defined extension, = Is-Modifier


PTY
Section: Linux Programmer's Manual (7)
Updated: 2005-10-10
Index
Return to Main Contents
NAME
pty - pseudoterminal interfaces
DESCRIPTION
A pseudoterminal (sometimes abbreviated "pty")
is a pair of virtual character devices that
provide a bidirectional communication channel.
One end of the channel is called the
master;
the other end is called the
slave.
The slave end of the pseudoterminal provides an interface
that behaves exactly like a classical terminal.
A process that expects to be connected to a terminal,
can open the slave end of a pseudoterminal and
then be driven by a program that has opened the master end.
Anything that is written on the master end is provided to the process
on the slave end as though it was input typed on a terminal.
For example, writing the interrupt character (usually control-C)
to the master device would cause an interrupt signal
(SIGINT)
to be generated for the foreground process group
that is connected to the slave.
Conversely, anything that is written to the slave end of the
pseudoterminal can be read by the process that is connected to
the master end.
Pseudoterminals are used by applications such as network login services
(ssh(1), rlogin(1), telnet(1)),
terminal emulators,
script(1),
screen(1),
and
expect(1).
Historically, two pseudoterminal APIs have evolved: BSD and System V.
SUSv1 standardized a pseudoterminal API based on the System V API,
and this API should be employed in all new programs that use
pseudoterminals.
Linux provides both BSD-style and (standardized) System V-style
pseudoterminals.
System V-style terminals are commonly called UNIX 98 pseudoterminals
on Linux systems.
Since kernel 2.6.4, BSD-style pseudoterminals are considered deprecated
(they can be disabled when configuring the kernel);
UNIX 98 pseudoterminals should be used in new applications.
UNIX 98 pseudoterminals
An unused UNIX 98 pseudoterminal master is opened by calling
posix_openpt(3).
(This function opens the master clone device,
/dev/ptmx;
see
pts(4).)
After performing any program-specific initializations,
changing the ownership and permissions of the slave device using
grantpt(3),
and unlocking the slave using
unlockpt(3)),
the corresponding slave device can be opened by passing
the name returned by
ptsname(3)
in a call to
open(2).
The Linux kernel imposes a limit on the number of available
UNIX 98 pseudoterminals.
In kernels up to and including 2.6.3, this limit is configured
at kernel compilation time
(CONFIG_UNIX98_PTYS),
and the permitted number of pseudoterminals can be up to 2048,
with a default setting of 256.
Since kernel 2.6.4, the limit is dynamically adjustable via
/proc/sys/kernel/pty/max,
and a corresponding file,
/proc/sys/kernel/pty/nr,
indicates how many pseudoterminals are currently in use.
For further details on these two files, see
proc(5).
BSD pseudoterminals
BSD-style pseudoterminals are provided as precreated pairs, with
names of the form
/dev/ptyXY
(master) and
/dev/ttyXY
(slave),
where X is a letter from the 16-character set [p-za-e],
and Y is a letter from the 16-character set [0-9a-f].
(The precise range of letters in these two sets varies across UNIX
implementations.)
For example,
/dev/ptyp1
and
/dev/ttyp1
constitute a BSD pseudoterminal pair.
A process finds an unused pseudoterminal pair by trying to
open(2)
each pseudoterminal master until an open succeeds.
The corresponding pseudoterminal slave (substitute "tty"
for "pty" in the name of the master) can then be opened.

The BSD
ioctl(2)
operations
TIOCSTOP,
TIOCSTART,
TIOCUCNTL,
and
TIOCREMOTE
have not been implemented under Linux.
SEE ALSO
select(2),
setsid(2),
forkpty(3),
openpty(3),
termios(3),
pts(4),
tty(4),
tty_ioctl(4)
Index
- NAME
-
- DESCRIPTION
-
- UNIX 98 pseudoterminals
-
- BSD pseudoterminals
-
- FILES
-
- NOTES
-
- SEE ALSO
-
This document was created by
man2html,
using the manual pages.
Time: 02:55:22 GMT, September 18, 2014


Background
The index is one of the most important data structures in git. It represents a virtual working tree state by recording list of paths and their object names and serves as a staging area to write out the next tree object to be committed. The state is "virtual" in the sense that it does not necessarily have to, and often does not, match the files in the working tree.
There are cases git needs to examine the differences between the
virtual working tree state in the index and the files in the
working tree. The most obvious case is when the user asks git
diff
(or its low level implementation, git diff-files
) or
git-ls-files --modified
. In addition, git internally checks
if the files in the working tree are different from what are
recorded in the index to avoid stomping on local changes in them
during patch application, switching branches, and merging.
In order to speed up this comparison between the files in the
working tree and the index entries, the index entries record the
information obtained from the filesystem via lstat(2)
system
call when they were last updated. When checking if they differ,
git first runs lstat(2)
on the files and compares the result
with this information (this is what was originally done by the
ce_match_stat()
function, but the current code does it in
ce_match_stat_basic()
function). If some of these "cached
stat information" fields do not match, git can tell that the
files are modified without even looking at their contents.
Note: not all members in struct stat
obtained via lstat(2)
are used for this comparison. For example, st_atime
obviously
is not useful. Currently, git compares the file type (regular
files vs symbolic links) and executable bits (only for regular
files) from st_mode
member, st_mtime
and st_ctime
timestamps, st_uid
, st_gid
, st_ino
, and st_size
members.
With a USE_STDEV
compile-time option, st_dev
is also
compared, but this is not enabled by default because this member
is not stable on network filesystems. With USE_NSEC
compile-time option, st_mtim.tv_nsec
and st_ctim.tv_nsec
members are also compared, but this is not enabled by default
because in-core timestamps can have finer granularity than
on-disk timestamps, resulting in meaningless changes when an
inode is evicted from the inode cache. See commit 8ce13b0
of git://git.kernel.org/pub/scm/linux/kernel/git/tglx/history.git
([PATCH] Sync in core time granuality with filesystems,
2005-01-04).
Racy git
There is one slight problem with the optimization based on the cached stat information. Consider this sequence:
: modify 'foo'
$ git update-index 'foo'
: modify 'foo' again, in-place, without changing its size
The first update-index
computes the object name of the
contents of file foo
and updates the index entry for foo
along with the struct stat
information. If the modification
that follows it happens very fast so that the file’s st_mtime
timestamp does not change, after this sequence, the cached stat
information the index entry records still exactly match what you
would see in the filesystem, even though the file foo
is now
different.
This way, git can incorrectly think files in the working tree
are unmodified even though they actually are. This is called
the "racy git" problem (discovered by Pasky), and the entries
that appear clean when they may not be because of this problem
are called "racily clean".
To avoid this problem, git does two things:
-
When the cached stat information says the file has not been modified, and the
st_mtime
is the same as (or newer than) the timestamp of the index file itself (which is the timegit update-index foo
finished running in the above example), it also compares the contents with the object registered in the index entry to make sure they match. -
When the index file is updated that contains racily clean entries, cached
st_size
information is truncated to zero before writing a new version of the index file.
Because the index file itself is written after collecting all
the stat information from updated paths, st_mtime
timestamp of
it is usually the same as or newer than any of the paths the
index contains. And no matter how quick the modification that
follows git update-index foo
finishes, the resulting
st_mtime
timestamp on foo
cannot get a value earlier
than the index file. Therefore, index entries that can be
racily clean are limited to the ones that have the same
timestamp as the index file itself.
The callers that want to check if an index entry matches the
corresponding file in the working tree continue to call
ce_match_stat()
, but with this change, ce_match_stat()
uses
ce_modified_check_fs()
to see if racily clean ones are
actually clean after comparing the cached stat information using
ce_match_stat_basic()
.
The problem the latter solves is this sequence:
$ git update-index 'foo'
: modify 'foo' in-place without changing its size
: wait for enough time
$ git update-index 'bar'
Without the latter, the timestamp of the index file gets a newer
value, and falsely clean entry foo
would not be caught by the
timestamp comparison check done with the former logic anymore.
The latter makes sure that the cached stat information for foo
would never match with the file in the working tree, so later
checks by ce_match_stat_basic()
would report that the index entry
does not match the file and git does not have to fall back on more
expensive ce_modified_check_fs()
.
Runtime penalty
The runtime penalty of falling back to ce_modified_check_fs()
from ce_match_stat()
can be very expensive when there are many
racily clean entries. An obvious way to artificially create
this situation is to give the same timestamp to all the files in
the working tree in a large project, run git update-index
on
them, and give the same timestamp to the index file:
$ date >.datestamp
$ git ls-files | xargs touch -r .datestamp
$ git ls-files | git update-index --stdin
$ touch -r .datestamp .git/index
This will make all index entries racily clean. The linux-2.6 project, for example, there are over 20,000 files in the working tree. On my Athlon 64 X2 3800+, after the above:
$ /usr/bin/time git diff-files
1.68user 0.54system 0:02.22elapsed 100%CPU (0avgtext+0avgdata 0maxresident)k
0inputs+0outputs (0major+67111minor)pagefaults 0swaps
$ git update-index MAINTAINERS
$ /usr/bin/time git diff-files
0.02user 0.12system 0:00.14elapsed 100%CPU (0avgtext+0avgdata 0maxresident)k
0inputs+0outputs (0major+935minor)pagefaults 0swaps
Running git update-index
in the middle checked the racily
clean entries, and left the cached st_mtime
for all the paths
intact because they were actually clean (so this step took about
the same amount of time as the first git diff-files
). After
that, they are not racily clean anymore but are truly clean, so
the second invocation of git diff-files
fully took advantage
of the cached stat information.
Avoiding runtime penalty
In order to avoid the above runtime penalty, post 1.4.2 git used to have a code that made sure the index file got timestamp newer than the youngest files in the index when there are many young files with the same timestamp as the resulting index file would otherwise would have by waiting before finishing writing the index file out.
I suspected that in practice the situation where many paths in the index are all racily clean was quite rare. The only code paths that can record recent timestamp for large number of paths are:
-
Initial
git add .
of a large project. -
git checkout
of a large project from an empty index into an unpopulated working tree.
Note: switching branches with git checkout
keeps the cached
stat information of existing working tree files that are the
same between the current branch and the new branch, which are
all older than the resulting index file, and they will not
become racily clean. Only the files that are actually checked
out can become racily clean.
In a large project where raciness avoidance cost really matters, however, the initial computation of all object names in the index takes more than one second, and the index file is written out after all that happens. Therefore the timestamp of the index file will be more than one seconds later than the youngest file in the working tree. This means that in these cases there actually will not be any racily clean entry in the resulting index.
Based on this discussion, the current code does not use the "workaround" to avoid the runtime penalty that does not exist in practice anymore. This was done with commit 0fc82cff on Aug 15, 2006.


... seeks to understand the user ...
... challenges assumptions ...
... redefine problems ...
... identify alternative strategies and solutions that are not on our level of understanding
... there are 3 - 7 phases or stages ...
...However ...
ALL variants are very SIMILAR.
• Created by Hasso-Plattner Institute of Design at Stanford or d.school
• They’re at the forefront of applying and teaching Design Thinking
... this is not sequential ...
... look at it as an overview of the phases that contribute to an innovative project ...
... naturally develop patterns of thinking based on repetetive activities and common knowledge
... because of this, it's easy for us to judge with little facts
... sometimes, this thinking hinders us to use innovative problem-solving strategy called ..
...thinking outside of the box can be a challenge ...
... because of the patterns and knowledge we already know ..
...not only for designers ...
But for
...engineers...
...creatives ...
...leaders ...
...that wants to infuse design thinking into their organization, product or service ...


{% extends "task.html" %} {% block css %} {{block.super}} {% endblock %} {% block task %} Hangman {% endblock %} {% block taskstory %} Quick! You'd better tell the sheriffs what they want to hear, or they'll tie the noose real tight and let you hang. Guess letters by tapping them below, but don't get carried away - you can only press your luck so far... {% endblock %} {% block taskbody %}


The filter package is a simple framework for two kinds of filters:
Stream-based and object-based. The package is capable of setting up chains
of filters and pumping data through these filters.
Related Documentation
The Summa-modules Ingest and Index are just collections of filters, relying
on the filters-framework to provide structure.


{% extends 'core/base_lr_rail.html' %} {% import 'macros/util.html' as util with context %} {% from 'macros/reminders.html' import reminder_form with context %} {% block left_rail %}


Go to the source code of this file.
| typedef void(* fwatch_cb_f) (int fd) |
| int fwatch_add |
( |
fwatch_cb_f |
cb, |
|
|
int |
fd, |
|
|
char * |
fname |
|
) |
| |
- Parameters
-
| cb | callback to be called when file is ready |
| fd | file descriptor, if zero, fname will be used to open file |
| fname | filename of the file to select on |
- Returns
- 0 on success, -1 on error
This function will call function cb when select notifies that
the file in fd has data to be read.
Definition at line 42 of file fwatch.c.
- Parameters
-
| us | Timeout time for select in µS |
- Returns
- 0 on success, -1 on error.
Definition at line 83 of file fwatch.c.
- Returns
- 0
Will start the module. No more registration should be done after start has been called.
Definition at line 67 of file fwatch.c.


{% extends "base.html" %} {% block title %}Insufficient Permissions{% endblock %} {% block content %}
You do not have permission to perform this action.


Yesterday I installed console on my GNU/HURD setup. It's very cool. It lets me switch between number of terminals even in command line interface. Never seen this thing in command line. The installation was straighforward as pointed on http://hurd.gnufans.org/bin/view/Hurd/HurdConsole.
Later I tried to make XFree86 work on my system referring to http://hurd.gnufans.org/bin/view/Hurd/Xfree86. But no luck with that yet. I don't understand how to tackle the dependency problem while installing the required packages for XFree86, namely x-window-system-core and others listed.
Later on I also tried to setup network connection. But it is giving me errors like
/hurd/pfinet: eth0: (os/device) no such device
Will do some googling on these issues today.


|
ASVLite
|
#include <simulation.h>
Public Attributes | |
| pthread_t | thread |
| char | id [32] |
| struct Wave * | wave |
| struct Asv * | asv |
| struct Waypoints * | waypoints |
| struct Buffer * | buffer |
| long | current_time_index |
| int | current_waypoint_index |
| struct Simulation * | previous |
| struct Simulation * | next |
Struct Simulation is a linked list to store simulation data related to each asv.


0:00 EST on November 9, 2015: The team-based Online Part is released. Teams have one week to work on this part, choosing one or both of two available topics.
23:59 EST on November 15, 2015: The Online Part is due, to be submitted as specified in the rules.
The Online Part will be judged separately from the Onsite Test for a duration of at least one week.
Schedule for Onsite Test
Noon on November 21, 2015: Arrival of contestants begins
12:00 - 1:30 pm: Registration in the Joseph Henry Room (JHR) on the first floor of Jadwin Hall, entrance from the courtyard.
12:30 - 1:30 pm: An informal meet-and-greet with lunch served in the Jadwin Hall lobby in front of the JHR. (Registration continues; signs will be posted.)
2:00 - 4:00 pm: The Onsite Test held in auditorium McDonnell A02.
3:00 - 5:00 pm: The Onsite Test *just for PUMaC division finalist contestants* held in room Jadwin A07.
5:00 pm: Keynote Talk given directly to contestants by Professor Lyman Page (Department of Physics, Princeton University), an expert in observational cosmology and one of the first co-investigators for the WMAP probe that made precise observations of the cosmic background radiation.
6:30 pm: the Awards Ceremony begins in auditorium McDonnell A02, to conclude by 7:00 pm.
Directions to campus
Please read this overview for traveling to campus from various directions.
The parking map is located here.
Per university policy, high school students are not permitted to stay overnight on campus.


Hello Everyone!. Good Day!.
I am GLORY ANN CABARAL , from Barangay Funda,Cuyo, Palawan. 3rd Year College Student taking of Bachelor of Science in Computer Science in Palawan State University Main Campus, here in Puerto Princesa City. I am creating this Website to show other people that our municipality has its own beauty, historical places and it's perfect for summer vacation, the cuyonon people are hospitality and having a good heart. I am Proud to be a CUYONON.
I'd love to hear your feedback!
Curent Location: Puerto Princesa City, Palawan


Interfaces have the following binary layout:[1]
struct IBar { typedef void (*funtion)(); void* pv; funtion* table; };
When an interface instance is bound to an object, the pointer pv
points to the bound object and the pointer table
points into an array of function pointers with static storage duration. The array contains a function pointer for each member function of the interface; the signature of a function in the array is the same as the signature of the corresponding interface member function except that it has an additional leading parameter of type void*
.
The function corresponding to an interface member function with the signature result f(arg1, ..., argn)
is implemented roughly as follows, where T
is the static type of the object at the point it was bound to the interface instance:
void f_impl(void* pv, arg1 a1, ..., argn an) { static_cast<T*>(pv)->f(a1, ..., an); }
The invocation of an interface member function:
int main() { IBar b = ...; b.foo(a1, ..., an); }
can be represented roughly as follows, where offset
is a compile-time constant:
int main() { IBar b = ...; (*b.table[offset])(b.pv, a1, ..., an); }
[1]Assuming the Empty Base Optimization (EBO) is applied. This optimization is not required by the standard, but is required for the current implementation to work. Two implementations which did not depend on the EBO for correctness were considered, but both had shortcomings in areas other than standard conformance.
Revised 13 Jan, 2005
© Copyright Jonathan Turkanis, 2005. Distributed under the Boost Software License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)


AssemblyTron Package¶
Subpackages¶
- AssemblyTron.Cloning Folder
- Submodules
- AssemblyTron.Cloning.IVA module
- AssemblyTron.Cloning.IVA_separatepcrruns_gradient Script
- AssemblyTron.Cloning.Setup Script
- AssemblyTron.Cloning.Setup_seppcr_gradient_24 Script
- AssemblyTron.Cloning.Setup_seppcr_gradient_96 Script
- AssemblyTron.Cloning.dilution_24 Script
- AssemblyTron.Cloning.dilution_96 Script
- Module contents
- AssemblyTron.Golden_Gate Folder
- Submodules
- AssemblyTron.Golden_Gate.GoldenGate_nodigests_separatepcrruns-gradient Script
- AssemblyTron.Golden_Gate.Setup_digests_gradient Script
- AssemblyTron.Golden_Gate.Setup_nodigests_seppcr_gradient_24 Script
- AssemblyTron.Golden_Gate.Setup_nodigests_seppcr_gradient_96 Script
- AssemblyTron.Golden_Gate.dilution_24 Script
- AssemblyTron.Golden_Gate.dilution_96 Script
- Module contents
Submodules¶
AssemblyTron.Update_Input Script¶
Input.csv Updater
This updater script is to ensure the robot calls the correct Input.csv file. Failure to complete this step could result in errors and failure.
This script is run as a module on the command line with the command AssemblyTron.Update_Input.py or if it is being run from a subdirectory the command would be AssemblyTron.{subdirectory folder}.{dated folder}.1_Update_Input.py
AssemblyTron.opentrons_demo_script Script¶
OT-2 Demo Script
This is a demo script designed to be executed on the OT-2 run app. It shows the OT-2 in action.
This script does not require any input files.
AssemblyTron.pathswriter Script¶
AssemblyTron Paths Writer Script
This script guides the user through finding and recording the AssemblyTron working directory and the Rscript.exe file. The pathswriter module records working directory and enables protocol setup scripts to navigate accurately. The pathswriter.py must be run in the AssemblyLine working directory so that the correct path is generated, and the paths.csv file is saved in the proper location.
The script does not require any input files, however it saves the paths as strings in a CSV.
This script requires that pandas be installed in the python environment where the script is run.
This file can also be run as a module by calling AssemblyTron.pathswriter
AssemblyTron.static_wired_IP_address Script¶
Static wired IP address script
This script was provided by Opentrons and is used to set a Static IP address for your OT-2. The static IP address is crucial for automating transfer of CSV files between the AssemblyTron working directory and the OT-2.
This script requires the new static IP address, which should be selected by your IT administrator.


We’ll be back soon!
Sorry for the inconvenience but we’re performing some maintenance at the moment. we’ll be back online shortly!
— The Olx Team
Sorry for the inconvenience but we’re performing some maintenance at the moment. we’ll be back online shortly!
— The Olx Team


{% extends 'base.html' %} {% block content %} {% load site_tags %}
You will need the following documents:
To obtain the LA County reclassification form, please visit http://www.lacourt.org/forms/criminal and select form CRIM235
Please click the resource page if you need to find where to get a Live Scan
In LA County, you can obtain your criminal record from the County Court by going here: https://www.lacourt.org/paonlineservices/criminalindex/publicmain.aspx?


MAINTx.SYS
MAINTx.SYS (\FBB\SYSTEM).
This file is in the SYSTEM directory. This works exactly like INITTNCx.SYS,
but the parametres are sent to the TNC when the BBS is shut down. The file
can look like this:
Y 1
U 1 BBS ($c) was shut down for service $d $T.
Y 1 means that only 1 station can connect my TNC now.
U 1 means that the TNC will send this message to any user that connects
after the BBS has shut down.
If you use a PK-232, the same file would look like this:
UR1
CTBBS ($c) was shut down for service $d $T.
The commands sent to the TNC, are the commands described in the
documentation for the firmware you use, or in the documentation for PK-232,
DRSI, BPQ , KAM etc.
This page was last updated


keystrokes: {{display.display}}
show character help
Close
the wubi code of this character is:
{{data.promptCharacter.wubiCode[0]}}
This character component is located on the
{{data.promptCharacter.key.toUpperCase()}}
key.
Group:
(First Stroke is in the {{data.promptCharacter.group}} group)
Start Typing
Typing
{{data.promptCharacter.character}}
{{input.inputSequence}}
Sorry that was wrong
, this component belongs to the
group
{{data.promptCharacter.group}}
Hint: Press ENTER to show/hide the wubi keyboard layout
Press SPACE to show/hide the help for the current character component


Hello!
As you can probably tell from the page title, my name is Nathan Cashman.
As an eventual jobseeker, I would like to give potential employers the
oportunity to learn about me. I currently reside in Cedar Rapids, Iowa.
Prior to my becoming a developer, I graduated from Drake University with
a Bachelor's degree in Music Education. Although I have left the field of
education, I still play trombone whenever I get the chance. In my free time,
I like to play video games, watch anime, and spend time with friends and family.
Education
-
DeltaV Coding School
-
Software Development
- June 2018 -
-
Drake University
- Bachelor's in Music Education
- Licensed to teach K-12 music classes
- GPA: 3.22
- August 2013 - August 2017
Top 10 Favorite Game Series
- The Legend of Zelda
- Xeno
- Super Smash Bros.
- Metroid
- Super Mario
- F-Zero
- Mario Kart
- Castlevania
- Elder Scrolls
- Kirby
About Me Questionaire
- Did Nathan Cashman graduate from college?
- Does Nathan Cashman play bass?
- Does Nathan Cashman live in Cedar Rapids?
- Does Nathan Cashman like anime?
- Does Nathan Cashman live with his parents?
- I'm thinking of a number between 1 and 10, what is it?
- What is one instrument Nathan Cashman is proficient on?


From "The Alchemist of Cuernavaca," by Pete Hamill:
"The Mexican artist Lucero Isaac moves through her studio like the
keeper of an alchemist's eyrie.... 'Here is where I make my dreams
visible.' Isaac is 65, trim, vivacious, exuding youthful enthusiasm....
She moves around her studio with a dancer's sense of focused energy."
-- Art News magazine, April 2001, pages 134-137
From the 1947 novel about Cuernavaca by Malcolm Lowry:
"...his eyes ranged the Consul's books disposed quite neatly... on high shelves around the walls: Dogme et Ritual de la Haute Magie, Serpent and Siva Worship in Central America,
there were two long shelves of this, together with the rusty leather
bindings and frayed edges of the numerous cabbalistic and alchemical
books, though some of them looked fairly new, like the Goetia of the Lemegaton of Solomon the King, probably they were treasures, but the rest were a heterogeneous collection...."
-- Under the Volcano, Chapter VI
From a novel that deals with properties of today's date, April 4:
Just as these lines that merge to form a key
Are as chess squares; when month and day are four;
Don't risk another chance to move to mate.
One game is real and one's a metaphor.
Untold times this wisdom's come too late.
Battle of White has raged on endlessly.
Everywhere Black will strive to seal his fate.
Continue a search for thirty-three and three.
Veiled forever is the secret door.
-- Katherine Neville, aka Cat Velis, in The Eight,
Ballantine Books, January 1989, page 140
"J-A-D-O-U-B-E / C-V"
-- The first letters of the above lines of verse, as pointed out on page 141 of The Eight
"Pardon me. J'adoube."
-- The Consul, as he fastens his fly in Under the Volcano, Signet paperback edition of 1966, in the Cuernavaca Garden of Eden scene, page 162
See also Dogma Part II: Amores Perros.
Samuel Beckett on Dante and Joyce:
"Another point of comparison is the preoccupation with the significance
of numbers. The death of Beatrice inspired nothing less than a highly
complicated poem dealing with the importance of the number 3 in her
life. Dante never ceased to be obsessed by this number. Thus the poem
is divided into three Cantiche, each composed of 33 Canti....
Why, Mr. Joyce seems to say, should.... the Armistice be celebrated at
the eleventh hour of the eleventh day of the eleventh month? He cannot
tell you because he is not God Almighty, but in a thousand years he
will tell you... He is conscious that things with a common numerical
characteristic tend towards a very significant interrelationship. This
preoccupation is freely translated in his present work...."
-- "Dante... Bruno. Vico.. Joyce," in James Joyce/Finnegans Wake: A Symposium (1929), New Directions paperback, 1972
See also Plato, Pegasus, and the Evening Star.
Summary of the above themes by S. H. Cullinane:
The Eight, by Katherine Neville, is perhaps the greatest bad
novel of the twentieth century. If it were made into a movie, who
should be cast as the Black Queen? ("...the dignified silver-haired
woman danced sinuously..." -- p. 241)
It seems obvious that the answer is ...
The Alchemist of Cuernavaca, Lucero Isaac.
(See the April 2001 Art News article quoted above.)
"...search for thirty-three and three..."
-- The Black Queen in The Eight
"-- Nel mezzo del bloody cammin di nostra vita mi ritrovai in..."
-- Under the Volcano, beginning of Chapter VI
Page created April 4, 2001 shc759. Return to Journal.


Domotics
Home Automation Console based on JQuery, Backbone, Marionette application using Require.js, Bower, Grunt and LESS
Quick start
Installing this project:
Clone this repository:
git clone git@github.com:dario01/domotics.git
Install all npm dependencies defined in package.json:
npm install
Install all Bower dependencies defined in bower.json:
bower install
Compile and watch files
grunt
Test and watch files
karma start test/js/karma.conf.js
Generate JsDocs
grunt jsdoc
The Web Application can be accessed at
app/index.html
Adding new domotics
Adding a new domotic item instance
Just add an instance to the JSON-LD file at rest/test/domotic-items
Adding a new domotic type
Sensors are read-only, so all you need to do is create a template under app/templates/item
with the same name as the domotic item type (but in camel case).
For more complex scenarios, you can have a custom view or model by adding elements to:
app/js/view/DomoticViewMapper
app/js/model/DomoticModelMapper
See respective examples under:
app/js/view/item
app/js/model/item
Thanks
Many thanks to:


Smell Stinky Dino Breath at the Field Museum in Chicago
Ever wonder what T. rex breath smells like? Find out at Chicago's Field Museum, home to the iconic Sue!
Sue lived more than 67 million years ago and is the world's largest and most complete T. rex skeleton ever discovered.
Now the Field Museum has added multisensory stations to bring you closer to Sue's world, including one that is supposed to smell like the inside of a T. rex's mouth.
Basically, it's time travel - without the fear of being eaten!


KINGPIN A film review by Chad Polenz Copyright 1997 Chad Polenz
** (out of 4 = fair) 1996, PG-13, 113 minutes [1 hour, 53 minutes] [comedy] starring: Woody Harrelson (Roy Munson), Randy Quaid (Ishmael Boorg), Vanessa Angel (Claudia), Bill Murray (Ernie McCracken), produced by Brad Krevoy, Steve Stabler, Bradley Thomas, written by Barney Fanaro, Mort Nathan, directed by Peter and Bobby Farrelly.
"Kingpin" tries to cash in on the elements that worked in the Farrelly brothers' first film, "Dumb And Dumber," this time with the generic sports plot (the underdog versus the champion), and it doesn't work because it goes overboard. The film focuses too much on plot rather than on jokes, and the jokes we get are in questionable taste.

The film stars Woody Harrelson as Roy Munson, a young bowler from Iowa who attempts to make a career out of hussling bowlers along with the man whom he narrowly defeated, Ernie McCracken (Murray).  When Ernie leaves Roy to a mob of angry gamblers, Roy finds himself deprived of his bowling hand and of course his life is shattered.
Fast forward to the present day as Roy is doing whatever he can to make ends meet, even going so far as to sleep with his absolutely disgusting landlady to avoid rent payment. Here the tone of the movie is set - we're going to get a lot of poo-poo jokes that are original, but disgusting at the same time.
One day Roy meets an Amish man named Ishmael (Quaid), who is the talented prodigy with great potential, if only he'd let Roy coach him. And so Roy and Ish start their cross-country journey from Pennsylvania to Reno to the million dollar bowling tournament, because "the bank" has threatened to foreclose on the Amish if they can not come up with $500,000.
>From here on the story goes through the motions and only exists to make for jokes - some funny, others not, which wouldn't be so bad if the pacing was a little faster. We get many jokes about both male and female genitalia, typical cartoony slapstick, and one-liners, but they are all pretty much connected by the fish-out-of-water story.
Guess how "Kingpin" ends? Actually, one element to it is surprising, but the rest is pretty standard. Yes, this movie does yield some big laughs, but not all big laughs. It concentrates too much on plot and comedy suffers.
please visit Chad'z Movie Page @ http://members.aol.com/ChadPolenz
The review above was posted to the
rec.arts.movies.reviews newsgroup (de.rec.film.kritiken for German reviews).
The Internet Movie Database accepts no responsibility for the contents of the
review and has no editorial control. Unless stated otherwise, the copyright
belongs to the author.
Please direct comments/criticisms of the review to relevant newsgroups.
Broken URLs inthe reviews are the responsibility of the author.
The formatting of the review is likely to differ from the original due
to ASCII to HTML conversion.
Related links: index of all rec.arts.movies.reviews reviews


cordova-plugin-ble
Source: cordova-ble/
Functions and properties in this module are available
under the global name evothings.ble
Namespace
Properties
Methods
- bond(device, success, fail)
- characteristics(device, service, success, fail)
- close(device)
- connect(device, success, fail)
- connectToDevice(device, connected, disconnected, fail, options)
- descriptors(device, characteristic, success, fail)
- disableNotification(device, characteristic, success, fail, options)
- enableNotification(device, characteristic, success, fail, options)
- fromUtf8(a)
- getBondedDevices(success, fail, options)
- getBondState(device, success, fail, options)
- getCanonicalUUID(uuid)
- getCharacteristic(device, uuid)
- getDescriptor(characteristic, uuid)
- getService(device, uuid)
- parseAdvertisementData(device)
- readAllServiceData(device, success, fail)
- readCharacteristic(device, characteristic, success, fail)
- readDescriptor(device, descriptor, success, fail)
- readServiceData(device, success, fail, options)
- reset(success, fail)
- rssi(device, success, fail)
- services(device, success, fail)
- startScan(success, fail, options)
- stopScan()
- testCharConversion(i, success)
- toUtf8(s)
- unbond(device, success, fail)
- writeCharacteristic(device, characteristic, data, success, fail)
- writeCharacteristicWithoutResponse(device, characteristic, data, success, fail)
- writeDescriptor(device, descriptor, data, success, fail)
Abstract types
Namespace
peripheral
Properties
connectionState
A map describing possible connection states.
Properties
| Name | Type | Optional | Description |
|---|---|---|---|
|
0 |
|
|
STATE_DISCONNECTED |
|
1 |
|
|
STATE_CONNECTING |
|
2 |
|
|
STATE_CONNECTED |
|
3 |
|
|
STATE_DISCONNECTING |
|
STATE_DISCONNECTED |
|
|
0 |
|
STATE_CONNECTING |
|
|
1 |
|
STATE_CONNECTED |
|
|
2 |
|
STATE_DISCONNECTING |
|
|
3 |
permission
A map describing possible permission flags.
Properties
| Name | Type | Optional | Description |
|---|---|---|---|
|
1 |
|
|
PERMISSION_READ |
|
2 |
|
|
PERMISSION_READ_ENCRYPTED |
|
4 |
|
|
PERMISSION_READ_ENCRYPTED_MITM |
|
16 |
|
|
PERMISSION_WRITE |
|
32 |
|
|
PERMISSION_WRITE_ENCRYPTED |
|
64 |
|
|
PERMISSION_WRITE_ENCRYPTED_MITM |
|
128 |
|
|
PERMISSION_WRITE_SIGNED |
|
256 |
|
|
PERMISSION_WRITE_SIGNED_MITM |
|
PERMISSION_READ |
|
|
1 |
|
PERMISSION_READ_ENCRYPTED |
|
|
2 |
|
PERMISSION_READ_ENCRYPTED_MITM |
|
|
4 |
|
PERMISSION_WRITE |
|
|
16 |
|
PERMISSION_WRITE_ENCRYPTED |
|
|
32 |
|
PERMISSION_WRITE_ENCRYPTED_MITM |
|
|
64 |
|
PERMISSION_WRITE_SIGNED |
|
|
128 |
|
PERMISSION_WRITE_SIGNED_MITM |
|
|
256 |
property
A map describing possible property flags.
Properties
| Name | Type | Optional | Description |
|---|---|---|---|
|
1 |
|
|
PROPERTY_BROADCAST |
|
2 |
|
|
PROPERTY_READ |
|
4 |
|
|
PROPERTY_WRITE_NO_RESPONSE |
|
8 |
|
|
PROPERTY_WRITE |
|
16 |
|
|
PROPERTY_NOTIFY |
|
32 |
|
|
PROPERTY_INDICATE |
|
64 |
|
|
PROPERTY_SIGNED_WRITE |
|
128 |
|
|
PROPERTY_EXTENDED_PROPS |
|
PROPERTY_BROADCAST |
|
|
1 |
|
PROPERTY_READ |
|
|
2 |
|
PROPERTY_WRITE_NO_RESPONSE |
|
|
4 |
|
PROPERTY_WRITE |
|
|
8 |
|
PROPERTY_NOTIFY |
|
|
16 |
|
PROPERTY_INDICATE |
|
|
32 |
|
PROPERTY_SIGNED_WRITE |
|
|
64 |
|
PROPERTY_EXTENDED_PROPS |
|
|
128 |
serviceType
A map describing possible service types.
Properties
| Name | Type | Optional | Description |
|---|---|---|---|
|
0 |
|
|
SERVICE_TYPE_PRIMARY |
|
1 |
|
|
SERVICE_TYPE_SECONDARY |
|
SERVICE_TYPE_PRIMARY |
|
|
0 |
|
SERVICE_TYPE_SECONDARY |
|
|
1 |
writeType
A map describing possible write types.
Properties
| Name | Type | Optional | Description |
|---|---|---|---|
|
1 |
|
|
WRITE_TYPE_NO_RESPONSE |
|
2 |
|
|
WRITE_TYPE_DEFAULT |
|
4 |
|
|
WRITE_TYPE_SIGNED |
|
WRITE_TYPE_NO_RESPONSE |
|
|
1 |
|
WRITE_TYPE_DEFAULT |
|
|
2 |
|
WRITE_TYPE_SIGNED |
|
|
4 |
Methods
bond(device, success, fail)
Bond with device. This function shows a pairing UI on Android. Does nothing on iOS (on iOS paring cannot be requested programatically).
Example
evothings.ble.bond(
{ address: uuidOrMacAddress }
function(newState)
{
console.log('New bond state: ' + newState);
},
function(errorCode)
{
console.log('bond error: ' + errorCode);
});
Parameters
| Name | Type | Optional | Description |
|---|---|---|---|
|
device |
DeviceInfo |
|
Object with address of the device (a device object that contains just the address field may be used). On iOS the address is a UUID, on Android the address is a MAC address. This value can be found in the device objects obtained using startScan(). |
|
success |
bondCallback |
|
Callback function called with the new bond state (a string). On iOS the result is always 'unknown'. |
|
fail |
failCallback |
|
Error callback function. |
characteristics(device, service, success, fail)
Fetch information about a service's characteristics.
Example
evothings.ble.characteristics(
device,
service,
function(characteristics)
{
console.log('found characteristics:');
for (var i = 0; i < characteristics.length; i++)
{
var characteristic = characteristics[i];
console.log(' characteristic: ' + characteristic.uuid);
}
},
function(errorCode)
{
console.log('characteristics error: ' + errorCode);
});
Parameters
| Name | Type | Optional | Description |
|---|---|---|---|
|
device |
DeviceInfo |
|
Device object or a device handle from connectCallback. |
|
service |
Service |
|
Service object or handle from serviceCallback. |
|
success |
characteristicCallback |
|
Called with array of Characteristic objects. |
|
fail |
failCallback |
|
close(device)
Close the connection to a remote device.
Frees any native resources associated with the device.
Does not cause any callbacks to the function passed to connect().
Example
evothings.ble.close(device);
Parameter
| Name | Type | Optional | Description |
|---|---|---|---|
|
device |
DeviceInfo |
|
Device object or a device handle from connectCallback. |
connect(device, success, fail)
Connect to a remote device. It is recommended that you use the high-level function {evothings.ble.connectToDevice} in place of this function. On Android connect may fail with error 133. If this happens, wait about 500ms and connect again.
Example
evothings.ble.connect(
device,
function(connectInfo)
{
console.log('Connect status for device: '
+ connectInfo.device.name
+ ' state: '
+ connectInfo.state);
},
function(errorCode)
{
console.log('Connect error: ' + errorCode);
});
Parameters
| Name | Type | Optional | Description |
|---|---|---|---|
|
device |
DeviceInfo |
|
Device object from scanCallback (for backwards compatibility, this parameter may also be the address string of the device object). |
|
success |
connectCallback |
|
|
|
fail |
failCallback |
|
connectToDevice(device, connected, disconnected, fail, options)
Connect to a BLE device and discover services. This is a more high-level function than {evothings.ble.connect}. You can configure which services to discover and also turn off automatic service discovery by supplying an options parameter. On Android connect may fail with error 133. If this happens, wait about 500ms and connect again.
Example
evothings.ble.connectToDevice(
device,
function(device)
{
console.log('Connected to device: ' + device.name);
},
function(device)
{
console.log('Disconnected from device: ' + device.name);
},
function(errorCode)
{
console.log('Connect error: ' + errorCode);
});
Parameters
| Name | Type | Optional | Description |
|---|---|---|---|
|
device |
DeviceInfo |
|
Device object from {scanCallback}. |
|
connected |
connectedCallback |
|
Called when connected to the device. |
|
disconnected |
disconnectedCallback |
|
Called when disconnected from the device. |
|
fail |
failCallback |
|
Called on error. |
|
options |
ConnectOptions |
|
Optional connect options object. |
descriptors(device, characteristic, success, fail)
Fetch information about a characteristic's descriptors.
Example
evothings.ble.descriptors(
device,
characteristic,
function(descriptors)
{
console.log('found descriptors:');
for (var i = 0; i < descriptors.length; i++)
{
var descriptor = descriptors[i];
console.log(' descriptor: ' + descriptor.uuid);
}
},
function(errorCode)
{
console.log('descriptors error: ' + errorCode);
});
Parameters
| Name | Type | Optional | Description |
|---|---|---|---|
|
device |
DeviceInfo |
|
Device object or a device handle from connectCallback. |
|
characteristic |
Characteristic |
|
Characteristic object or handle from characteristicCallback. |
|
success |
descriptorCallback |
|
Called with array of Descriptor objects. |
|
fail |
failCallback |
|
disableNotification(device, characteristic, success, fail, options)
Disable notification or indication of a characteristic's value.
Example
// Example call:
evothings.ble.disableNotification(
device,
characteristic,
function()
{
console.log('characteristic notification disabled');
},
function(errorCode)
{
console.log('disableNotification error: ' + errorCode);
});
// To disable automatic writing of the config descriptor
// supply this as last parameter to enableNotification:
{ writeConfigDescriptor: false }
Parameters
| Name | Type | Optional | Description |
|---|---|---|---|
|
device |
DeviceInfo |
|
Device object or a device handle from connectCallback. |
|
characteristic |
Characteristic |
|
Characteristic object or handle from characteristicCallback. |
|
success |
emptyCallback |
|
Success callback. |
|
fail |
failCallback |
|
Error callback. |
|
options |
NotificationOptions |
|
Android only: Optional object with options. Set field writeConfigDescriptor to false to disable automatic writing of notification or indication descriptor value. This is useful if full control of writing the config descriptor is needed. |
enableNotification(device, characteristic, success, fail, options)
Request notification or indication on changes to a characteristic's value. This is more efficient than polling the value using readCharacteristic(). This function automatically detects if the characteristic supports notification or indication.
Android only: To disable this functionality and write the configuration descriptor yourself, supply an options object as last parameter, see example below.
Example
// Example call:
evothings.ble.enableNotification(
device,
characteristic,
function(data)
{
console.log('characteristic data: ' + evothings.ble.fromUtf8(data));
},
function(errorCode)
{
console.log('enableNotification error: ' + errorCode);
});
// To disable automatic writing of the config descriptor
// supply this as last parameter to enableNotification:
{ writeConfigDescriptor: false }
Parameters
| Name | Type | Optional | Description |
|---|---|---|---|
|
device |
DeviceInfo |
|
Device object or a device handle from connectCallback. |
|
characteristic |
Characteristic |
|
Characteristic object or handle from characteristicCallback. |
|
success |
dataCallback |
|
Called every time the value changes. |
|
fail |
failCallback |
|
Error callback. |
|
options |
NotificationOptions |
|
Android only: Optional object with options. Set field writeConfigDescriptor to false to disable automatic writing of notification or indication descriptor value. This is useful if full control of writing the config descriptor is needed. |
fromUtf8(a)
Converts an ArrayBuffer containing UTF-8 data to a JavaScript String.
Parameter
| Name | Type | Optional | Description |
|---|---|---|---|
|
a |
ArrayBuffer |
|
- Returns
string
getBondedDevices(success, fail, options)
Get a list of bonded devices.
Example
evothings.ble.getBondedDevices(
function(devices)
{
console.log('Bonded devices: ' + JSON.stringify(devices));
},
function(errorCode)
{
console.log('getBondedDevices error: ' + errorCode);
},
{ serviceUUIDs: ['0000180a-0000-1000-8000-00805f9b34fb'] });
Parameters
| Name | Type | Optional | Description |
|---|---|---|---|
|
success |
getBondedDevicesCallback |
|
Callback function called with list of bonded devices. |
|
fail |
failCallback |
|
Error callback function. |
|
options |
GetBondedDevicesOptions |
|
Mandatory object that specifies service UUIDs to search for. |
getBondState(device, success, fail, options)
Get bond state for device.
Example
evothings.ble.getBondState(
{ address: uuidOrMacAddress }
function(state)
{
console.log('Bond state: ' + state);
},
function(errorCode)
{
console.log('getBondState error: ' + errorCode);
},
{ serviceUUID: '0000180a-0000-1000-8000-00805f9b34fb' });
Parameters
| Name | Type | Optional | Description |
|---|---|---|---|
|
device |
DeviceInfo |
|
Object with address of the device (a device object that contains just the address field may be used). On iOS the address is a UUID, on Android the address is a MAC address. This value can be found in the device objects obtained using startScan(). |
|
success |
getBondStateCallback |
|
Callback function called with the current bond state (a string). |
|
fail |
failCallback |
|
Error callback function. |
|
options |
GetBondStateOptions |
|
Mandatory on iOS where a serviceUUID of the device must be specified. Ignored on Android. |
getCanonicalUUID(uuid)
Returns a canonical UUID.
Code adopted from the Bleat library by Rob Moran (@thegecko), see this file: https://github.com/thegecko/bleat/blob/master/dist/bluetooth.helpers.js
Parameter
| Name | Type | Optional | Description |
|---|---|---|---|
|
uuid |
(string or number) |
|
The UUID to turn into canonical form. |
- Returns
Canonical UUID.
getCharacteristic(device, uuid)
Get a characteristic object of a service. (Characteristics within a service that share the same UUID (rare case) must be retrieved by manually traversing the characteristics array of the service. This function will return the first characteristic found, which may not be the one you want. Note that this is a rare case.)
Parameters
| Name | Type | Optional | Description |
|---|---|---|---|
|
device |
Service |
|
Service object. |
|
uuid |
string |
|
UUID of characteristic to get. |
getDescriptor(characteristic, uuid)
Get a descriptor object of a characteristic.
Parameters
| Name | Type | Optional | Description |
|---|---|---|---|
|
characteristic |
Characteristic |
|
Characteristic object. |
|
uuid |
string |
|
UUID of descriptor to get. |
getService(device, uuid)
Get a service object from a device or array.
Parameters
| Name | Type | Optional | Description |
|---|---|---|---|
|
device |
DeviceInfo |
|
Device object (or array of Service objects). |
|
uuid |
string |
|
UUID of service to get. |
parseAdvertisementData(device)
Parse the advertisement data in the scan record. If device already has AdvertisementData, does nothing. If device instead has scanRecord, creates AdvertisementData. See AdvertisementData for reference documentation.
Parameter
| Name | Type | Optional | Description |
|---|---|---|---|
|
device |
DeviceInfo |
|
Device object. |
readAllServiceData(device, success, fail)
Read all services, and associated characteristics and descriptors for the given device.
This function is an easy-to-use wrapper of the low-level functions ble.services(), ble.characteristics() and ble.descriptors().
Parameters
| Name | Type | Optional | Description |
|---|---|---|---|
|
device |
DeviceInfo |
|
Device object or device handle from connectCallback. |
|
success |
serviceCallback |
|
Called with array of Service objects. Those Service objects each have an additional field "characteristics", which is an array of Characteristic objects. Those Characteristic objects each have an additional field "descriptors", which is an array of Descriptor objects. |
|
fail |
failCallback |
|
Error callback. |
readCharacteristic(device, characteristic, success, fail)
Reads a characteristic's value from a remote device.
Example
evothings.ble.readCharacteristic(
device,
characteristic,
function(data)
{
console.log('characteristic data: ' + evothings.ble.fromUtf8(data));
},
function(errorCode)
{
console.log('readCharacteristic error: ' + errorCode);
});
Parameters
| Name | Type | Optional | Description |
|---|---|---|---|
|
device |
DeviceInfo |
|
Device object or a device handle from connectCallback. |
|
characteristic |
Characteristic |
|
Characteristic object or handle from characteristicCallback. |
|
success |
dataCallback |
|
|
|
fail |
failCallback |
|
readDescriptor(device, descriptor, success, fail)
Reads a descriptor's value from a remote device.
Example
evothings.ble.readDescriptor(
device,
descriptor,
function(data)
{
console.log('descriptor data: ' + evothings.ble.fromUtf8(data));
},
function(errorCode)
{
console.log('readDescriptor error: ' + errorCode);
});
Parameters
| Name | Type | Optional | Description |
|---|---|---|---|
|
device |
DeviceInfo |
|
Device object or a device handle from connectCallback. |
|
descriptor |
Descriptor |
|
Descriptor object or handle from descriptorCallback. |
|
success |
dataCallback |
|
|
|
fail |
failCallback |
|
readServiceData(device, success, fail, options)
Read services, and associated characteristics and descriptors for the given device. Which services to read may be specified in the options parameter. Leaving out the options parameter with read all services.
Parameters
| Name | Type | Optional | Description |
|---|---|---|---|
|
device |
DeviceInfo |
|
Device object or device handle from connectCallback. |
|
success |
serviceCallback |
|
Called with array of Service objects. Those Service objects each have an additional field "characteristics", which is an array of Characteristic objects. Those Characteristic objects each have an additional field "descriptors", which is an array of Descriptor objects. |
|
fail |
failCallback |
|
Error callback. |
|
options |
ReadServiceDataOptions |
|
Object with options (optional parameter). If left out, all services are read. |
reset(success, fail)
Resets the device's Bluetooth system. This is useful on some buggy devices where BLE functions stops responding until reset. Available on Android 4.3+. This function takes 3-5 seconds to reset BLE. On iOS this function stops any ongoing scan operation and disconnects all connected devices.
Parameters
| Name | Type | Optional | Description |
|---|---|---|---|
|
success |
emptyCallback |
|
|
|
fail |
failCallback |
|
rssi(device, success, fail)
Fetch the remote device's RSSI (signal strength).
Example
evothings.ble.rssi(
device,
function(rssi)
{
console.log('rssi: ' + rssi);
},
function(errorCode)
{
console.log('rssi error: ' + errorCode);
});
Parameters
| Name | Type | Optional | Description |
|---|---|---|---|
|
device |
DeviceInfo |
|
Device object or a device handle from connectCallback. |
|
success |
rssiCallback |
|
|
|
fail |
failCallback |
|
services(device, success, fail)
Fetch information about a remote device's services.
Example
evothings.ble.services(
device,
function(services)
{
console.log('found services:');
for (var i = 0; i < services.length; i++)
{
var service = services[i];
console.log(' service:');
console.log(' ' + service.handle);
console.log(' ' + service.uuid);
console.log(' ' + service.serviceType);
}
},
function(errorCode)
{
console.log('services error: ' + errorCode);
});
Parameters
| Name | Type | Optional | Description |
|---|---|---|---|
|
device |
DeviceInfo |
|
Device object or a device handle from connectCallback. |
|
success |
serviceCallback |
|
Called with array of Service objects. |
|
fail |
failCallback |
|
startScan(success, fail, options)
Start scanning for devices.
An array of service UUID strings may be given in the options object parameter. One or more service UUIDs must be specified for iOS background scanning to work.
Found devices and errors are reported to the supplied callback functions.
Will keep scanning until you call stopScan().
To conserve energy, call stopScan() as soon as you've found the device you're looking for.
Call stopScan() before calling startScan() again.
Example
// Scan for all services.
evothings.ble.startScan(
function(device)
{
console.log('startScan found device named: ' + device.name);
},
function(errorCode)
{
console.log('startScan error: ' + errorCode);
}
);
// Scan for specific service (Eddystone Service UUID).
evothings.ble.startScan(
function(device)
{
console.log('startScan found device named: ' + device.name);
},
function(errorCode)
{
console.log('startScan error: ' + errorCode);
},
{ serviceUUIDs: ['0000feaa-0000-1000-8000-00805f9b34fb'] }
);
Parameters
| Name | Type | Optional | Description |
|---|---|---|---|
|
success |
scanCallback |
|
Success callback, called repeatedly for each found device. |
|
fail |
failCallback |
|
Error callback. |
|
options |
ScanOptions |
|
Optional object with options. Set field serviceUUIDs to an array of service UUIDs to scan for. Set field parseAdvertisementData to false to disable automatic parsing of advertisement data. |
stopScan()
Stops scanning for devices.
Example
evothings.ble.stopScan();
testCharConversion(i, success)
i is an integer. It is converted to byte and put in an array[1]. The array is returned.
assert(string.charCodeAt(0) == i).
Parameters
| Name | Type | Optional | Description |
|---|---|---|---|
|
i |
number |
|
|
|
success |
dataCallback |
|
Called every time the value changes. |
toUtf8(s)
Converts a JavaScript String to an Uint8Array containing UTF-8 data.
Parameter
| Name | Type | Optional | Description |
|---|---|---|---|
|
s |
string |
|
- Returns
Uint8Array
unbond(device, success, fail)
Unbond with device. This function does nothing on iOS.
Example
evothings.ble.unbond(
{ address: uuidOrMacAddress }
function(newState)
{
console.log('New bond state: ' + newState);
},
function(errorCode)
{
console.log('bond error: ' + errorCode);
});
Parameters
| Name | Type | Optional | Description |
|---|---|---|---|
|
device |
DeviceInfo |
|
Object with address of the device (a device object that contains just the address field may be used). On iOS the address is a UUID, on Android the address is a MAC address. This value can be found in the device objects obtained using startScan(). |
|
success |
unbondCallback |
|
Callback function called with the new bond state (a string). On iOS the result is always 'unknown'. |
|
fail |
failCallback |
|
Error callback function. |
writeCharacteristic(device, characteristic, data, success, fail)
Write a characteristic's value to the remote device.
Writes with response, the remote device sends back a confirmation message. This is safe but slower than writing without response.
Example
TODO: Add example.
Parameters
| Name | Type | Optional | Description |
|---|---|---|---|
|
device |
DeviceInfo |
|
Device object or a device handle from connectCallback. |
|
characteristic |
Characteristic |
|
Characteristic object or handle from characteristicCallback. |
|
data |
ArrayBufferView |
|
The value to be written. |
|
success |
emptyCallback |
|
Called when the remote device has confirmed the write. |
|
fail |
failCallback |
|
Called if the operation fails. |
writeCharacteristicWithoutResponse(device, characteristic, data, success, fail)
Write a characteristic's value without response.
Asks the remote device to NOT send a confirmation message. This may be used for increased data throughput.
If the application needs to ensure data integrity, a separate safety protocol would be required. Design of such protocols is beyond the scope of this document.
Parameters
| Name | Type | Optional | Description |
|---|---|---|---|
|
device |
DeviceInfo |
|
Device object or a device handle from connectCallback. |
|
characteristic |
Characteristic |
|
Characteristic object or handle from characteristicCallback. |
|
data |
ArrayBufferView |
|
The value to be written. |
|
success |
emptyCallback |
|
Called when the data has been sent. |
|
fail |
failCallback |
|
Called if the operation fails. |
writeDescriptor(device, descriptor, data, success, fail)
Write a descriptor's value to a remote device.
Example
TODO: Add example.
Parameters
| Name | Type | Optional | Description |
|---|---|---|---|
|
device |
DeviceInfo |
|
Device object or a device handle from connectCallback. |
|
descriptor |
Descriptor |
|
Descriptor object or handle from descriptorCallback. |
|
data |
ArrayBufferView |
|
The value to be written. |
|
success |
emptyCallback |
|
|
|
fail |
failCallback |
|
Abstract types
AdvertiseData Object
Describes BLE advertisement data.
Data size is limited to 31 bytes. Each property set consumes some bytes. If too much data is added, startAdvertise will fail with "ADVERTISE_FAILED_DATA_TOO_LARGE" or something similar.
All properties are optional. UUIDs must be formatted according to RFC 4122, all lowercase. Normally, UUIDs take up 16 bytes. However, UUIDs that use the Bluetooth Base format can be compressed to 4 or 2 bytes. The Bluetooth Base UUID is "00000000-0000-1000-8000-00805f9b34fb". For 2 bytes, use this format, where "x" is any hexadecimal digit: "0000xxxx-0000-1000-8000-00805f9b34fb". For 4 bytes, use this format: "xxxxxxxx-0000-1000-8000-00805f9b34fb".
Properties
| Name | Type | Optional | Description |
|---|---|---|---|
|
includeDeviceName |
boolean |
|
If true, the device's Bluetooth name is added to the advertisement. The name is set by the user in the device's Settings. The name cannot be changed by the app. The default is false. |
|
includeTxPowerLevel |
boolean |
|
If true, the txPowerLevel found in AdvertiseSettings is added to the advertisement. The default is false. |
|
serviceUUIDs |
Array |
|
Array of strings. Each string is the UUID of a service that should be available in the device's GattServer. |
|
serviceData |
Object |
|
Map of string to string. Each key is a service UUID. The value is base64-encoded data associated with the service. |
|
manufacturerData |
Object |
|
Map of int to string. Each key is a manufacturer ID. Manufacturer IDs are assigned by the Bluetooth Special Interest Group. The value is base64-encoded data associated with the manufacturer. |
AdvertisementData Object
Information extracted from a scanRecord. Some or all of the fields may be undefined. This varies between BLE devices. Depending on OS version and BLE device, additional fields, not documented here, may be present.
Properties
| Name | Type | Optional | Description |
|---|---|---|---|
|
kCBAdvDataLocalName |
string |
|
The device's name. Might or might not be equal to DeviceInfo.name. iOS caches DeviceInfo.name which means if the name is changed on the device, the new name might not be visible. kCBAdvDataLocalName is not cached and is therefore safer to use, when available. |
|
kCBAdvDataTxPowerLevel |
number |
|
Transmission power level as advertised by the device. |
|
kCBAdvDataChannel |
number |
|
A positive integer, the BLE channel on which the device listens for connections. Ignore this number. |
|
kCBAdvDataIsConnectable |
boolean |
|
True if the device accepts connections. False if it doesn't. |
|
kCBAdvDataServiceUUIDs |
array |
|
Array of strings, the UUIDs of services advertised by the device. Formatted according to RFC 4122, all lowercase. |
|
kCBAdvDataServiceData |
object |
|
Dictionary of strings to strings. The keys are service UUIDs. The values are base-64-encoded binary data. |
|
kCBAdvDataManufacturerData |
string |
|
Base-64-encoded binary data. This field is used by BLE devices to advertise custom data that don't fit into any of the other fields. |
AdvertiseSettings Object
Describes a BLE advertisement.
All the properties are optional, except broadcastData.
Properties
| Name | Type | Optional | Description |
|---|---|---|---|
|
advertiseMode |
string |
|
ADVERTISE_MODE_LOW_POWER, ADVERTISE_MODE_BALANCED, or ADVERTISE_MODE_LOW_LATENCY. The default is ADVERTISE_MODE_LOW_POWER. |
|
connectable |
boolean |
|
Advertise as connectable or not. Has no bearing on whether the device is actually connectable. The default is true if there is a GattServer running, false if there isn't. |
|
timeoutMillis |
int |
|
Advertising time limit. May not exceed 180000 milliseconds. A value of 0 will disable the time limit. The default is 0. |
|
txPowerLevel |
string |
|
ADVERTISE_TX_POWER_ULTRA_LOW, ADVERTISE_TX_POWER_LOW, ADVERTISE_TX_POWER_MEDIUM or ADVERTISE_TX_POWER_HIGH. The default is ADVERTISE_TX_POWER_MEDIUM. |
|
broadcastData |
AdvertiseData |
|
The data which will be broadcast. Passive scanners will see this data. |
|
scanResponseData |
AdvertiseData |
|
The data with which the device will respond to active scans. Should be an extension to the broadcastData; should not contain the same data. |
bondCallback(newState)
Success callback function for bond. On iOS the bond state returned will always be 'unknown' (this function is a NOP on iOS). Note that bonding on Android may fail and then this function is called with 'unbonded' as the new state.
Parameter
| Name | Type | Optional | Description |
|---|---|---|---|
|
newState |
string |
|
The new bond state of the device. Possible values are: 'bonded' (Android), 'bonding' (Android), 'unbonded' (Android), and 'unknown' (iOS). |
Characteristic Object
Describes a GATT characteristic.
Properties
| Name | Type | Optional | Description |
|---|---|---|---|
|
handle |
number |
|
|
|
uuid |
string |
|
Formatted according to RFC 4122, all lowercase. |
|
permissions |
|
Bitmask of zero or more permission flags. |
|
|
properties |
|
Bitmask of zero or more property flags. |
|
|
writeType |
|
characteristicCallback(characteristics)
Parameter
| Name | Type | Optional | Description |
|---|---|---|---|
|
characteristics |
Array |
|
Array of Characteristic objects. |
connectCallback(info)
Will be called whenever the device's connection state changes.
Parameter
| Name | Type | Optional | Description |
|---|---|---|---|
|
info |
ConnectInfo |
|
ConnectInfo Object
Info about connection events and state.
Properties
| Name | Type | Optional | Description |
|---|---|---|---|
|
device |
DeviceInfo |
|
The device object is available in the ConnectInfo if a device object was passed to connect; passing the address string to connect is allowed for backwards compatibility, but this does not set the device field. |
|
deviceHandle |
number |
|
Handle to the device. |
|
state |
number |
|
One of the module:cordova-plugin-ble.connectionState keys. |
connectionStateChangeCallback(deviceHandle, connected)
This function is a part of GattSettings and is called when a remote device connects to, or disconnects from, your server.
Parameters
| Name | Type | Optional | Description |
|---|---|---|---|
|
deviceHandle |
int |
|
Will be used in other callbacks. |
|
connected |
boolean |
|
If true, the device just connected, and the handle is now valid for use in close() and other functions. If false, it just disconnected, and the handle is now invalid for use in close() and other functions. |
ConnectOptions Object
Options for connectToDevice.
Properties
| Name | Type | Optional | Description |
|---|---|---|---|
|
discoverServices |
boolean |
|
Set to false to disable automatic service discovery. Default is true. |
|
serviceUUIDs |
array |
|
Array with service UUID strings for services to discover (optional). If empty or null, all services are read, this is the default. |
dataCallback(data)
Parameter
| Name | Type | Optional | Description |
|---|---|---|---|
|
data |
ArrayBuffer |
|
Descriptor Object
Describes a GATT descriptor.
Properties
| Name | Type | Optional | Description |
|---|---|---|---|
|
handle |
number |
|
|
|
uuid |
string |
|
Formatted according to RFC 4122, all lowercase. |
|
permissions |
|
Bitmask of zero or more permission flags. |
descriptorCallback(descriptors)
Parameter
| Name | Type | Optional | Description |
|---|---|---|---|
|
descriptors |
Array |
|
Array of Descriptor objects. |
DeviceInfo Object
Info about a BLE device.
Properties
| Name | Type | Optional | Description |
|---|---|---|---|
|
address |
string |
|
Uniquely identifies the device. Pass this to connect(). The form of the address depends on the host platform. |
|
rssi |
number |
|
A negative integer, the signal strength in decibels. |
|
name |
string |
|
The device's name, or nil. |
|
scanRecord |
string |
|
Base64-encoded binary data. Its meaning is device-specific. Not available on iOS. |
|
advertisementData |
AdvertisementData |
|
Object containing some of the data from the scanRecord. Available natively on iOS. Available on Android by parsing the scanRecord, which is implemented in the library EasyBLE: https://github.com/evothings/evothings-libraries/blob/master/libs/evothings/easyble/easyble.js. |
emptyCallback()
failCallback(errorString)
This function is called when an operation fails.
Parameter
| Name | Type | Optional | Description |
|---|---|---|---|
|
errorString |
string |
|
A human-readable string that describes the error that occurred. |
GattCharacteristic Object
Describes a GATT characteristic.
Properties
| Name | Type | Optional | Description |
|---|---|---|---|
|
handle |
int |
|
Optional. Used in notify(). If set, must be unique among all other GattCharacteristic handles. |
|
uuid |
string |
|
Formatted according to RFC 4122, all lowercase. |
|
permissions |
|
Bitmask of zero or more permission flags. |
|
|
properties |
property |
|
Bitmask of zero or more property flags. |
|
writeType |
writeType |
|
|
|
onReadRequest |
readRequestCallback |
|
|
|
onWriteRequest |
writeRequestCallback |
|
|
|
descriptors |
Array |
|
Optional. An array of GattDescriptor objects. |
GattDescriptor Object
Describes a GATT descriptor.
Properties
| Name | Type | Optional | Description |
|---|---|---|---|
|
uuid |
string |
|
Formatted according to RFC 4122, all lowercase. |
|
permissions |
|
Bitmask of zero or more permission flags. |
|
|
onReadRequest |
readRequestCallback |
|
|
|
onWriteRequest |
writeRequestCallback |
|
GattService Object
Describes a GATT service.
Properties
| Name | Type | Optional | Description |
|---|---|---|---|
|
uuid |
string |
|
Formatted according to RFC 4122, all lowercase. |
|
type |
serviceType |
|
|
|
characteristics |
Array |
|
An array of GattCharacteristic objects. |
GattSettings Object
Describes a GATT server.
Properties
| Name | Type | Optional | Description |
|---|---|---|---|
|
services |
Array |
|
An array of GattService objects. |
|
onConnectionStateChange |
connectionStateChangeCallback |
|
getBondedDevicesCallback(devices)
Success callback function for getBondedDevices. Called with array of bonded devices (may be empty).
Parameter
| Name | Type | Optional | Description |
|---|---|---|---|
|
devices |
Array |
|
Array of {DeviceInfo} objects. Note that only fields name and address are available in the device info object. |
GetBondedDevicesOptions Object
Options for getBondedDevices.
Parameter
| Name | Type | Optional | Description |
|---|---|---|---|
|
serviceUUIDs |
array |
|
Array with or or more service UUID strings (mandatory). |
getBondStateCallback(state)
Success callback function for getBondState.
Parameter
| Name | Type | Optional | Description |
|---|---|---|---|
|
state |
string |
|
The bond state of the device. Possible values are: 'bonded', 'bonding' (Android only), 'unbonded', and 'unknown'. |
GetBondStateOptions Object
Options for getBondState.
Parameter
| Name | Type | Optional | Description |
|---|---|---|---|
|
serviceUUID |
string |
|
String with service UUID (mandatory on iOS, ignored on Android). |
NotificationOptions Object
Options for enableNotification and disableNotification.
Property
| Name | Type | Optional | Description |
|---|---|---|---|
|
writeConfigDescriptor |
boolean |
|
set to false to disable automatic writing of the notification or indication descriptor. This is useful if full control of writing the config descriptor is needed. |
readRequestCallback(deviceHandle, requestId)
Called when a remote device asks to read a characteristic or descriptor.
Parameters
| Name | Type | Optional | Description |
|---|---|---|---|
|
deviceHandle |
int |
|
|
|
requestId |
int |
|
ReadServiceDataOptions Object
Options for readServiceData.
Property
| Name | Type | Optional | Description |
|---|---|---|---|
|
serviceUUIDs |
array |
|
Array with service UUID strings for services to discover (optional). If absent or null, all services are read, this is the default. |
rssiCallback(rssi)
This function is called with an RSSI value.
Parameter
| Name | Type | Optional | Description |
|---|---|---|---|
|
rssi |
number |
|
A negative integer, the signal strength in decibels. |
scanCallback(device)
This function is a parameter to startScan() and is called when a new device is discovered.
Parameter
| Name | Type | Optional | Description |
|---|---|---|---|
|
device |
DeviceInfo |
|
ScanOptions Object
Options for startScan.
Parameter
| Name | Type | Optional | Description |
|---|---|---|---|
|
serviceUUIDs |
array |
|
Array with service UUID strings (optional). On iOS multiple UUIDs are scanned for using logical OR operator, any UUID that matches any of the UUIDs adverticed by the device will count as a match. On Android, multiple UUIDs are scanned for using AND logic, the device must advertise all of the given UUIDs to produce a match. (The matching logic will be unified in future versions of the plugin.) When providing one service UUID, behaviour is the same on Android and iOS. Learning out this parameter or setting it to null, will scan for all devices, regardless of advertised services. |
Property
| Name | Type | Optional | Description |
|---|---|---|---|
|
parseAdvertisementData |
boolean |
|
Set to false to disable automatic parsing of advertisement data from the scan record. Default is true. |
Service Object
Describes a GATT service.
Properties
| Name | Type | Optional | Description |
|---|---|---|---|
|
handle |
number |
|
|
|
uuid |
string |
|
Formatted according to RFC 4122, all lowercase. |
|
type |
|
serviceCallback(services)
Parameter
| Name | Type | Optional | Description |
|---|---|---|---|
|
services |
Array |
|
Array of Service objects. |
unbondCallback(newState)
Success callback function for unbond. On iOS the bond state returned will always be 'unknown' (this function is a NOP on iOS). On Anroid the result should be 'unbonded', but other states are possible. Check the state to make sure the function was successful.
Parameter
| Name | Type | Optional | Description |
|---|---|---|---|
|
newState |
string |
|
The new bond state of the device. Possible values are: 'unbonded' (Android), 'bonding' (Android), 'bonded' (Android), and 'unknown' (iOS). |
writeRequestCallback(deviceHandle, requestId, data)
Called when a remote device asks to write a characteristic or descriptor.
Parameters
| Name | Type | Optional | Description |
|---|---|---|---|
|
deviceHandle |
int |
|
|
|
requestId |
int |
|
|
|
data |
ArrayBuffer |
|


Retro Cinema Reservation
Name
Email
Date of Birth
Choose your Movie
Invasion of the
Saucer Men
Plan 9 from
Outer Space
Reefer Madness
Adults Only


public class FakeHttpLayer
extends java.lang.Object
| Modifier and Type | Class and Description |
|---|---|
static class |
FakeHttpLayer.DefaultRequestMatcher |
static class |
FakeHttpLayer.RequestMatcherBuilder |
static class |
FakeHttpLayer.RequestMatcherResponseRule |
static class |
FakeHttpLayer.UriRegexMatcher |
static class |
FakeHttpLayer.UriRequestMatcher |
| Constructor and Description |
|---|
FakeHttpLayer() |
| Modifier and Type | Method and Description |
|---|---|
void |
addHttpResponse(org.apache.http.HttpResponse response)
As a consumer of the fake http call, you should never call this method.
|
void |
addHttpResponseContent(byte[] content) |
void |
addHttpResponseRule(HttpEntityStub.ResponseRule responseRule) |
void |
addHttpResponseRule(RequestMatcher requestMatcher,
org.apache.http.HttpResponse response) |
void |
addHttpResponseRule(RequestMatcher requestMatcher,
java.util.List<? extends org.apache.http.HttpResponse> responses)
Add a response rule.
|
void |
addHttpResponseRule(java.lang.String uri,
org.apache.http.HttpResponse response) |
void |
addHttpResponseRule(java.lang.String uri,
java.lang.String response) |
void |
addHttpResponseRule(java.lang.String method,
java.lang.String uri,
org.apache.http.HttpResponse response) |
void |
addPendingHttpResponse(org.apache.http.HttpResponse httpResponse) |
void |
addPendingHttpResponse(HttpResponseGenerator httpResponseGenerator) |
void |
addPendingHttpResponse(int statusCode,
java.lang.String responseBody,
org.apache.http.Header... headers) |
void |
addRequestInfo(HttpRequestInfo requestInfo)
This method is not supposed to be consumed by tests.
|
void |
clearHttpResponseRules() |
void |
clearHttpResponses()
Call this method if you want to ensure that there’s no http responses logged from this point until the next response arrives.
|
void |
clearPendingHttpResponses() |
void |
clearRequestInfos() |
org.apache.http.HttpResponse |
emulateRequest(org.apache.http.HttpHost httpHost,
org.apache.http.HttpRequest httpRequest,
org.apache.http.protocol.HttpContext httpContext,
org.apache.http.client.RequestDirector requestDirector) |
java.util.List<org.apache.http.HttpResponse> |
getHttpResponses()
This method return a list containing all the HTTP responses logged by the fake http layer, be it mocked http responses, be it real http calls (if {code}interceptHttpRequests{/code} is set to false).
|
java.util.List<byte[]> |
getHttpResposeContentList() |
org.apache.http.HttpResponse |
getLastHttpResponse()
Helper method that returns the latest received response from the server.
|
HttpRequestInfo |
getLastSentHttpRequestInfo() |
HttpRequestInfo |
getNextSentHttpRequestInfo() |
HttpRequestInfo |
getSentHttpRequestInfo(int index) |
java.util.List<HttpRequestInfo> |
getSentHttpRequestInfos() |
boolean |
hasPendingResponses() |
boolean |
hasRequestInfos() |
boolean |
hasRequestMatchingRule(RequestMatcher rule) |
boolean |
hasResponseRules() |
void |
interceptHttpRequests(boolean interceptHttpRequests)
You can disable Robolectric’s fake HTTP layer temporarily by calling this method.
|
void |
interceptResponseContent(boolean interceptResponseContent) |
boolean |
isInterceptingHttpRequests() |
boolean |
isInterceptingResponseContent() |
void |
logHttpRequests() |
void |
setDefaultHttpResponse(org.apache.http.HttpResponse defaultHttpResponse) |
void |
setDefaultHttpResponse(int statusCode,
java.lang.String responseBody) |
void |
silence() |
public HttpRequestInfo getLastSentHttpRequestInfo()
public void addPendingHttpResponse(int statusCode, java.lang.String responseBody, org.apache.http.Header... headers)
public void addPendingHttpResponse(org.apache.http.HttpResponse httpResponse)
public void addPendingHttpResponse(HttpResponseGenerator httpResponseGenerator)
public void addHttpResponseRule(java.lang.String method, java.lang.String uri, org.apache.http.HttpResponse response)
public void addHttpResponseRule(java.lang.String uri, org.apache.http.HttpResponse response)
public void addHttpResponseRule(java.lang.String uri, java.lang.String response)
public void addHttpResponseRule(RequestMatcher requestMatcher, org.apache.http.HttpResponse response)
public void addHttpResponseRule(RequestMatcher requestMatcher, java.util.List<? extends org.apache.http.HttpResponse> responses)
Add a response rule.
requestMatcher
- Request matcherresponses
- A list of responses that are returned to matching requests in order from first to last.public void addHttpResponseRule(HttpEntityStub.ResponseRule responseRule)
public void setDefaultHttpResponse(org.apache.http.HttpResponse defaultHttpResponse)
public void setDefaultHttpResponse(int statusCode, java.lang.String responseBody)
public org.apache.http.HttpResponse emulateRequest(org.apache.http.HttpHost httpHost, org.apache.http.HttpRequest httpRequest, org.apache.http.protocol.HttpContext httpContext, org.apache.http.client.RequestDirector requestDirector) throws org.apache.http.HttpException, java.io.IOException
org.apache.http.HttpException
java.io.IOException
public boolean hasPendingResponses()
public boolean hasRequestInfos()
public void clearRequestInfos()
public void addRequestInfo(HttpRequestInfo requestInfo)
This method is not supposed to be consumed by tests. This exists solely for the purpose of logging real HTTP requests, so that functional/integration tests can verify if those were made, without messing with the fake http layer to actually perform the http call, instead of returning a mocked response.
If you are just using mocked http calls, you should not even notice this method here.
requestInfo
- Request info object to add.public boolean hasResponseRules()
public boolean hasRequestMatchingRule(RequestMatcher rule)
public HttpRequestInfo getSentHttpRequestInfo(int index)
public HttpRequestInfo getNextSentHttpRequestInfo()
public void logHttpRequests()
public void silence()
public java.util.List<HttpRequestInfo> getSentHttpRequestInfos()
public void clearHttpResponseRules()
public void clearPendingHttpResponses()
public java.util.List<org.apache.http.HttpResponse> getHttpResponses()
This method return a list containing all the HTTP responses logged by the fake http layer, be it mocked http responses, be it real http calls (if {code}interceptHttpRequests{/code} is set to false).
It doesn’t make much sense to call this method if said property is set to true, as you yourself are providing the response, but it’s here nonetheless.
public void addHttpResponse(org.apache.http.HttpResponse response)
As a consumer of the fake http call, you should never call this method. This should be used solely by components that exercises http calls.
response
- The final response received by the serverpublic void addHttpResponseContent(byte[] content)
public java.util.List<byte[]> getHttpResposeContentList()
public org.apache.http.HttpResponse getLastHttpResponse()
Helper method that returns the latest received response from the server.
public void clearHttpResponses()
Call this method if you want to ensure that there’s no http responses logged from this point until the next response arrives. Helpful to ensure that the state is “clear” before actions are executed.
public void interceptHttpRequests(boolean interceptHttpRequests)
You can disable Robolectric’s fake HTTP layer temporarily by calling this method.
interceptHttpRequests
- whether all HTTP requests should be intercepted (true by default)public boolean isInterceptingHttpRequests()
public void interceptResponseContent(boolean interceptResponseContent)
public boolean isInterceptingResponseContent()


import {BidiModule} from '@angular/cdk/bidi';
Directionality
The directionality (LTR / RTL) context for the application (or a subtree of it). Exposes the current direction and a stream of direction changes.
| Name | Description |
|---|---|
|
Stream that emits whenever the 'ltr' / 'rtl' state changes. |
|
The current 'ltr' or 'rtl' value. |
Dir
Directive to listen for changes of direction of part of the DOM.
Provides itself as Directionality such that descendant directives only need to ever inject Directionality to get the closest direction.
Selector: [dir]
Exported as: dir| Name | Description |
|---|---|
@Output('dirChange')
|
Event emitted when the direction changes. |
|
Current layout direction of the element. |
Direction
type Direction = 'ltr' | 'rtl';