Trading_GetOrdersRequestType Class Reference
| Inherits from | Trading_AbstractRequestType : NSObject |
| Declared in | Trading_GetOrdersRequestType.h Trading_GetOrdersRequestType.m |
Overview
Retrieves the orders for which the authenticated user is a participant, either as the buyer
or the seller. Also for Half.com. The call returns all the
orders that meet the request specifications.
@ingroup EBayAPIInterface
Tasks
-
orderIDArray
A container for eBay order IDs. If one or more order IDs are specified in this
property
container, no other call-specific input fields are applicable.
Not applicable to Half.com. -
createTimeFrom
The CreateTimeFrom and CreateTimeTo fields specify a date range for retrieving
property
orders. The CreateTimeFrom field is the starting date range. All eBay orders
that were created within this date range are returned in the output. The maximum
date range that may be specified with the CreateTimeFrom and CreateTimeTo fields
is 90 days. CreateTimeFrom/CreateTimeTo date filters are ignored if the
NumberOfDays date filter is used in the request, or if one or more order IDs are
passed in the request.
Applicable to Half.com. -
createTimeTo
The CreateTimeFrom and CreateTimeTo fields specify a date range for retrieving
property
orders. The CreateTimeTo field is the ending date range. All eBay orders that were
created within this date range are returned in the output. The maximum
date range that may be specified with the CreateTimeFrom and CreateTimeTo fields
is 90 days. If the CreateTimeFrom field is used and the
CreateTimeTo field is omitted, the “TimeTo” value defaults to the present time or
to 90 days past the CreateTimeFrom value (if CreateTimeFrom value is more than 90
days in the past). CreateTimeFrom/CreateTimeTo date filters are ignored if the
NumberOfDays date filter is used in the request, or if one or more order IDs are
passed in the request.
Note:
If a GetOrders call is made within a few seconds after the creation of a multiple
line item order, the caller runs the risk of retrieiving orders that are in an
inconsistent state, since the order consolidation involved in a multi-line item order
may not have been completed. For
this reason, it is recommended that sellers include the
CreateTimeTo field in the call, and set its value to:
Current Time - 2 minutes.
Applicable to Half.com. -
orderRole
Filters the returned orders based on the role of the user. The user’s role is
property
either buyer or seller. If this field is used with a date filter, returned orders
must satisfy both the date range and the OrderRole value.
Applicable to eBay.com and Half.com. -
orderStatus
Filters the returned orders by order status. For eBay orders, only the Active and
property
Completed values are applicable. The Shipping value can be used for Half.com
orders. If this field is used with a date filter, returned orders
must satisfy both the date range and the OrderStatus value.
To retrieve orders with a status of Inactive or Cancelled, you must specify
the order IDs (OrderIDArray.OrderID). When you specify order IDs, no
other filters may be used.
For Half.com, you can get some, but not all orders.
Orders on Half.com have different order status values from
eBay orders. When you set ListingType to Half, set OrderStatus
to Shipped. Otherwise, GetOrders may return incomplete information
or have indeterminate results. -
listingType
Specify Half to retrieve Half.com orders.
property
Note:
Do not use this field if you are retrieving eBay orders.
This field cannnot be used as a listing type filter on eBay.com. If not
provided, or if you specify any value other than Half, this field has
no useful effect and the call retrieves eBay orders of all types. Also,
you can’t retrieve both eBay and Half.com orders in the same response.
-
pagination
If many orders are
property
available to retrieve, you may need to call GetOrders multiple times to retrieve all
the data. Each result set is returned as a page of entries. Use the
Pagination filters to control the maximum number of entries to
retrieve per page (i.e., per call), the page number to retrieve, and
other data. -
modTimeFrom
The ModTimeFrom and ModTimeTo fields specify a date range for retrieving
property
existing orders that have been modified within this time window (for example,
‘Incomplete’ status to ‘Pending’ status or ‘Pending’ status to ‘Complete’ status). The
ModTimeFrom field is the starting date range. All eBay orders that were last
modified within this date range are returned in the output. The maximum date
range that may be specified with the ModTimeFrom and ModTimeTo fields is 30
days. ModTimeFrom/ModTimeTo date filters are ignored if the
CreateTimeFrom/CreateTimeTo or NumberOfDays date filters are used in the
request, or if one or more order IDs are passed in the request.
Applicable to Half.com. -
modTimeTo
The ModTimeFrom and ModTimeTo fields specify a date range for retrieving
property
existing orders that have been modified within this time window (for example,
‘Incomplete’ status to ‘Pending’ status or ‘Pending’ status to ‘Complete'
status). The ModTimeTo field is the ending date range. All eBay orders that were
last modified within this date range are returned in the output. The maximum
date range that may be specified with the ModTimeFrom and ModTimeTo fields is 30
days. If the ModTimeFrom field is used and the ModTimeTo field is omitted, the
“TimeTo” value defaults to the present time (if ModTimeFrom value is less than
30 days in the past) or to 30 days past the ModTimeFrom value.
ModTimeFrom/ModTimeTo date filters are ignored if the
CreateTimeFrom/CreateTimeTo or NumberOfDays date filters are used in the
request, or if one or more order IDs are passed in the request.
Applicable to Half.com. -
numberOfDays
This filter specifies the number of days (24-hour periods) in the past to search
property
for orders. All eBay orders that were either created or modified within this
period are returned in the output. This field cannot be used in conjunction with
the CreateTimeFrom/CreateTimeTo or ModTimeFrom/ModTimeTo date filters. This date
filter is ignored if one or more order IDs are passed in the request.
Applicable to Half.com. -
includeFinalValueFee
Indicates whether to include the Final Value Fee (FVF) for all Transaction objects in the
property
response. The Final Value Fee is returned in Transaction.FinalValueFee. The Final
Value Fee is assessed right after the creation of an eBay order line item.
Properties
createTimeFrom
The CreateTimeFrom and CreateTimeTo fields specify a date range for retrieving
orders. The CreateTimeFrom field is the starting date range. All eBay orders
that were created within this date range are returned in the output. The maximum
date range that may be specified with the CreateTimeFrom and CreateTimeTo fields
is 90 days. CreateTimeFrom/CreateTimeTo date filters are ignored if the
NumberOfDays date filter is used in the request, or if one or more order IDs are
passed in the request.
Applicable to Half.com.
@property (nonatomic, retain) NSDate *createTimeFrom
Discussion
The CreateTimeFrom and CreateTimeTo fields specify a date range for retrieving
orders. The CreateTimeFrom field is the starting date range. All eBay orders
that were created within this date range are returned in the output. The maximum
date range that may be specified with the CreateTimeFrom and CreateTimeTo fields
is 90 days. CreateTimeFrom/CreateTimeTo date filters are ignored if the
NumberOfDays date filter is used in the request, or if one or more order IDs are
passed in the request.
Applicable to Half.com.
type : NSDate, wrapper for primitive date
Declared In
Trading_GetOrdersRequestType.h
createTimeTo
The CreateTimeFrom and CreateTimeTo fields specify a date range for retrieving
orders. The CreateTimeTo field is the ending date range. All eBay orders that were
created within this date range are returned in the output. The maximum
date range that may be specified with the CreateTimeFrom and CreateTimeTo fields
is 90 days. If the CreateTimeFrom field is used and the
CreateTimeTo field is omitted, the “TimeTo” value defaults to the present time or
to 90 days past the CreateTimeFrom value (if CreateTimeFrom value is more than 90
days in the past). CreateTimeFrom/CreateTimeTo date filters are ignored if the
NumberOfDays date filter is used in the request, or if one or more order IDs are
passed in the request.
Note:
If a GetOrders call is made within a few seconds after the creation of a multiple
line item order, the caller runs the risk of retrieiving orders that are in an
inconsistent state, since the order consolidation involved in a multi-line item order
may not have been completed. For
this reason, it is recommended that sellers include the
CreateTimeTo field in the call, and set its value to:
Current Time - 2 minutes.
Applicable to Half.com.
@property (nonatomic, retain) NSDate *createTimeTo
Discussion
The CreateTimeFrom and CreateTimeTo fields specify a date range for retrieving
orders. The CreateTimeTo field is the ending date range. All eBay orders that were
created within this date range are returned in the output. The maximum
date range that may be specified with the CreateTimeFrom and CreateTimeTo fields
is 90 days. If the CreateTimeFrom field is used and the
CreateTimeTo field is omitted, the “TimeTo” value defaults to the present time or
to 90 days past the CreateTimeFrom value (if CreateTimeFrom value is more than 90
days in the past). CreateTimeFrom/CreateTimeTo date filters are ignored if the
NumberOfDays date filter is used in the request, or if one or more order IDs are
passed in the request.
Note:
If a GetOrders call is made within a few seconds after the creation of a multiple
line item order, the caller runs the risk of retrieiving orders that are in an
inconsistent state, since the order consolidation involved in a multi-line item order
may not have been completed. For
this reason, it is recommended that sellers include the
CreateTimeTo field in the call, and set its value to:
Current Time - 2 minutes.
Applicable to Half.com.
type : NSDate, wrapper for primitive date
Declared In
Trading_GetOrdersRequestType.h
includeFinalValueFee
Indicates whether to include the Final Value Fee (FVF) for all Transaction objects in the
response. The Final Value Fee is returned in Transaction.FinalValueFee. The Final
Value Fee is assessed right after the creation of an eBay order line item.
@property (nonatomic, retain) NSNumber *includeFinalValueFee
Discussion
Indicates whether to include the Final Value Fee (FVF) for all Transaction objects in the
response. The Final Value Fee is returned in Transaction.FinalValueFee. The Final
Value Fee is assessed right after the creation of an eBay order line item.
type : NSNumber, wrapper for primitive bool
Declared In
Trading_GetOrdersRequestType.h
listingType
Specify Half to retrieve Half.com orders.
Note:
Do not use this field if you are retrieving eBay orders.
This field cannnot be used as a listing type filter on eBay.com. If not
provided, or if you specify any value other than Half, this field has
no useful effect and the call retrieves eBay orders of all types. Also,
you can’t retrieve both eBay and Half.com orders in the same response.
@property (nonatomic, retain) NSString *listingType
Discussion
Specify Half to retrieve Half.com orders.
Note:
Do not use this field if you are retrieving eBay orders.
This field cannnot be used as a listing type filter on eBay.com. If not
provided, or if you specify any value other than Half, this field has
no useful effect and the call retrieves eBay orders of all types. Also,
you can’t retrieve both eBay and Half.com orders in the same response.
type: string constant in Trading_ListingTypeCodeType.h
Declared In
Trading_GetOrdersRequestType.h
modTimeFrom
The ModTimeFrom and ModTimeTo fields specify a date range for retrieving
existing orders that have been modified within this time window (for example,
‘Incomplete’ status to ‘Pending’ status or ‘Pending’ status to ‘Complete’ status). The
ModTimeFrom field is the starting date range. All eBay orders that were last
modified within this date range are returned in the output. The maximum date
range that may be specified with the ModTimeFrom and ModTimeTo fields is 30
days. ModTimeFrom/ModTimeTo date filters are ignored if the
CreateTimeFrom/CreateTimeTo or NumberOfDays date filters are used in the
request, or if one or more order IDs are passed in the request.
Applicable to Half.com.
@property (nonatomic, retain) NSDate *modTimeFrom
Discussion
The ModTimeFrom and ModTimeTo fields specify a date range for retrieving
existing orders that have been modified within this time window (for example,
‘Incomplete’ status to ‘Pending’ status or ‘Pending’ status to ‘Complete’ status). The
ModTimeFrom field is the starting date range. All eBay orders that were last
modified within this date range are returned in the output. The maximum date
range that may be specified with the ModTimeFrom and ModTimeTo fields is 30
days. ModTimeFrom/ModTimeTo date filters are ignored if the
CreateTimeFrom/CreateTimeTo or NumberOfDays date filters are used in the
request, or if one or more order IDs are passed in the request.
Applicable to Half.com.
type : NSDate, wrapper for primitive date
Declared In
Trading_GetOrdersRequestType.h
modTimeTo
The ModTimeFrom and ModTimeTo fields specify a date range for retrieving
existing orders that have been modified within this time window (for example,
‘Incomplete’ status to ‘Pending’ status or ‘Pending’ status to ‘Complete'
status). The ModTimeTo field is the ending date range. All eBay orders that were
last modified within this date range are returned in the output. The maximum
date range that may be specified with the ModTimeFrom and ModTimeTo fields is 30
days. If the ModTimeFrom field is used and the ModTimeTo field is omitted, the
“TimeTo” value defaults to the present time (if ModTimeFrom value is less than
30 days in the past) or to 30 days past the ModTimeFrom value.
ModTimeFrom/ModTimeTo date filters are ignored if the
CreateTimeFrom/CreateTimeTo or NumberOfDays date filters are used in the
request, or if one or more order IDs are passed in the request.
Applicable to Half.com.
@property (nonatomic, retain) NSDate *modTimeTo
Discussion
The ModTimeFrom and ModTimeTo fields specify a date range for retrieving
existing orders that have been modified within this time window (for example,
‘Incomplete’ status to ‘Pending’ status or ‘Pending’ status to ‘Complete'
status). The ModTimeTo field is the ending date range. All eBay orders that were
last modified within this date range are returned in the output. The maximum
date range that may be specified with the ModTimeFrom and ModTimeTo fields is 30
days. If the ModTimeFrom field is used and the ModTimeTo field is omitted, the
“TimeTo” value defaults to the present time (if ModTimeFrom value is less than
30 days in the past) or to 30 days past the ModTimeFrom value.
ModTimeFrom/ModTimeTo date filters are ignored if the
CreateTimeFrom/CreateTimeTo or NumberOfDays date filters are used in the
request, or if one or more order IDs are passed in the request.
Applicable to Half.com.
type : NSDate, wrapper for primitive date
Declared In
Trading_GetOrdersRequestType.h
numberOfDays
This filter specifies the number of days (24-hour periods) in the past to search
for orders. All eBay orders that were either created or modified within this
period are returned in the output. This field cannot be used in conjunction with
the CreateTimeFrom/CreateTimeTo or ModTimeFrom/ModTimeTo date filters. This date
filter is ignored if one or more order IDs are passed in the request.
Applicable to Half.com.
@property (nonatomic, retain) NSNumber *numberOfDays
Discussion
This filter specifies the number of days (24-hour periods) in the past to search
for orders. All eBay orders that were either created or modified within this
period are returned in the output. This field cannot be used in conjunction with
the CreateTimeFrom/CreateTimeTo or ModTimeFrom/ModTimeTo date filters. This date
filter is ignored if one or more order IDs are passed in the request.
Applicable to Half.com.
type : NSNumber, wrapper for primitive int
Declared In
Trading_GetOrdersRequestType.h
orderIDArray
A container for eBay order IDs. If one or more order IDs are specified in this
container, no other call-specific input fields are applicable.
Not applicable to Half.com.
@property (nonatomic, retain) Trading_OrderIDArrayType *orderIDArray
Discussion
A container for eBay order IDs. If one or more order IDs are specified in this
container, no other call-specific input fields are applicable.
Not applicable to Half.com.
type : class Trading_OrderIDArrayType
Declared In
Trading_GetOrdersRequestType.h
orderRole
Filters the returned orders based on the role of the user. The user’s role is
either buyer or seller. If this field is used with a date filter, returned orders
must satisfy both the date range and the OrderRole value.
Applicable to eBay.com and Half.com.
@property (nonatomic, retain) NSString *orderRole
Discussion
Filters the returned orders based on the role of the user. The user’s role is
either buyer or seller. If this field is used with a date filter, returned orders
must satisfy both the date range and the OrderRole value.
Applicable to eBay.com and Half.com.
type: string constant in Trading_TradingRoleCodeType.h
Declared In
Trading_GetOrdersRequestType.h
orderStatus
Filters the returned orders by order status. For eBay orders, only the Active and
Completed values are applicable. The Shipping value can be used for Half.com
orders. If this field is used with a date filter, returned orders
must satisfy both the date range and the OrderStatus value.
To retrieve orders with a status of Inactive or Cancelled, you must specify
the order IDs (OrderIDArray.OrderID). When you specify order IDs, no
other filters may be used.
For Half.com, you can get some, but not all orders.
Orders on Half.com have different order status values from
eBay orders. When you set ListingType to Half, set OrderStatus
to Shipped. Otherwise, GetOrders may return incomplete information
or have indeterminate results.
@property (nonatomic, retain) NSString *orderStatus
Discussion
Filters the returned orders by order status. For eBay orders, only the Active and
Completed values are applicable. The Shipping value can be used for Half.com
orders. If this field is used with a date filter, returned orders
must satisfy both the date range and the OrderStatus value.
To retrieve orders with a status of Inactive or Cancelled, you must specify
the order IDs (OrderIDArray.OrderID). When you specify order IDs, no
other filters may be used.
For Half.com, you can get some, but not all orders.
Orders on Half.com have different order status values from
eBay orders. When you set ListingType to Half, set OrderStatus
to Shipped. Otherwise, GetOrders may return incomplete information
or have indeterminate results.
type: string constant in Trading_OrderStatusCodeType.h
Declared In
Trading_GetOrdersRequestType.h
pagination
If many orders are
available to retrieve, you may need to call GetOrders multiple times to retrieve all
the data. Each result set is returned as a page of entries. Use the
Pagination filters to control the maximum number of entries to
retrieve per page (i.e., per call), the page number to retrieve, and
other data.
@property (nonatomic, retain) Trading_PaginationType *pagination
Discussion
If many orders are
available to retrieve, you may need to call GetOrders multiple times to retrieve all
the data. Each result set is returned as a page of entries. Use the
Pagination filters to control the maximum number of entries to
retrieve per page (i.e., per call), the page number to retrieve, and
other data.
type : class Trading_PaginationType
Declared In
Trading_GetOrdersRequestType.h


Wife drags alleged rapist to court, seeks divorce - Premium Times Nigeria
by Agency ReportA housewife, Fatima Ishaq, on Wednesday in Kaduna dragged her husband, Hassan Haruna, before a Sharia Court in Kaduna, over his being accused of raping a minor.
The petitioner who lives with her estranged husband within Kaduna metropolis, through her counsel, M.S. Abdullahi, told the court that she cannot continue living with Mr Haruna.
Mr Abdullahi said that his client could no longer guarantee her respect for Mr Haruna.
He told the court that his client was willing to pay back the N5,000 her husband paid as bride price in 2006.
The petitioner is seeking the custody of their four children and N20,000 monthly for their upkeep.
News Agency of Nigeria (NAN) reports that the respondent was brought to the court in shackles for allegedly raping a minor.
Mr Haruna, however, denied the charge of rape against him.

The judge, Dahiru Lawal, terminated the marriage and ordered the petitioner to return N15,000 to Mr Haruna as the bride price he paid.
“The value of money in 2006 is not the same in the current situation,” Mr Lawal said.
(NAN)


Welcome 😄 My name is Ojas Karmarkar and I stay in Mumbai , India. Most people get to know me because of my open source work on flutter projects. I hear you asking.
I like to finish the app in less time , thereby with more productivity! Your startup or buiseness can grow rapidly with the help of neatly designed apps for your clients!
As an app developer , I would like to develop apps for small startups to make then grow! And what's better than turning your hobby into your profession?!
Lets talk about your next project , describe your budget and the idea in a few words!


Home
Installation
Getting Started
Tutorials
FAQ
More
Resources
Extra (404)
☰
Tutorials
Home
Installation
Getting Started
Tutorials
FAQ
This is where Tutorials would go


|
MiniBot
2019/2020
|
A GearBox is a wrapper for any pair of WPI_TalonSRX motor controllers where the first controller has an encoder attached. More...
Public Member Functions | |
| GearBox (WPI_TalonSRX front, WPI_TalonSRX rear) | |
| GearBox Constructor. More... | |
| void | limitCurrent (int peakCurrent, int holdCurrent, int peakDuration) |
| Wrapper method around the WPI_TalonSRX current limiting functionality. More... | |
| int | getTicks () |
| Wrapper around the encoder for the front or master talon. More... | |
| void | setInverseMotion (boolean is_inverted) |
| Flips the sensor phase of the GearBox's encoder. More... | |
| boolean | getInverseMotion () |
| Is the gearbox currently in inverse motion mode? More... | |
| WPI_TalonSRX | getMaster () |
| Get the master controller. More... | |
| void | set (double speed) |
| Set the GearBox speed. More... | |
Public Attributes | |
| WPI_TalonSRX | front |
| SpeedControllerGroup | speedcontroller |
Private Attributes | |
| boolean | is_inverse_motion = false |
A GearBox is a wrapper for any pair of WPI_TalonSRX motor controllers where the first controller has an encoder attached.
Definition at line 10 of file GearBox.java.
| frc.common.wrappers.GearBox.GearBox | ( | WPI_TalonSRX | front, |
| WPI_TalonSRX | rear | ||
| ) |
GearBox Constructor.
| front | The front or master talon in the gearbox |
| rear | The rear or slave talon in the gearbox |
Definition at line 23 of file GearBox.java.
| boolean frc.common.wrappers.GearBox.getInverseMotion | ( | ) |
Is the gearbox currently in inverse motion mode?
Definition at line 80 of file GearBox.java.
| WPI_TalonSRX frc.common.wrappers.GearBox.getMaster | ( | ) |
| int frc.common.wrappers.GearBox.getTicks | ( | ) |
Wrapper around the encoder for the front or master talon.
Definition at line 60 of file GearBox.java.
| void frc.common.wrappers.GearBox.limitCurrent | ( | int | peakCurrent, |
| int | holdCurrent, | ||
| int | peakDuration | ||
| ) |
Wrapper method around the WPI_TalonSRX current limiting functionality.
| peakCurrent | The current threshold that must be passed before the limiter kicks in |
| holdCurrent | The current to hold the motors at once the threshold has been passed |
| peakDuration | The duration of the corrent limit |
Definition at line 44 of file GearBox.java.
| void frc.common.wrappers.GearBox.set | ( | double | speed | ) |
| void frc.common.wrappers.GearBox.setInverseMotion | ( | boolean | is_inverted | ) |
Flips the sensor phase of the GearBox's encoder.
This is mainly used for inverse motion profiling
| is_inverted | Should the phase be inverted? |
Definition at line 71 of file GearBox.java.
| WPI_TalonSRX frc.common.wrappers.GearBox.front |
Definition at line 11 of file GearBox.java.
|
private |
Definition at line 15 of file GearBox.java.
| SpeedControllerGroup frc.common.wrappers.GearBox.speedcontroller |
Definition at line 13 of file GearBox.java.


| The Top 30 items/URLs |
|---|
| More details | ||||||
|---|---|---|---|---|---|---|
| No. | Hits | 304's | KBytes sent | URL | ||
| 1 | 3682 | 43.56% | 527 | 45.95% | 44440 | All images |
| 2 | 514 | 6.08% | 131 | 11.42% | 1768 | / |
| 3 | 246 | 2.91% | 124 | 10.81% | 86 | /CPH/ |
| 4 | 239 | 2.83% | 104 | 9.07% | 169 | /CPH/frconten.htm |
| 5 | 192 | 2.27% | 0 | 0.00% | 273 | /robots.txt |
| 6 | 170 | 2.01% | 41 | 3.57% | 285 | /CPH/frmain.htm |
| 7 | 95 | 1.12% | 12 | 1.05% | 341 | /CPH/pircs2.html |
| 8 | 89 | 1.05% | 2 | 0.17% | 2256 | /people/flory/Projects/biomet_project.htm |
| 9 | 88 | 1.04% | 13 | 1.13% | 187 | /CPH/CPHagenda.html |
| 10 | 87 | 1.03% | 11 | 0.96% | 181 | /CPH/CPHtravel.html |
| 11 | 84 | 0.99% | 41 | 3.57% | 94 | /people/Helin/ |
| 12 | 68 | 0.80% | 24 | 2.09% | 21 | /people/flory/MM5/MM5_frame.htm |
| 13 | 62 | 0.73% | 18 | 1.57% | 98 | /people/flory/MM5/links.htm |
| 14 | 62 | 0.73% | 19 | 1.66% | 15 | /people/flory/MM5/directions.htm |
| 15 | 62 | 0.73% | 9 | 0.78% | 42 | /CPH/links.html |
| 16 | 46 | 0.54% | 0 | 0.00% | 455 | /atmos/pircsex1.html |
| 17 | 45 | 0.53% | 1 | 0.09% | 180 | /mission.html |
| 18 | 44 | 0.52% | 1 | 0.09% | 30 | /people/flory/MM5/MM5LSM.htm |
| 19 | 40 | 0.47% | 0 | 0.00% | 351 | /people/flory/homepage.html |
| 20 | 39 | 0.46% | 2 | 0.17% | 132 | /personnel.html |
| 21 | 33 | 0.39% | 1 | 0.09% | 208 | /pubs_2.html |
| 22 | 33 | 0.39% | 21 | 1.83% | 11 | /CPH/frbanner.htm |
| 23 | 29 | 0.34% | 1 | 0.09% | 53 | /atmos/panz/overview.html |
| 24 | 25 | 0.30% | 1 | 0.09% | 127 | /atmos/plots/plots.html |
| 25 | 25 | 0.30% | 0 | 0.00% | 59 | /atmos/atmos_copy.html |
| 26 | 24 | 0.28% | 1 | 0.09% | 123 | /PIRCSnotes.html |
| 27 | 23 | 0.27% | 0 | 0.00% | 56 | /prospect.html |
| 28 | 22 | 0.26% | 4 | 0.35% | 188 | /atmos/dataformat.html |
| 29 | 22 | 0.26% | 0 | 0.00% | 7 | /atmos/simulations.html |
| 30 | 21 | 0.25% | 1 | 0.09% | 36 | /CPHagenda.html |
| The 10 least frequently accessed items/URLs |
|---|
| More details | ||||||
|---|---|---|---|---|---|---|
| No. | Hits | 304's | KBytes sent | URL | ||
| 10 | 1 | 0.01% | 0 | 0.00% | 2 | /people/Helin/seminar1/sld008.htm |
| 9 | 1 | 0.01% | 0 | 0.00% | 2 | /people/Helin/seminar1/sld016.htm |
| 8 | 1 | 0.01% | 0 | 0.00% | 2 | /people/Gutowski/Presentations/10_year/sld050.htm |
| 7 | 1 | 0.01% | 0 | 0.00% | 2 | /people/Gutowski/Presentations/10_year/sld042.htm |
| 6 | 1 | 0.01% | 0 | 0.00% | 2 | /people/Helin/seminar1/sld009.htm |
| 5 | 1 | 0.01% | 0 | 0.00% | 1 | /stats/www1997/frames.html |
| 4 | 1 | 0.01% | 0 | 0.00% | 2 | /people/Helin/seminar1/sld018.htm |
| 3 | 1 | 0.01% | 0 | 0.00% | 26 | /atmos/plots/noct93.ori |
| 2 | 1 | 0.01% | 0 | 0.00% | 1 | /atmos/panz/personnel.html |
| 1 | 1 | 0.01% | 0 | 0.00% | 2 | /people/Gutowski/Presentations/10_year/sld041.htm |
|


Seven killed after car bomb blast near Afghan interior ministry in Kabul
by ReutersSeven people were killed and seven injured on Wednesday after a car bomb explosion near the interior ministry in the Afghan capital of Kabul, a government spokesman said.
There was no immediate claim of responsibility for the attack.
It came a day after two Taliban commanders and a leader of the Haqqani militant group were released in exchange for two professors, an American and an Australian, in a development some analysts had hoped could defuse violence in Afghanistan.


| Chrome | Safari | Firefox | Edge | IE | Opera | |
| Desktop | Yes | Yes | Yes | Yes | 9+ | Yes |
| iOS | Yes | Yes | ||||
| Android | Yes |
The following selectors are currently unsupported.
$('h2[foo!="bar"]')
DollarJS universally uses a different style of iterator than jQuery. The order of the parameters is different. This is an intentional choice because we believe this approach to be more adherent to JavaScript's accepted practices.
An iterator in DollarJS
$('p').each(function (value, key, collection) {
console.log(value);
});
An iterator in jQuery
$('p').each(function (key, value, collection) {
console.log(value);
});
DollarJS does event bindings using addEventListener. Therefore, returning false from an event handler does not prevent the default behavior or stop the event from bubbling. This is expected of addEventListener.
The following does NOT work
$('a').on('click', function (e) { return false; });
You should do this instead
$('a').on('click', function (e) { e.preventDefault(); e.stopPropagation(); });


Computers are great at crunching numbers. However, if programmers aren’t careful, their machines can end up biting off more than they can chew: simple arithmetic operations over very large (or very tiny) inputs can overflow leading to bizarre crashes or vulnerabilities. For example, Joshua Bloch’s classic post argues that nearly all binary searches are broken due to integer overflows. Lets see how we can teach LiquidHaskell to spot such overflows.
30: module Bounded where 31: 32: import Control.Exception (assert) 33: import Prelude hiding (Num (..)) 34: import qualified Prelude 35: 36: plusStrict :: Int -> Int -> Int 37: plusLazy :: Int -> Int -> Int 38: mono :: Int -> Bool
1. The Problem
LiquidHaskell, like some programmers, likes to make believe
that Int
represents the set of integers. For example, you
might define a function plus
as:
51: {-@ plus :: x:Int -> y:Int -> {v:Int | v == x + y} @-} 52: plus :: Int -> Int -> Int 53: x1:Int -> x2:Int -> {v : Int | v == x1 + x2}plus Intx Inty = {v : Int | v == y}x x1:Int -> x2:Int -> {v : Int | v == x1 + x2}Prelude.+ y
The output type of the function states that the returned value is equal to the result of adding the two inputs.
The above signature lets us “prove” facts like addition by one yields a bigger number:
63: {-@ monoPlus :: Int -> {v:Bool | v <=> true } @-} 64: monoPlus :: Int -> Bool 65: Int -> {v : Bool | v <=> true}monoPlus Intx = {v : Int | v == x}x x1:Int -> x2:Int -> {v : Bool | v <=> x1 < x2}< {v : x1:Int -> x2:Int -> {v : Int | v == x1 + x2} | v == Bounded.plus}plus x 1
Unfortunately, the signature for plus and hence, the above “fact” are both lies.
LH checks plus
as the same signature is assumed
for the primitive Int
addition operator Prelude.+
.
LH has to assume some signature for this “foreign”
machine operation, and by default, LH assumes that
machine addition behaves like logical addition.
However, this assumption, and its consequences are only true upto a point:
> monoPlus 0
λTrue
> monoPlus 100
λTrue
> monoPlus 10000
λTrue
> monoPlus 1000000
λTrue
Once we get to maxBound
at the very edge of Int
,
a tiny bump is enough to send us tumbling backwards
into a twilight zone.
> monoPlus maxBound
λFalse
> plus maxBound 1
λ-9223372036854775808
2. Keeping Int In Their Place
The news isn’t all bad: the glass half full
view is that for “reasonable” values
like 10, 100, 10000 and 1000000, the
machine’s arithmetic is the same as
logical arithmetic. Lets see how to impart
this wisdom to LH. We do this in two steps:
define the biggest Int
value, and then,
use this value to type the arithmetic operations.
A. The Biggest Int
First, we need a way to talk about
“the edge” – i.e. the largest Int
value at which overflows occur.
We could use the concrete number
> maxBound :: Int
λ9223372036854775807
However, instead of hardwiring a particular number,
a more general strategy is to define a symbolic
constant maxInt
to represent any arbitrary
overflow value and thus, make the type checking
robust to different machine integer widths.
135: -- defines an Int constant called `maxInt` 136: {-@ measure maxInt :: Int @-}
To tell LH that maxInt
is the “biggest” Int
,
we write a predicate that describes values bounded
by maxInt
:
144: {-@ predicate Bounded N = 0 < N + maxInt && N < maxInt @-}
Thus, Bounded n
means that the number n
is in
the range [-maxInt, maxInt]
.
B. Bounded Machine Arithmetic
Next, we can assign the machine arithmetic operations types that properly capture the possibility of arithmetic overflows. Here are two possible specifications.
Strict: Thou Shalt Not Overflow A strict specification simply prohibits any overflow:
160: {-@ plusStrict :: x:Int -> y:{Int|Bounded(x+y)} -> {v:Int|v = x+y} @-} 161: x1:Int -> x2:{y : Int | 0 < (x1 + y) + maxInt && x1 + y < maxInt} -> {v : Int | v == x1 + x2}plusStrict Intx {y : Int | 0 < (x + y) + maxInt && x + y < maxInt}y = {v : Int | 0 < (x + v) + maxInt && x + v < maxInt && v == y}x x1:Int -> x2:Int -> {v : Int | v == x1 + x2}Prelude.+ y
The inputs x
and y
must be such that the result is Bounded
,
and in that case, the output value is indeed their logical sum.
Lazy: Overflow at Thine Own Risk Instead, a lazy specification could permit overflows but gives no guarantees about the output when they occur.
172: {-@ plusLazy :: x:Int -> y:Int -> {v:Int|Bounded(x+y) => v = x+y} @-} 173: x1:Int -> x2:Int -> {v : Int | 0 < (x1 + x2) + maxInt && x1 + x2 < maxInt => v == x1 + x2}plusLazy Intx Inty = {v : Int | v == y}x x1:Int -> x2:Int -> {v : Int | v == x1 + x2}Prelude.+ y
The lazy specification says that while plusLazy
can be called with any values you like, the
result is the logical sum
only if there is no overflow.
To understand the difference between the two
specifications, lets revisit the monoPlus
property using the new machine-arithmetic
sensitive signatures:
188: {-@ monoPlusStrict :: Int -> {v:Bool | v <=> true } @-} 189: Int -> {v : Bool | v <=> true}monoPlusStrict Intx = {v : Int | v == x}x x1:Int -> x2:Int -> {v : Bool | v <=> x1 < x2}< {v : x1:Int -> x2:{v : Int | 0 < (x1 + v) + maxInt && x1 + v < maxInt} -> {v : Int | v == x1 + x2} | v == Bounded.plusStrict}plusStrict x 1 190: 191: {-@ monoPlusLazy :: Int -> {v:Bool | v <=> true } @-} 192: Int -> {v : Bool | v <=> true}monoPlusLazy Intx = {v : Int | v == x}x x1:Int -> x2:Int -> {v : Bool | v <=> x1 < x2}< {v : x1:Int -> x2:Int -> {v : Int | 0 < (x1 + x2) + maxInt && x1 + x2 < maxInt => v == x1 + x2} | v == Bounded.plusLazy}plusLazy x 1
Both are rejected by LH, since, as we saw earlier,
the functions do not always evaluate to True
.
However, in the strict version the error is at the
possibly overflowing call to plusStrict
.
In the lazy version, the call to plusLazy
is
accepted, but as the returned value is some
arbitrary Int
(not the logical x+1
), the
comparison may return False
hence the output
is not always True
.
Exercise: Can you fix the specification
for monoPlusStrict
and monoPlusLazy
to
get LH to verify the implementation?
3. A Typeclass for Machine Arithmetic
Its a bit inconvenient to write plusStrict
and plusLazy
,
and really, we’d just like to write +
and -
and so on.
We can do so, by tucking the above specifications into
a bounded numeric typeclass whose signatures capture machine
arithmetic. First, we define a BoundedNum
variant of Num
220: class BoundedNum a where 221: (+) :: a -> a -> a 222: (-) :: a -> a -> a 223: -- other operations ...
and now, we can define its Int
instance just as wrappers
around the Prelude
operations:
230: instance BoundedNum Int where 231: Intx x1:Int -> x2:{y : Int | 0 < (x1 + y) + maxInt && x1 + y < maxInt} -> {v : Int | v == x1 + x2}+ {y : Int | 0 < (x + y) + maxInt && x + y < maxInt}y = {v : Int | 0 < (x + v) + maxInt && x + v < maxInt && v == y}x x1:Int -> x2:Int -> {v : Int | v == x1 + x2}Prelude.+ y 232: Intx x1:Int -> x2:{y : Int | 0 < (x1 - y) + maxInt && x1 - y < maxInt} -> {v : Int | v == x1 - x2}- {y : Int | 0 < (x - y) + maxInt && x - y < maxInt}y = {v : Int | 0 < (x - v) + maxInt && x - v < maxInt && v == y}x x1:Int -> x2:Int -> {v : Int | v == x1 - x2}Prelude.- y
Finally, we can tell LH that the above above instance obeys the (strict) specifications for machine arithmetic:
239: {-@ instance BoundedNum Int where 240: + :: x:Int -> y:{Int | Bounded (x+y)} -> {v:Int | v == x+y }; 241: - :: x:Int -> y:{Int | Bounded (x-y)} -> {v:Int | v == x-y } 242: @-}
With the above instance in scope, we can just use the plain +
operator and have LH flag potential overflows:
249: {-@ mono :: Int -> {v:Bool | v <=> true} @-} 250: Int -> {v : Bool | v <=> true}mono Intx = {v : Int | v == x}x x1:Int -> x2:Int -> {v : Bool | v <=> x1 < x2}< Intx + 1
4. An Application: Binary Search
The above seems a bit paranoid. Do overflows really matter? And if they do, is it really practical to check for them using the above?
Joshua Bloch’s famous article describes a tricky overflow bug in an implementation of binary-search that lay hidden in plain sight in classic textbooks and his own implementation in the JDK for nearly a decade. Gabriel Gonzalez wrote a lovely introduction to LH using binary-search as an example, and a careful reader pointed out that it had the same overflow bug!
Lets see how we might spot and fix such bugs using BoundedNum
.
(Hover over the images to animate.)
A. Off by One Lets begin by just using
the default Num Int
which ignores overflow.
As Gabriel explains, LH flags a bunch of errors
if we start the search with loop x v 0 n
as
the resulting search can access v
at any
index between 0
and n
inclusive, which
may lead to an out of bounds at n
.
We can fix the off-by-one by correcting the
upper bound to n-1
, at which point LH
reports the code free of errors.
B. Lots of Overflows To spot arithmetic overflows, we need
only hide the default Prelude
and instead import the BoundedNum
instance described above. Upon doing so, LH flags a whole bunch of
potential errors – essentially all the arithmetic operations which
seems rather dire!
C. Vector Sizes are Bounded Of course, things
aren’t so bad. LH is missing the information that
the size of any Vector
must be Bounded
. Once we
inform LH about this invariant with the
using
directive, it infers that
as the lo
and hi
indices are upper-bounded by
the Vector
’s size, all the arithmetic on them is
also Bounded
and hence, free of overflows.
D. Staying In The Middle
Well, almost all. The one pesky pink highlight that
remains is exactly the bug that Bloch made famous. Namely:
the addition used to compute the new midpoint between lo
and hi
could overflow e.g. if the array was large and both
those indices were near the end. To ensure the machine doesn’t
choke, we follow Bloch’s suggestion and re-jigger the computation
to instead compute the midpoint by splitting the difference
between hi
and lo
! the code is now free of arithmetic
overflows and truly memory safe.


Source code for kollacli.api.client
# Copyright(c) 2017, Oracle and/or its affiliates. All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License"); you may
# not use this file except in compliance with the License. You may obtain
# a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
# License for the specific language governing permissions and limitations
# under the License.
import kollacli.i18n as u
import logging
import os
import sys
from logging.handlers import RotatingFileHandler
from kollacli.api.control_plane import ControlPlaneApi
from kollacli.api.group import GroupApi
from kollacli.api.host import HostApi
from kollacli.api.password import PasswordApi
from kollacli.api.properties import PropertyApi
from kollacli.api.service import ServiceApi
from kollacli.api.support import SupportApi
from kollacli.common.utils import get_log_level
CONSOLE_MESSAGE_FORMAT = '%(message)s'
LOG_FILE_MESSAGE_FORMAT = \
'[%(asctime)s] %(levelname)-8s %(name)s %(message)s'
LOG = None
VERSION = '2.0'
[docs]class ClientApi(
ControlPlaneApi,
GroupApi,
HostApi,
PasswordApi,
PropertyApi,
ServiceApi,
SupportApi,
):
"""Client API Notes
Objects returned by the API contain a local copy of the information
in the datastore. While changes made to the local copy will be
reflected in the local object, changes made to the datastore
from other objects will not be reflected in this local copy. The
object will need to be re-fetched from the datastore to reflect
the updates.
"""
def __init__(self):
self._configure_logging()
@staticmethod
[docs] def get_version():
# type: () -> str
return VERSION
@staticmethod
[docs] def base_call():
LOG.info('base call')
@staticmethod
[docs] def enable_console_logging(level, enable=True):
# type: (int, bool) -> None
"""enable/disable console logging for the api
enable: True/False
level: logging.INFO, logging.DEBUG, logging.WARNING,
logging.CRITICAL...
"""
root_logger = logging.getLogger('')
console = logging.StreamHandler(sys.stderr)
if enable:
console.setLevel(level)
formatter = logging.Formatter(CONSOLE_MESSAGE_FORMAT)
console.setFormatter(formatter)
root_logger.addHandler(console)
else:
root_logger.removeHandler(console)
def _configure_logging(self):
global LOG
root_logger = logging.getLogger('')
root_logger.setLevel(logging.DEBUG)
handler_found = False
handlers = root_logger.handlers
for handler in handlers:
if isinstance(handler, RotatingFileHandler):
handler_found = True
break
if not handler_found:
# logger has not been set up
try:
rotate_handler = RotatingFileHandler(
os.path.join(os.path.abspath(os.sep),
'var', 'log', 'kolla', 'kolla.log'),
maxBytes=self._get_kolla_log_file_size(),
backupCount=4)
except IOError as e:
# most likely the caller is not part of the kolla group
raise IOError(u._('Permission denied to run the kolla client.'
'\nPlease add user to the kolla group and '
'then log out and back in. {error}')
.format(error=str(e)))
formatter = logging.Formatter(LOG_FILE_MESSAGE_FORMAT)
rotate_handler.setFormatter(formatter)
rotate_handler.setLevel(get_log_level())
root_logger.addHandler(rotate_handler)
LOG = logging.getLogger(__name__)
def _get_kolla_log_file_size(self):
# type: () -> int
envvar = 'KOLLA_LOG_FILE_SIZE'
size_str = os.environ.get(envvar, '500000')
try:
size = int(size_str)
except Exception:
size = 50000
return size


--- layout: post title: urmese opposition leader Aung San Suu Kyi intends to start tweeting once she is released from house arrest in order to communicate with the younger generation, her lawyer said today. The Nobel laureate has been in prison or under house arrest for 15 of the past 21 years but her current detention is due to end on 13 November. Analysts believe her sentence was designed to keep the 65-year-old locked away during Burma’s first election in 20 years, scheduled for 7 November. date: '2010-10-18T06:44:10-07:00' tags: tumblr_url: http://alexhwilliams.tumblr.com/post/1343861706/urmese-opposition-leader-aung-san-suu-kyi-intends ---
urmese opposition leader Aung San Suu Kyi intends to start tweeting once she is released from house arrest in order to communicate with the younger generation, her lawyer said today. The Nobel laureate has been in prison or under house arrest for 15 of the past 21 years but her current detention is due to end on 13 November. Analysts believe her sentence was designed to keep the 65-year-old locked away during Burma’s first election in 20 years, scheduled for 7 November.—Aung San Suu Kyi plans to join Twitter


|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object edu.mit.csail.sdg.alloy4compiler.ast.Browsable edu.mit.csail.sdg.alloy4compiler.ast.Func
public final class Func
Mutable; represents a predicate or function.
Invariant: the list of parameters do not contain duplicates
Invariant: none of the parameter declaration contains a predicate/function call
Invariant: the return type declaration does not contain a predicate/function call
| Field Summary | |
|---|---|
ConstList<Decl> |
decls
The list of parameter declarations; may be an empty list if this predicate/function has no parameters. |
boolean |
isPred
True if this is a predicate; false if this is a function. |
Pos |
isPrivate
If nonnull, then this predicate/function is private (and this.isPrivate is the location of the "private" keyword) |
java.lang.String |
label
The label of this predicate/function; it does not need to be unique. |
Pos |
pos
The location in the original file where this predicate/function is declared; never null. |
Expr |
returnDecl
The declared return type; never null. |
| Constructor Summary | |
|---|---|
Func(Pos pos,
Pos isPrivate,
java.lang.String label,
java.util.List<Decl> decls,
Expr returnDecl,
Expr body)
Constructs a new predicate/function. |
|
Func(Pos pos,
java.lang.String label,
java.util.List<Decl> decls,
Expr returnDecl,
Expr body)
Constructs a new predicate/function. |
| Method Summary | |
|---|---|
Expr |
call(Expr... args)
Convenience method that calls this function with the given list of arguments. |
int |
count()
Return the number of parameters. |
ExprVar |
get(int i)
Return the i-th parameter where i goes from 0 to count()-1 |
Expr |
getBody()
Return the body of this predicate/function. |
java.lang.String |
getHTML()
Returns the description (as HTML) to show for this node. |
java.util.List<? extends Browsable> |
getSubnodes()
Returns a list of subnodes for this node. |
java.util.List<ExprVar> |
params()
Return the list of all parameters. |
Pos |
pos()
Returns a Pos object representing the position of this Expr. |
void |
setBody(Expr newBody)
Changes the method body. |
Pos |
span()
Returns a Pos object representing the entire span of this Expr and all its subexpressions. |
java.lang.String |
toString()
Returns a human-readable description for this predicate/function |
| Methods inherited from class edu.mit.csail.sdg.alloy4compiler.ast.Browsable |
|---|
make, make, make, make, showAsTree |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
|---|
public final Pos pos
public final Pos isPrivate
public final java.lang.String label
public final boolean isPred
public final ConstList<Decl> decls
public final Expr returnDecl
| Constructor Detail |
|---|
public Func(Pos pos, java.lang.String label, java.util.List<Decl> decls, Expr returnDecl, Expr body) throws Err
The first declaration's bound should be an expression with no free variables.
The second declaration's bound should be an expression with no free variables, except possibly the parameters in first declaration.
The third declaration's bound should be an expression with no free variables, except possibly the parameters in first two declarations.
etc.
The return declaration should have no free variables, except possibly the list of input parameters.
pos
- - the original position in the filelabel
- - the label for this predicate/function (does not have to be unique)decls
- - the list of parameter declarations (can be null or an empty list if this predicate/function has no parameters)returnDecl
- - the return declaration (null if this is a predicate rather than a function)
ErrorType
- if returnType!=null and returnType cannot be unambiguously typechecked to be a set/relation
ErrorSyntax
- if the list of parameters contain duplicates
ErrorSyntax
- if at least one of the parameter declaration contains a predicate/function call
ErrorSyntax
- if this function's return type declaration contains a predicate/function call
Err
public Func(Pos pos, Pos isPrivate, java.lang.String label, java.util.List<Decl> decls, Expr returnDecl, Expr body) throws Err
The first declaration's bound should be an expression with no free variables.
The second declaration's bound should be an expression with no free variables, except possibly the parameters in first declaration.
The third declaration's bound should be an expression with no free variables, except possibly the parameters in first two declarations.
etc.
The return declaration should have no free variables, except possibly the list of input parameters.
pos
- - the original position in the fileisPrivate
- - if nonnull, then the user intended this func/pred to be "private"label
- - the label for this predicate/function (does not have to be unique)decls
- - the list of parameter declarations (can be null or an empty list if this predicate/function has no parameters)returnDecl
- - the return declaration (null if this is a predicate rather than a function)
ErrorType
- if returnType!=null and returnType cannot be unambiguously typechecked to be a set/relation
ErrorSyntax
- if the list of parameters contain duplicates
ErrorSyntax
- if at least one of the parameter declaration contains a predicate/function call
ErrorSyntax
- if this function's return type declaration contains a predicate/function call
Err
| Method Detail |
|---|
public int count()
public ExprVar get(int i)
public java.util.List<ExprVar> params()
public void setBody(Expr newBody) throws Err
ErrorSyntax
- if newBody.mult!=0
ErrorType
- if newBody cannot be unambiguously resolved
ErrorType
- if newBody's type is incompatible with the original declared type of this predicate/function
Err
public Expr getBody()
public Expr call(Expr... args)
public final java.lang.String toString()
toString
in class java.lang.Object
public final Pos pos()
pos
in class Browsable
public final Pos span()
span
in class Browsable
public java.lang.String getHTML()
getHTML
in class Browsable
public java.util.List<? extends Browsable> getSubnodes()
getSubnodes
in class Browsable
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |


One of the most widely used mobile OS these days is ANDROID. Android is a software bunch comprising not only operating system but also middleware and key applications. Android Inc was founded in Palo Alto of California, U.S. by Andy Rubin, Rich miner, Nick sears and Chris White in 2003. Later Android Inc. was acquired by Google in 2005. After original release there have been number of updates in the original version of Android.


I have officially mastered this crawling thing and it is a whole new world. For me and my parents. Lucky for them, I listen really well (better than Kunik) and have no problem coming right back or staying away from things I have no business playing with.
One of my favorite things to do is to crawl into the kitchen to see what’s going on. Sometimes Kunik and Denali follow me around, but I’m pretty sure they just think I am going to get them something to eat from the refrigerator. Not yet, but I am working on it.
Here’s a short video of me on a return trip from the kitchen:
That face at the end there is a favorite of mine . . . as is the word, “go.” I pretty much “go” everywhere now and when I’m not going, I am suggesting it. “Go!” I’ll tell the dogs to go, Dad to go, the car to go; it’s a pretty useful word and I think I like it.


On behalf of all staff I would like to welcome you to SMART SCIENCE COLLEGE Calabar.
At SMART SCIENCE COLLEGE Calabar, we aim to give every child the very best start possible to their education through vibrant and engaging teaching, enabling the children to become active learners and by using an exciting, broad and balanced curriculum.
The Early Years are crucial to a child's development and our Foundation Stage and Key Stage 1 enable the children to get their school careers off to a flying start.
Throughout the school, we want our children to enjoy a wide range of experiences which bring the curriculum to life and make learning fun. All our staff work hard to ensure the best possible quality of education for the children in every year group.
Success is something we readily celebrate, both academic and personal. We know this helps the children develop their self-confidence and self-esteem, which in turn encourages them to continue to do their very best. We hold a wide range of events throughout the year where we invite parents into the school to help us celebrate the achievements of all the children.
Our website aims to give you a taste of what SMART SCIENCE COLLEGE Calabar is all about along with a range of other useful information.
We hope this website is a useful introduction to the school. If you have any questions, please do not hesitate to call us or, better still, come and see us at work during a school day. The teachers, children and I will be very pleased to welcome you.
Senior , E. A. (Mrs)
CEO/MD
ABOUT US
Smart science high college was established in the year 1956, we were established by Professor.Dr. Akak Favour Eyo with the aim of providing stable educational background for children intrested in science about cars providing good and interactive services to our vistors.
LINKS
GALLERY
©2018 - 2019 School. All Rights Reserved


Hypertext Transfer Protocol
HTTP & HTTPS
HTTP is a protocol that is used to transfer data over a network. Essentially, this protocol is a set of rules that dictates how information is transmitted on the World Wide Web. There are 2 main types of HTTP messages; requests and responses. HTTPS is the same thing as HTTP, but with encryption. The extra "s" at the end stands for secure. HTTPS is much more secure because it uses SSL to encrypt the data that is being transferred over that network.
HTTP & HTTPS is what allows most data to be transferred over the internet. Often times we may take this for granted, but it is an important topic to understand. This is the set of rules standard rules which enables different sites to communicate with each other over a network.
The benefits of HTTPS are very apparent- See the image to the right to see why HTTPS is the preferred protocol!
Learn more about HTTP & HTTPS


class: center, middle # Python for GIS and Geoscience Specialist course Doctoral schools of Ghent University,
5-6-8 October 2020 Joris Van den Bossche, Stijn Van Hoey https://github.com/jorisvandenbossche/DS-python-geospatial --- ### Joris Van den Bossche
jorisvdbossche
,
jorisvandenbossche
* Open source software developer and teacher * Pandas, GeoPandas, scikit-learn, Apache Arrow --- ### Stijn Van Hoey
SVanHoey
,
stijnvanhoey
* Research software engineer .center[ ![:scale 90%](./img/work_stijn_1.png)] --- class: middle, section_background # Setting up a working environment --- ## Setting up a working environment For the setup instructions, see the [setup page](https://jorisvandenbossche.github.io/DS-python-geospatial/setup.html). --- class: left, middle 0. Everyone has conda installed and the environment setup? If not, see [1-install-python-and-the-required-python-packages](https://jorisvandenbossche.github.io/DS-python-geospatial/setup.html#1-install-python-and-the-required-python-packages) 1. Make sure to (re)download ALL the course material, see [2-getting-the-course-materials](https://jorisvandenbossche.github.io/DS-python-geospatial/setup.html#2-getting-the-course-materials) also if you already did this before. We had to update the material this morning... 2. Next, also do section 3 and 4 of the [setup](https://jorisvandenbossche.github.io/DS-python-geospatial/setup.html) 3. Log in to [Ufora](https://ufora.ugent.be/d2l/home/329089) and enter the course room of the '2020-10-05-morning-session' session > If you succesfully done 0, 1, 2 and 3, give a thumbs up in the discord `#status` channel. Next: - Surf to and fill in [the questionnaire](https://hackmd.io/L9fDTVspSbG7BIBJAT2xLQ?both) - In Jupyter Lab, start with the 'notebooks/00-jupyter_introduction.ipynb'. Installation or setup issues? Post them on the discord `#installation-issues` channel --- class: center, middle When you see something like this... ![:scale 100%](./img/startup.png) ...relax, you're ready to start! --- class: center, middle ![:scale 100%](https://i.ytimg.com/vi/PlaYMh-u-2w/maxresdefault.jpg) --- class: center, middle # Why python? --- class: center, middle # Python is... --- ## …WIDESPREAD * Large world-wide community ensures **fast development** * Used in **scientific** and non-scientific institutes
(Google, NASA, ESRI, VMM,...) * Python is a standard in **GIS**
(commercial and non-commercial tools) * **Multiplatform** (linux, windows,…) --- ## …REPRODUCIBLE .center[ instead of > *what did you/I clicked a few months ago?’-style WYSISYG* ] -- ## …MULTI-FUNCTIONAL * Research and development: the python *scientific ecosystem* * Webdevelopment (Django, Flask) * Daily use: great as ducttape/glue * **Automation** of time-consuming returning tasks -- ## …OPEN SOURCE * No license costs! --- ## ...SO WHAT? The Holy Grail ? No! * Commercial packages give specific support and more direct help-functions (cfr. MATLAB) * Commercial packages can be more client-friendly * For hard number-crunching stuff, NOT the fastest solution * R, Fortran, C++ etc are also ‘widespread’, so python is just a language amongst the others * Risk of getting lost in the forest/flood of ‘useful packages’ --- # Conda ### Why using conda? - Consistent package manager across Windows, Mac and Linux - Many precompiled packages available - Less problems with installation -- ### Why different environments? - Manage the dependencies of a specific project/paper/group/... - You can install different version of Python and other packages alongside on your computer - Easily share environments with other --- ## Small overview of conda commands Creating a new environment: ``` conda create -n my_env python=3.7 pandas # or from environment file conda env create -f environment.yml ``` Activating an environment: ``` conda activate my_env ``` Install a new package: ``` conda install matplotlib # if not working, try: pip install ... ``` List all installed packages: `conda list` List all your environments: `conda info -e` See the docs: http://conda.pydata.org/docs/using/index.html --- class: center, middle ### Keep track of your python ecosystem
with an `environment.yml`
``` conda env export > environment.yml ``` --- class: middle, section_background # Working with Python --- ## IPython console
.center[![:scale 75%](./img/ipython.png)] --- ## Interactive Development Environment (IDE) * [**Spyder**](https://pythonhosted.org/spyder/) is shipped with Anaconda. The familiar environment for Matlab/Rstudio-users... * [**PyCharm**](https://www.jetbrains.com/pycharm/): Popular for web-development and Django applications, powerful when doing 'real' development (packages, libraries, software) * [Eclipse + **pyDev plugin**](http://www.pydev.org/): If you like working in Eclipse, just add the python environment * [**VS Code**](https://code.visualstudio.com/), [**Atom**](https://atom.io/), ... --- ## Jupyter Notebook
(*previously called IPython notebook*)
**Jupyter notebook** provides an **interactive** scripting environment,
ideal for exploration, prototyping,... .center[![:scale 70%](./img/notebook.png)] -- ...the stuff we're dealing with in this course! --- class: middle, left ### Time is divided between - group sessions: we explain new concepts (aka 'theory') - break-out sessions: you work on exercises In case of questions, remarks, suggestions, you can always post messages in the discord `#daily-channel` ### Status check We will regularly ask for a check (ready with exercise, installation succesfull...). Use the discord `#status` channel to put 👍 (`thumbs up`). ### Feel lost? Feel free to send a discord direct message to one of us, we are stand by. --- class: middle, center ![:scale 80%](./img/issuetracker.png) Report bugs, typo's, suggestions... as issues ([New issue](https://github.com/jorisvandenbossche/DS-python-geospatial/issues/new)) or see the [contributing guidelines](https://github.com/jorisvandenbossche/DS-python-geospatial/blob/master/CONTRIBUTING.md) --- class: middle, center ## Let's start --- class: middle, center ... --- class: center, middle # How are you feeling? ![:scale 100%](http://esq.h-cdn.co/assets/15/51/980x490/landscape-1450137389-john-cleese.JPG) ### https://forms.gle/PhxSAW768fTBqLJz8 Please fill in the questionnaire! --- class: center, middle # Closing notes --- class: center, middle # Python's scientific/GIS ecosystem #### Inspired by figure by Jake VanderPlas --- class: center, middle, bgheader background-image: url(./img/ecosystem-gis-overview_6.svg) background-size: cover --- class: center, middle, bgheader background-image: url(./img/ecosystem-gis-overview_5.svg) background-size: cover --- class: center, middle, bgheader background-image: url(./img/ecosystem-gis-overview_3.svg) background-size: cover --- class: center, middle, bgheader background-image: url(./img/ecosystem-gis-overview_2.svg) background-size: cover --- class: center, middle, bgheader background-image: url(./img/ecosystem-gis-overview_1.svg) background-size: cover --- class: center, middle, bgheader background-image: url(./img/ecosystem-gis-overview.svg) background-size: cover --- # A rich ecosystem of packages
![:scale 60%](https://pysal.org/pysal1.png) Python Spatial Analysis Library (https://pysal.org). Collection of packages for: * detection of spatial clusters, hot-spots, and outliers * construction of graphs from spatial data * spatial regression and statistical modeling on geographically embedded networks * spatial econometrics * exploratory spatio-temporal data analysis * ... --- # A rich ecosystem of packages
Building up on / integrating with GeoPandas: **MovingPandas** (https://anitagraser.github.io/movingpandas/): working with movement data **Momepy** (http://docs.momepy.org/en/latest/): quantitative analysis of urban morphology **geoplot** (https://residentmario.github.io/geoplot/): high-level Python geospatial plotting library (combining GeoPandas, matplotlib and cartopy) **...** --- # A rich ecosystem of packages
Building up on / integrating with xarray: **Satpy** (https://satpy.readthedocs.io/en/stable/): package for earth-observing satellite data processing **xesmf** (https://xesmf.readthedocs.io/): Universal Regridder for Geospatial Data **verde** (https://www.fatiando.org/verde/): interpolating spatial data on regular grids **rioxarray** (https://github.com/corteva/rioxarray): linking rasterio functionality with xarray **...** --- # A rich ecosystem of packages
Several more domain/application specific packages: **MetPy** (https://unidata.github.io/MetPy): working with weather data **xgcm** (https://xgcm.readthedocs.io/en/latest/index.html): working with output from General Circulation Models **osmnx** (https://github.com/gboeing/osmnx): street networks **...** --- # A rich ecosystem of packages
**Machine learning**: scikit-learn, tensorflow, pytorch, keras, chainer, ... **Performance**: Numba, Cython, Numexpr, Pythran, C/Fortran wrappers, ... **Visualisation**: Bokeh, Seaborn, Plotnine, Altair, Plotly, Mayavi, HoloViews, datashader, vaex ... **Data structures and parallel/distributed computation**: Xarray, Dask, Distributed, Cupy, ... Specialized packages in many **scientific fields**: astronomy, natural language processing, image processing, geospatial, ... **Packaging and distribution**: pip/wheels, conda, Anaconda, Canopy, ... --- class: center, middle ### Reading advice [Good Enough Practices in Scientific Computing](https://arxiv.org/pdf/1609.00037v1.pdf) > "*However, while most scientists are careful to validate their laboratory and field equipment, most do not know how reliable their software is*" --- class: center, middle ## Good luck! ![](http://www.backwaterreptiles.com/images/pythons/angolan-python-for-sale.jpg)


--- layout: default-data title: ATT&CK® Mapping custom_css: default breadcrumb: ATT&CK® Mapping ---
The table below shows the mapping of ATT&CK® Techniques from all ATT&CK® Tactics to Active Defense Opportunities, Techniques, and Use Cases.
| ATT&CK Technique | Opportunity Space | AD Technique | Use Case | {%- for row in site.data.attack_mapping -%}
|---|---|---|---|
| {{ row.attack_technique.id }} - {{ row.attack_technique.name }} | {{ row.opportunity.description }} | {{row.technique.id}} - {{ row.technique.name }} | {{ row.use_case.description }} |


[gecode-users] Compilation error
anusha rani
anusha.maneru at gmail.com
Thu Mar 25 23:09:45 CET 2010
Hi
I am trying to compile and run send-more-money.cpp. I have installed Gecode
3.3.2 and configured it on Visual c++ 2008. But i m getting the following
error.
1>------ Build started: Project: sendmoremoney, Configuration: Debug Win32
------
1>Compiling...
1>cl : Command line warning D9035 : option 'Wp64' has been deprecated and
will be removed in a future release
1>send-more-money.cpp
1>.\send-more-money.cpp(28) : fatal error C1083: Cannot open include file:
'gecode/int.hh': No such file or directory
1>Build log was saved at "file://c:\cygwin\CPLUS\Debug\BuildLog.htm"
1>sendmoremoney - 1 error(s), 1 warning(s)
========== Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped ==========
Could you help me to find out where i am doing worng ?
Thanks in advance
MVH
Anusha.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.gecode.org/pipermail/users/attachments/20100325/24da6b48/attachment.htm>
More information about the users
mailing list


{{mymap.js}}
Flask Google Maps Example
Comments
MAP
Stop MAP
Data
Generated in view
{{mymap.html}}
Comments


Predicting the aggregate risk emerging in stock markets is of paramount importance.
I investigate both theoretically and empirically information contagion and systemic risk in stocks markets, when investors are sensitive to news about the stocks, bad news about a number of stocks can adversely spill over to other stocks. We study this information contagion in a number of stock mrkets.
Systemic risk is defined as the probability of joint movement in the stock market prices.
Difference in the Survival and the Specificity-Sensitivity-Prevalence Impacts
Author scientific profile:
Statistics and Applied Mathematics for Data Analytics, Identify opportunities to apply Mathematical Statistics, Numerical Methods, Machine Learning and Pattern Recognition to investigate and implement solutions to the field of Data Content Analytics. Data prediction via computational methods to predict from massive amounts of data (Big Data Content). These methods included clustering, regression, survival analysis, neural network, classification , ranking, deep discrepancy learning .


Toggle navigation
Home
Newsfeed
Newsfeed
Images
My friends
My Profile
My info
My Albums
My Friends
Admin
Logout
Principal Name
Count friends
My Newsfeed
Friends
Images
Add URL address of video
×
Video URL
Must be URL address.
Add location address
×
Location address
Must be location address.
Publish
Public
Private
My Friend
Friend Name
Suggestions
Non friend Name
Non friend Name
Add friend


Total Users
Total Movies
Total Rooms
Total Bookings
is the last registered user
is the last added room
is the last added movie


GCS Client Uploads
Upload through App Engine
Upload
Upload directly to GCS
Upload
Result
Upload time:
Upload URL:
Display URL:


There are several pairs of test programs in the test dir. These use the CSlib:
| client.cpp, server.cpp | serial client/server in C++ |
| client_c.cpp, server_c.cpp | serial c/s in C |
| client_f90.f90, server_f90.f90 | serial c/s in Fortran 90 |
| client.py, server.py | serial c/s in Python |
| client_parallel.cpp, server_parallel.cpp | parallel c/s in C++ |
| client_parallel_c.cpp, server_parallel_c.cpp | parallel c/s in C |
| client_parallel_f90.f90, server_parallel_f90.f90 | parallel c/s in Fortran 90 |
| client.parallel_py, server_parallel.py | serial c/s in Python |
These are stand-alone apps which do not use the CSlib:
| simple_client_zmq, simple_server_zmq | c/s in native ZMQ |
| simple_client_mpi_one, simple_server_mpi_one | c/s in native MPI via single mpirun |
| simple_client_mpi_two, simple_server_mpi_two | c/s in native MPI via two mpiruns |
Codes in the first table (CSlib test apps) illustrate how to use the CSlib from different languages, for both serial and MPI parallel applications. Codes in the second table (simple test apps) do not use the CSlib. They are bare-bones codes that call the zeroMQ (ZMQ) and MPI libraries directly. They can be useful for debugging if the CSlib tests do not build or work properly on your system for some reason.
The CSlib test apps written in C++ instantiate the CSlib as a C++ class. The C apps are actually written in (vanilla) C++ but call the CSlib through its C interface, just as a true C program would. The Fortran programs also call the CSlib through its C interface, using a Fortran iso_c_binding interface file (src/cslib_wrap.f90 or test/cslib_wrap.f90). The Python scripts use the Python interface in src/cslib.py), which in turn wraps the C interface of the CSlib.
The serial CSlib test apps must each be run on a single processor. The parallel CSlib test apps can be run via mpirun on any number of processors, including a single processor. Parallel client and server apps can run on different numbers of processors. You can run a serial client app with a parallel server app, or vice versa. You can run a client app in one language with a server app in another language.
All the CSlib test apps are functionally identical. They exercise the complete set of library calls for the CSlib. They can be run in any of the messaging modes (except the serial apps cannot use an MPI mode). The client sends a set of vectors and scalars to the server. The server receives them, increments the vectors and scalars, and sends them back to the client. The client receives them, and updates the data in its vectors and scalars. This is repeated N times after which the client sends an all-done message to the server. The vector length is an input to both the client and server; the iteration count N in an input to the client. The Python apps also have an input for which Python data type to use for vectors (lists or tuples, Numpy array, ctypes vectors), since the CSlib Python wrapper (src/cslib.py) will work with all 3.
At the end of a run, both the client and server app should exit cleanly. The client prints stats and timing info about the run, including the effective messaging bandwidth. It also prints an error metric on the max difference for any element of any of the vectors or scalars, between the acutal versus expected value. If it is non-zero and tiny, there may have been some accumulated round-off error for floating point arithmetic. If it is not tiny, there is likely a bug in the test program or the CSlib.


jQuery UI - change rules demo - ui.formValidator
Set new validation rules (incl. textarea)
Fields with an asterix (
*
) are needed.
Input's
Text Input (email)
*
Textarea
Copyright (c) 2009-2012
Felix Nagel
.
jQuery Acessible RIA
are licensed under the
MIT license
.


We want freeCodeCamp.org to look and feel like the command line interfaces and code editors that professional developers use for work.
We couple this "command line chic" aesthetic with large fonts, high-contrast layouts, and explicit buttons and links.
Here are some examples:
Our logo appears in two variations.
The freeCodeCamp logo is designed for use primarily on dark backgrounds. For instances in which the full color logo is not practical, the following color combinations are approved alternatives.
freeCodeCamp uses the following types with various font weights in large sizes (minimum 18px) to ensure readability and typographical hierarchy:
We use Roboto Mono as a primary monospace font.
Download Roboto MonoWe use Lato as a primary proportional font in longer sections of text.
Download LatoWe use SaxMono as the font in our logo.
Download SaxMonoWe use Menlo for our browser-based code editor.
Download MenloTo achieve a flexible dark and light theme, freeCodeCamp's layouts consist of four color pairs with various contrast levels.
The contrast difference between two colors in a pair represent their visual hierarchy.
For instance, the pair with the highest contrast difference is reserved for primary background and content.
This system allows flawless theme changes by switching the colors in each pair and preseving their contrast and visual hierarchy.
#ffffff
#0a0a23
#f5f6f7
#1b1b32
#dfdfe2
#2a2a40
#d0d0d5
#3b3b4f
freeCodeCamp accent colors consist of two sets of four colors. The primary colors are used on a dark background and the secondary colors are used on a light background.
#dbb8ff
#f1be32
#99c9ff
#acd157
#5a01a7
#4d3800
#002ead
#00471b
To maintain the integrity of the freeCodeCamp logo, it is important that you provide adequate space around the logo.
To ensure enough spacing, give 50px or greater padding to each side.
The consistent application of color plays an extremely important role in the freeCodeCamp identity system.
The examples below illustrate a few inappropriate applications of the logo.
Feel free to reach out to us at<EMAIL_ADDRESS>with any questions about this freeCodeCamp style guide.


State of the Dev Setup: 2014
I thought I would write a short article based on this years development environment. It seems that, as web developers, our stack goes through changes, sometimes very small over time, sometimes not much for a long time, then spikes of new, then back to being the same for a while again. So why not publish my current dev stack that I have been using for the year of 2014.
2014 has been an amazing year, working for [Copirite](http://copirite.com.au] a design, web and print company on the Gold Coast in Australia. My role has required me to build many web apps/website hybrids, these are sites that require a bit more than your standard WordPress/Drupal/Other Out of/Semi out of the box CMS. Rails has been the choice since I started working there for a majority of the projects, and I can’t see many if any that I would change after the projects have been completed.
My stack is as follows:
Hardware
- Retina MPB
- Dual Monitor Setup with laptop in clamshell mode (24inch screens)
- Blue Yeti microphone (fairly recent)
- Misc Apple devices (yea its a give in, I love Apple products)
Software
- Vim
- Tmux
- iTerm
- Google Chrome
- Firefox
- Safari
- Paw HTTP Rest Client
- Adobe Creative Cloud
- Sketch
- Skype
- Screenhero
- Airmail
- Dropbox
- Alfred
- Dash
- Evernote
- Hazel
- Screenflow
- Monosnap
Services
- Github
- Codeship
- CodeClimate
- devbase.io
- Egghead.io
- Feedly
- Slack
- Digital Ocean
Technologies
- Ruby on Rails
- WordPress
- Drupal (small amount)
- Jekyll
- Bower
- Grunt
- Gulp
- Sass
- Ruby
- chruby
- Ruby Install
Workflow
Generally my workflow is with rails applications. While I started out using pow for nearly every project, I have gone back to good old rails s.
I have been using a terminal based workflow, using tmux sessions with Tmuxinator and vim as my editor of choice. This leaves me in the terminal most of the time (at least one monitor making up the terminal, another for web browsers etc).
I have used atom on the rare occassion as well (without the vim bindings), which is a nice editor, but I still feel at home in vim.
I have changed from using RVM as my ruby version manager/switcher, to using chruby and ruby install. I love RVM, and it solved a lot of issues, but after switching to chruby, it feels a lot lighter and a lot nicer. RVM 2 is in the works, I may look at it again, but for a simple ruby switcher, chruby covers everything I need.
I have been dabbling in Chef to automate some infrastructure but have found myself now really loving ansible, its just much more digestible and less of a learning curve. While I am not using any of them in production I will be in 2015, hopefully along with docker (at least for my local dev environments for new projects).
All projects are still kept in git, most being hosted on GitHub, but some through gitlab on a private server I have. Which reminds me, Digital Ocean is my current server provider of choice, they have been fantastic and have suited every project I have had to work on.
Anyway that is it for now, I may do a revised post of this at the end of the year / start of 2015 just incase anything changes.


We are creating a more transparent space for construction. We will allow for sharing documents and easy access of information. It is time for the construction industry to adapt to new techonlogies and reap the rewards.
Get Started!Our software will allow for better money management that takes processing out of payments, making your life easier
Fly above your competition by using these new technologies that will make the whole process of construction management smoother
Store all of your documents in one location and give access to the people who need it most. Don't let a system interrupt your current processes.
We have been there, we know what you are going through. We know how to help


The motivation
I am an economist by training, that was somehow drawn into Data Science. Since the field is a multidisciplinary one, most people landing on it, initially do miss some of the pieces of the puzzle. I have tried different ways to fill in the gaps: formal training, personal study, online courses, summer school (actually the best experience was in BigDive. Yet I was finding difficult to get all the details right and get a project from A to Z. No wonder since the field is so varied. So, this project grew out of the personal need to get all the pieces together. The main way to learn something is to practice it; and that's what I did. Once you do that though, the next best thing is to explain to someone else what you just did .
The objectives
You can think of this blog as a free online course with 3 objectives:
- Present a unifying framework; a necessary starting point in a multidisciplinary field
- Provide enough knowledge from the various fields, so that a person can pull through with Data Science project. At the same time let people know where they should look at for the things that they don't know
- Create a production line made of software that processes data and produces insights. One should then be able to plug this production line and use it in any new project
One can find all the code and the documentation for the projects presented here, at GitHub
I would be particularly glad to receive feedback for the blog. Get in contact with me here<EMAIL_ADDRESS>Enjoy!


module OpenSSL::ASN1
Abstract Syntax Notation One (or ASN.1) is a notation syntax to describe data structures and is defined in ITU-T X.680. ASN.1 itself does not mandate any encoding or parsing rules, but usually ASN.1 data structures are encoded using the Distinguished Encoding Rules (DER) or less often the Basic Encoding Rules (BER) described in ITU-T X.690. DER and BER encodings are binary Tag-Length-Value (TLV) encodings that are quite concise compared to other popular data description formats such as XML, JSON etc. ASN.1 data structures are very common in cryptographic applications, e.g. X.509 public key certificates or certificate revocation lists (CRLs) are all defined in ASN.1 and DER-encoded. ASN.1, DER and BER are the building blocks of applied cryptography. The ASN1 module provides the necessary classes that allow generation of ASN.1 data structures and the methods to encode them using a DER encoding. The decode method allows parsing arbitrary BER-/DER-encoded data to a Ruby object that can then be modified and re-encoded at will.
ASN.1 class hierarchy¶ ↑
The base class representing ASN.1 structures is ASN1Data. ASN1Data offers attributes to read and set
the tag
, the tag_class
and finally the
value
of a particular ASN.1 item. Upon parsing, any tagged
values (implicit or explicit) will be represented by ASN1Data instances because their “real type”
can only be determined using out-of-band information from the ASN.1 type
declaration. Since this information is normally known when encoding a type,
all sub-classes of ASN1Data offer an
additional attribute tagging
that allows to encode a value
implicitly (:IMPLICIT
) or explicitly (:EXPLICIT
).
Constructive¶ ↑
Constructive is, as its name implies, the base class for all constructed encodings, i.e. those that consist of several values, opposed to “primitive” encodings with just one single value. Primitive values that are encoded with “infinite length” are typically constructed (their values come in multiple chunks) and are therefore represented by instances of Constructive. The value of an Constructive is always an Array.
ASN1::Set and ASN1::Sequence¶ ↑
The most common constructive encodings are SETs and SEQUENCEs, which is why there are two sub-classes of Constructive representing each of them.
Primitive¶ ↑
This is the super class of all primitive values. Primitive itself is not used when parsing ASN.1 data, all values are either instances of a corresponding sub-class of Primitive or they are instances of ASN1Data if the value was tagged implicitly or explicitly. Please cf. Primitive documentation for details on sub-classes and their respective mappings of ASN.1 data types to Ruby objects.
Possible values for tagging
¶ ↑
When constructing an ASN1Data object the
ASN.1 type definition may require certain elements to be either implicitly
or explicitly tagged. This can be achieved by setting the
tagging
attribute manually for sub-classes of ASN1Data. Use the symbol
:IMPLICIT
for implicit tagging and :EXPLICIT
if
the element requires explicit tagging.
Possible values for tag_class
¶ ↑
It is possible to create arbitrary ASN1Data objects that also support a PRIVATE
or APPLICATION tag class. Possible values for the tag_class
attribute are:
-
:UNIVERSAL
(the default for untagged values) -
:CONTEXT_SPECIFIC
(the default for tagged values) -
:APPLICATION
-
:PRIVATE
Tag constants¶ ↑
There is a constant defined for each universal tag:
-
OpenSSL::ASN1::EOC (0)
-
OpenSSL::ASN1::BOOLEAN (1)
-
OpenSSL::ASN1::INTEGER (2)
-
OpenSSL::ASN1::BIT_STRING (3)
-
OpenSSL::ASN1::OCTET_STRING (4)
-
OpenSSL::ASN1::NULL (5)
-
OpenSSL::ASN1::OBJECT (6)
-
OpenSSL::ASN1::ENUMERATED (10)
-
OpenSSL::ASN1::UTF8STRING (12)
-
OpenSSL::ASN1::SEQUENCE (16)
-
OpenSSL::ASN1::SET (17)
-
OpenSSL::ASN1::NUMERICSTRING (18)
-
OpenSSL::ASN1::PRINTABLESTRING (19)
-
OpenSSL::ASN1::T61STRING (20)
-
OpenSSL::ASN1::VIDEOTEXSTRING (21)
-
OpenSSL::ASN1::IA5STRING (22)
-
OpenSSL::ASN1::UTCTIME (23)
-
OpenSSL::ASN1::GENERALIZEDTIME (24)
-
OpenSSL::ASN1::GRAPHICSTRING (25)
-
OpenSSL::ASN1::ISO64STRING (26)
-
OpenSSL::ASN1::GENERALSTRING (27)
-
OpenSSL::ASN1::UNIVERSALSTRING (28)
-
OpenSSL::ASN1::BMPSTRING (30)
UNIVERSAL_TAG_NAME constant¶ ↑
An Array that stores the name of a given tag number. These names are the same as the name of the tag constant that is additionally defined, e.g. UNIVERSAL_TAG_NAME = “INTEGER” and OpenSSL::ASN1::INTEGER = 2.
Example usage¶ ↑
Decoding and viewing a DER-encoded file¶ ↑
require 'openssl' require 'pp' der = File.binread('data.der') asn1 = OpenSSL::ASN1.decode(der) pp der
Creating an ASN.1 structure and DER-encoding it¶ ↑
require 'openssl' version = OpenSSL::ASN1::Integer.new(1) # Explicitly 0-tagged implies context-specific tag class serial = OpenSSL::ASN1::Integer.new(12345, 0, :EXPLICIT, :CONTEXT_SPECIFIC) name = OpenSSL::ASN1::PrintableString.new('Data 1') sequence = OpenSSL::ASN1::Sequence.new( [ version, serial, name ] ) der = sequence.to_der
Constants
- UNIVERSAL_TAG_NAME
Array storing tag names at the tag's index.
Public Class Methods
Decodes a BER- or DER-encoded value and creates an ASN1Data instance. der
may be a
String
or any object that features a #to_der
method transforming it into a BER-/DER-encoded String
.
Example¶ ↑
der = File.binread('asn1data') asn1 = OpenSSL::ASN1.decode(der)
static VALUE ossl_asn1_decode(VALUE self, VALUE obj) { VALUE ret; unsigned char *p; VALUE tmp; long len, read = 0, offset = 0; obj = ossl_to_der_if_possible(obj); tmp = rb_str_new4(StringValue(obj)); p = (unsigned char *)RSTRING_PTR(tmp); len = RSTRING_LEN(tmp); ret = ossl_asn1_decode0(&p, len, &offset, 0, 0, &read); RB_GC_GUARD(tmp); int_ossl_decode_sanity_check(len, read, offset); return ret; }
Similar to decode
with the difference that decode
expects one distinct value represented in der
.
decode_all
on the contrary decodes a sequence of sequential
BER/DER values lined up in der
and returns them as an array.
Example¶ ↑
ders = File.binread('asn1data_seq') asn1_ary = OpenSSL::ASN1.decode_all(ders)
static VALUE ossl_asn1_decode_all(VALUE self, VALUE obj) { VALUE ary, val; unsigned char *p; long len, tmp_len = 0, read = 0, offset = 0; VALUE tmp; obj = ossl_to_der_if_possible(obj); tmp = rb_str_new4(StringValue(obj)); p = (unsigned char *)RSTRING_PTR(tmp); len = RSTRING_LEN(tmp); tmp_len = len; ary = rb_ary_new(); while (tmp_len > 0) { long tmp_read = 0; val = ossl_asn1_decode0(&p, tmp_len, &offset, 0, 0, &tmp_read); rb_ary_push(ary, val); read += tmp_read; tmp_len -= tmp_read; } RB_GC_GUARD(tmp); int_ossl_decode_sanity_check(len, read, offset); return ary; }
If a block is given, it prints out each of the elements encountered. Block parameters are (in that order):
-
depth: The recursion depth, plus one with each constructed value being encountered (Number)
-
offset: Current byte offset (Number)
-
header length: Combined length in bytes of the Tag and Length headers. (Number)
-
length: The overall remaining length of the entire data (Number)
-
constructed: Whether this value is constructed or not (Boolean)
-
tag_class: Current tag class (Symbol)
-
tag: The current tag (Number)
Example¶ ↑
der = File.binread('asn1data.der') OpenSSL::ASN1.traverse(der) do | depth, offset, header_len, length, constructed, tag_class, tag| puts "Depth: #{depth} Offset: #{offset} Length: #{length}" puts "Header length: #{header_len} Tag: #{tag} Tag class: #{tag_class} Constructed: #{constructed}" end
static VALUE ossl_asn1_traverse(VALUE self, VALUE obj) { unsigned char *p; VALUE tmp; long len, read = 0, offset = 0; obj = ossl_to_der_if_possible(obj); tmp = rb_str_new4(StringValue(obj)); p = (unsigned char *)RSTRING_PTR(tmp); len = RSTRING_LEN(tmp); ossl_asn1_decode0(&p, len, &offset, 0, 1, &read); RB_GC_GUARD(tmp); int_ossl_decode_sanity_check(len, read, offset); return Qnil; }


This is a simple vue app to capture work needed and people who might be interested in helping
What do you want to do?
Login Skills Resources Projects Logout


--- fabricator: true ---
Relatively complex UI components composed of groups of molecules and/or atoms, and/or other organisms.


About the devs:
Calla Rudolph
- I've worked in hotels for ten years, so I know all of the secrets.
- I went to Epicodus to create a better life for my fur babies.
- I like potatoes.
Brittany Hardison
- I am the daughter of an art teacher and have always enjoyed creating things so I enrolled in Epicodus.
- I like to hike, practice yoga and play piano.
- One of my favorite places in the world is Portugal and I would go there at the drop of a hat.
Max Scher
- New dad with a love for pasta and stand-up comedy.
- Sold movies to movie theaters (yes, that's a thing), but currently build killer apps for the web. Apps that are killer. Not apps that kill... you get it.
- Moved to Portland because it was so green, but then a teenager set it on fire. #FML
Michelle Poterek
- I have a degree in geology but please don't take me to a party and ask to identify the rocks you found on a beach.
- My favorite party game is "Nicki Minaj or Beyonce" in which I bring up quotes and ask who said it. Ex: "I sneezed on the beat and the beat got sicker."
- I love eating pizza and collaborating on music projects.
Larry Taylor
- Got a degree in Theatre Arts (it seemed like a good idea at the time).
- Is an ordained minister for no reason at all.
- Has never had a dog.


Welcome to the "Implementing a language with LLVM" tutorial. This tutorial runs through the implementation of a simple language, showing how fun and easy it can be. This tutorial will get you up and started as well as help to build a framework you can extend to other languages. The code in this tutorial can also be used as a playground to hack on other LLVM specific things.
The goal of this tutorial is to progressively unveil our language, describing how it is built up over time. This will let us cover a fairly broad range of language design and LLVM-specific usage issues, showing and explaining the code for it all along the way, without overwhelming you with tons of details up front.
It is useful to point out ahead of time that this tutorial is really about teaching compiler techniques and LLVM specifically, not about teaching modern and sane software engineering principles. In practice, this means that we'll take a number of shortcuts to simplify the exposition. For example, the code leaks memory, uses global variables all over the place, doesn't use nice design patterns like visitors, etc... but it is very simple. If you dig in and use the code as a basis for future projects, fixing these deficiencies shouldn't be hard.
I've tried to put this tutorial together in a way that makes chapters easy to skip over if you are already familiar with or are uninterested in the various pieces. The structure of the tutorial is:
By the end of the tutorial, we'll have written a bit less than 700 lines of non-comment, non-blank, lines of code. With this small amount of code, we'll have built up a very reasonable compiler for a non-trivial language including a hand-written lexer, parser, AST, as well as code generation support with a JIT compiler. While other systems may have interesting "hello world" tutorials, I think the breadth of this tutorial is a great testament to the strengths of LLVM and why you should consider it if you're interested in language or compiler design.
A note about this tutorial: we expect you to extend the language and play with it on your own. Take the code and go crazy hacking away at it, compilers don't need to be scary creatures - it can be a lot of fun to play with languages!
This tutorial will be illustrated with a toy language that we'll call "Kaleidoscope" (derived from "meaning beautiful, form, and view"). Kaleidoscope is a procedural language that allows you to define functions, use conditionals, math, etc. Over the course of the tutorial, we'll extend Kaleidoscope to support the if/then/else construct, a for loop, user defined operators, JIT compilation with a simple command line interface, etc.
Because we want to keep things simple, the only datatype in Kaleidoscope is a 64-bit floating point type (aka 'double' in C parlance). As such, all values are implicitly double precision and the language doesn't require type declarations. This gives the language a very nice and simple syntax. For example, the following simple example computes Fibonacci numbers:
# Compute the x'th fibonacci number. def fib(x) if x < 3 then 1 else fib(x-1)+fib(x-2) # This expression will compute the 40th number. fib(40)
We also allow Kaleidoscope to call into standard library functions (the LLVM JIT makes this completely trivial). This means that you can use the 'extern' keyword to define a function before you use it (this is also useful for mutually recursive functions). For example:
extern sin(arg); extern cos(arg); extern atan2(arg1 arg2); atan2(sin(.4), cos(42))
A more interesting example is included in Chapter 6 where we write a little Kaleidoscope application that displays a Mandelbrot Set at various levels of magnification.
Lets dive into the implementation of this language!
When it comes to implementing a language, the first thing needed is the ability to process a text file and recognize what it says. The traditional way to do this is to use a "lexer" (aka 'scanner') to break the input up into "tokens". Each token returned by the lexer includes a token code and potentially some metadata (e.g. the numeric value of a number). First, we define the possibilities:
// The lexer returns tokens [0-255] if it is an unknown character, otherwise one // of these for known things. enum Token { tok_eof = -1, // commands tok_def = -2, tok_extern = -3, // primary tok_identifier = -4, tok_number = -5, }; static std::string IdentifierStr; // Filled in if tok_identifier static double NumVal; // Filled in if tok_number
Each token returned by our lexer will either be one of the Token enum values or it will be an 'unknown' character like '+', which is returned as its ASCII value. If the current token is an identifier, the IdentifierStr global variable holds the name of the identifier. If the current token is a numeric literal (like 1.0), NumVal holds its value. Note that we use global variables for simplicity, this is not the best choice for a real language implementation :).
The actual implementation of the lexer is a single function named gettok. The gettok function is called to return the next token from standard input. Its definition starts as:
/// gettok - Return the next token from standard input. static int gettok() { static int LastChar = ' '; // Skip any whitespace. while (isspace(LastChar)) LastChar = getchar();
gettok works by calling the C getchar() function to read characters one at a time from standard input. It eats them as it recognizes them and stores the last character read, but not processed, in LastChar. The first thing that it has to do is ignore whitespace between tokens. This is accomplished with the loop above.
The next thing gettok needs to do is recognize identifiers and specific keywords like "def". Kaleidoscope does this with this simple loop:
if (isalpha(LastChar)) { // identifier: [a-zA-Z][a-zA-Z0-9]* IdentifierStr = LastChar; while (isalnum((LastChar = getchar()))) IdentifierStr += LastChar; if (IdentifierStr == "def") return tok_def; if (IdentifierStr == "extern") return tok_extern; return tok_identifier; }
Note that this code sets the 'IdentifierStr' global whenever it lexes an identifier. Also, since language keywords are matched by the same loop, we handle them here inline. Numeric values are similar:
if (isdigit(LastChar) || LastChar == '.') { // Number: [0-9.]+ std::string NumStr; do { NumStr += LastChar; LastChar = getchar(); } while (isdigit(LastChar) || LastChar == '.'); NumVal = strtod(NumStr.c_str(), 0); return tok_number; }
This is all pretty straight-forward code for processing input. When reading a numeric value from input, we use the C strtod function to convert it to a numeric value that we store in NumVal. Note that this isn't doing sufficient error checking: it will incorrectly read "<IP_ADDRESS>" and handle it as if you typed in "1.23". Feel free to extend it :). Next we handle comments:
if (LastChar == '#') { // Comment until end of line. do LastChar = getchar(); while (LastChar != EOF && LastChar != '\n' && LastChar != '\r'); if (LastChar != EOF) return gettok(); }
We handle comments by skipping to the end of the line and then return the next token. Finally, if the input doesn't match one of the above cases, it is either an operator character like '+' or the end of the file. These are handled with this code:
// Check for end of file. Don't eat the EOF. if (LastChar == EOF) return tok_eof; // Otherwise, just return the character as its ascii value. int ThisChar = LastChar; LastChar = getchar(); return ThisChar; }
With this, we have the complete lexer for the basic Kaleidoscope language (the full code listing for the Lexer is available in the next chapter of the tutorial). Next we'll build a simple parser that uses this to build an Abstract Syntax Tree. When we have that, we'll include a driver so that you can use the lexer and parser together.
Next: Implementing a Parser and AST


--- layout: post title: Emotion design and I-mode date: 2005-01-04 00:00:00 category: mobile ---
"The products cited most often in Japan's consumer electronics rebirth ... include digital cameras, high-definition TVs and DVD players, along with the components that go in them. In these devices and others, domestic manufacturers have continued to hone an edge in turning aluminum, plastic and little cartoon characters into art.": The emotional aspect of i-mode design


Public Member Functions | |
| State () | |
| Construct the compiler state object. More... | |
| automaton | getAutomaton (int optimiseLevel) |
| Returns a function pointer for the automaton at the specified optimisation level. | |
Public Attributes | |
| LLVMContext & | C |
| LLVM uses a context object to allow multiple threads. | |
| Module * | Mod |
| The compilation unit that we are generating. | |
| Function * | F |
| The function representing the program. | |
| IRBuilder | B |
| A helper class for generating instructions. | |
| Value * | a [10] |
| The 10 local registers in the source language. | |
| Value * | g [10] |
| The 10 global registers in the source language. | |
| Value * | oldGrid |
| The input grid (passed as an argument) | |
| Value * | newGrid |
| The output grid (passed as an argument) | |
| Value * | width |
| The width of the grid (passed as an argument) | |
| Value * | height |
| The height of the grid (passed as an argument) | |
| Value * | x |
| The x coordinate of the current cell (passed as an argument) | |
| Value * | y |
| The y coordinate of the current cell (passed as an argument) | |
| Value * | v |
| The value of the current cell (passed as an argument, returned at the end) | |
| Type * | regTy |
| The type of our registers (currently i16) | |
Definition at line 60 of file compiler.cc.
|
inline |
Construct the compiler state object.
This loads the runtime.bc support file and prepares the module, including setting up all of the LLVM state required.
Definition at line 98 of file compiler.cc.


Plenty more to be gleaned from this. Well written, referenced and clear. Worth reading more.
"Many scholars are convinced that boundary objects (BOs) can play a key facilitating role
in inter-departmental problem solving. BOs are physical artifacts that provide a common
language and promote shared understanding about a problem or a situation among a group of
individuals to reach a mutually satisfactory resolution. For example, a medical chart in a
hospital is a physical artifact usually presented in a standardized format that serves as a BO."
"Much of the existing research on BOs examines their use in problem solving contexts
such as new product design and development (e.g., Bechky, 2003; Carlile, 2002, 2004;
Henderson, 1991, 1995)."
"Yakura (2002) investigated the role of a Gantt chart (visual artifact to
represent a project timeline) as a temporal BO between an information technology (IT)
consultant and its client, a public utility company, in managing the progress of an IT project. The
Gantt chart became an effective temporal BO in interpretation and negotiation between the IT
consultant and its client."
"Bechky (2003), from her empirical research in a semiconductor equipment manufacturing
company, finds tangible BOs, such as prototypes, to be more effective than drawings in creating
common ground between two departments (design and assembly) because such objects invoke
the necessary elements of work context."
"From these studies it appears that an appropriate BO in one setting can become a
boundary roadblock in another setting, even when the problem solving contexts are very similar,
i.e., producing a new product."