Bacon ipsum dolor amet hamburger ball tip tongue, t-bone brisket leberkas biltong spare ribs. Pork ribeye pork belly, beef pastrami turkey tenderloin strip steak frankfurter. Rump chuck landjaeger cow bresaola pig. Drumstick alcatra short loin turkey, capicola jerky leberkas chuck venison burgdoggen rump prosciutto brisket turducken sirloin. Pastrami sirloin alcatra beef ribs shoulder picanha bresaola, spare ribs pork chop ball tip capicola turducken kevin. Bresaola biltong pork loin salami pork belly jerky shankle pancetta tenderloin beef ribs ham hock short loin beef leberkas. Chuck kevin cow, sirloin bresaola cupim burgdoggen rump meatball doner venison corned beef spare ribs short ribs landjaeger.
Tongue beef ribs cow bresaola pork loin tri-tip, beef biltong meatloaf ham.  Swine filet mignon kielbasa capicola, beef pork chop kevin short loin ribeye corned beef tri-tip. Tri-tip hamburger spare ribs alcatra meatloaf sirloin.
Biltong beef ribs short loin meatball shank t-bone. Chuck chicken corned beef turkey picanha fatback, kielbasa meatloaf pork chop pastrami hamburger filet mignon. Flank ball tip salami beef biltong. Meatloaf porchetta sirloin t-bone. Beef alcatra corned beef landjaeger.
 Strip steak tri-tip burgdoggen short loin prosciutto swine tongue beef ribs turkey. Ham hock rump pork loin, picanha andouille jerky spare ribs. Meatloaf andouille ribeye jerky, jowl meatball tongue kielbasa short ribs t-bone pork loin cupim pork chop tail bresaola.


Where is everyone?
{%for name, info in users.items()%}
{{name}}: {{info.room}} at {{info.dt}}
{%endfor%}


Ideological matching is a work in progress, and is much less accurate than the values and axes.
You can send these results by copying and pasting the URL at the top of the page, share the image below, or screenshotting this page. Think your matched ideology was wrong? Want to help us calibrate the test? Send the results along with your political ideology to u/DatGuard, u/lexsiek2005 or u/ETHICALDARWINISM on Reddit, or Mr. Fish#6394 on Discord. Feel free to send us any comments, questions, or criticism.


Draw.Fill
Syntax
Draw.Fill (x, y : int, fillColor, borderColor : int)
Description
The Draw.Fill procedure is used to color in a figure that is on the screen. Starting at (x, y), the figure is filled with fillColor to a surrounding border whose color is borderColor.
Example
This program draws an oval with x and y radius of 10 in the center of the screen in bright green. Then the oval is filled with red. The maxx and maxy functions are used to determine the maximum x and y values on the screen.
View.Set ("graphics")
const midx := maxx div 2
const midy := maxy div 2
Draw.Oval (midx, midy, 10, 10, brightgreen)
Draw.Fill (midx, midy, red, brightgreen)
Details
The screen must be in a "graphics" mode. See the View.Set procedure for details. If the screen is not in a "graphics" mode, an error will occur.
Status
Exported qualified.
This means that you can only call the function by calling Draw.Fill, not by calling Fill.
See also
View.Set, maxx, maxy and the various procedures in the Draw unit.


module ActiveRecord::Sanitization::ClassMethods
Protected Instance Methods
Accepts a hash of SQL conditions and replaces those attributes that
correspond to a composed_of
relationship with their expanded
aggregate attribute values. Given:
class Person < ActiveRecord::Base composed_of :address, class_name: "Address", mapping: [%w(address_street street), %w(address_city city)] end
Then:
{ address: Address.new("813 abc st.", "chicago") } # => { address_street: "813 abc st.", address_city: "chicago" }
# File lib/active_record/sanitization.rb, line 56 def expand_hash_conditions_for_aggregates(attrs) expanded_attrs = {} attrs.each do |attr, value| if aggregation = reflect_on_aggregation(attr.to_sym) mapping = aggregation.mapping mapping.each do |field_attr, aggregate_attr| if mapping.size == 1 && !value.respond_to?(aggregate_attr) expanded_attrs[field_attr] = value else expanded_attrs[field_attr] = value.send(aggregate_attr) end end else expanded_attrs[attr] = value end end expanded_attrs end
Accepts an array of conditions. The array has each value sanitized and interpolated into the SQL statement.
["name='%s' and group_id='%s'", "foo'bar", 4] returns "name='foo''bar' and group_id='4'"
# File lib/active_record/sanitization.rb, line 123 def sanitize_sql_array(ary) statement, *values = ary if values.first.is_a?(Hash) && statement =~ /:\w+/ replace_named_bind_variables(statement, values.first) elsif statement.include?('?') replace_bind_variables(statement, values) elsif statement.blank? statement else statement % values.collect { |value| connection.quote_string(value.to_s) } end end
Accepts an array, hash, or string of SQL conditions and sanitizes them into a valid SQL fragment for a SET clause.
{ name: nil, group_id: 4 } returns "name = NULL , group_id='4'"
# File lib/active_record/sanitization.rb, line 37 def sanitize_sql_for_assignment(assignments, default_table_name = self.table_name) case assignments when Array; sanitize_sql_array(assignments) when Hash; sanitize_sql_hash_for_assignment(assignments, default_table_name) else assignments end end
Accepts an array, hash, or string of SQL conditions and sanitizes them into a valid SQL fragment for a WHERE clause.
["name='%s' and group_id='%s'", "foo'bar", 4] returns "name='foo''bar' and group_id='4'" { name: "foo'bar", group_id: 4 } returns "name='foo''bar' and group_id='4'" "name='foo''bar' and group_id='4'" returns "name='foo''bar' and group_id='4'"
# File lib/active_record/sanitization.rb, line 22 def sanitize_sql_for_conditions(condition, table_name = self.table_name) return nil if condition.blank? case condition when Array; sanitize_sql_array(condition) when Hash; sanitize_sql_hash_for_conditions(condition, table_name) else condition end end
Sanitizes a hash of attribute/value pairs into SQL conditions for a SET clause.
{ status: nil, group_id: 1 } # => "status = NULL , group_id = 1"
# File lib/active_record/sanitization.rb, line 106 def sanitize_sql_hash_for_assignment(attrs, table) c = connection attrs.map do |attr, value| "#{c.quote_table_name_for_assignment(table, attr)} = #{quote_bound_value(value, c, columns_hash[attr.to_s])}" end.join(', ') end
Sanitizes a hash of attribute/value pairs into SQL conditions for a WHERE clause.
{ name: "foo'bar", group_id: 4 } # => "name='foo''bar' and group_id= 4" { status: nil, group_id: [1,2,3] } # => "status IS NULL and group_id IN (1,2,3)" { age: 13..18 } # => "age BETWEEN 13 AND 18" { 'other_records.id' => 7 } # => "`other_records`.`id` = 7" { other_records: { id: 7 } } # => "`other_records`.`id` = 7"
And for value objects on a composed_of relationship:
{ address: Address.new("123 abc st.", "chicago") } # => "address_street='123 abc st.' and address_city='chicago'"
# File lib/active_record/sanitization.rb, line 89 def sanitize_sql_hash_for_conditions(attrs, default_table_name = self.table_name) ActiveSupport::Deprecation.warn("sanitize_sql_hash_for_conditions is deprecated, and will be removed in Rails 5.0 ") attrs = PredicateBuilder.resolve_column_aliases self, attrs attrs = expand_hash_conditions_for_aggregates(attrs) table = Arel::Table.new(table_name, arel_engine).alias(default_table_name) PredicateBuilder.build_from_hash(self, attrs, table).map { |b| connection.visitor.compile b }.join(' AND ') end
Sanitizes a string
so that it is safe to use within an SQL
LIKE statement. This method uses escape_character
to escape
all occurrences of “", ”_“ and ”%“
# File lib/active_record/sanitization.rb, line 115 def sanitize_sql_like(string, escape_character = "\\") pattern = Regexp.union(escape_character, "%", "_") string.gsub(pattern) { |x| [escape_character, x].join } end


Pirate (ARRR) is a cryptocurrency that solves the issue of financial privacy on the blockchain through forced anonymous transactions. Protect your wallet and transactions with Pirate’s completely anonymous network. With forced private transactions, your privacy cannot be compromised by another users’ activity on the network. If you wish to learn more, please join the official Pirate Discord at https://pirate.black/discord/ or message FishyGuts#5085, who will be happy to help out.
100 messages
Before 05-Dec-19 12:00 AM
ComputerGenie 👴👴👴28-Sep-18 03:36 PM
almost by double
house28-Sep-18 03:36 PM
Me 5 x 1080 Ti got scuttled as of 12 hrs ago grrr arrr
ComputerGenie 👴👴👴28-Sep-18 03:37 PM
I've got a Ti that has a bad riser and I'm too lazy to figure out which one it is
it's only running at like 10%(edited)
Llama28-Sep-18 03:37 PM
lol its double kmd?
ComputerGenie 👴👴👴28-Sep-18 03:38 PM
yes @Llama
Hot28-Sep-18 03:38 PM
soon pirate will be > 1 KMD arrrrrr
1
house28-Sep-18 03:38 PM
NH @ComputerGenie 👴👴👴 ?
ComputerGenie 👴👴👴28-Sep-18 03:38 PM
house28-Sep-18 03:39 PM
You sellin a boatload ther
Llama28-Sep-18 03:39 PM
trading my 15 KMD for 777 pirate was a tough one. I'm not one to let my KMD go
1
ComputerGenie 👴👴👴28-Sep-18 03:39 PM
no, I buy there
selling on nh would only make ~ 80% of what I make soloing(edited)
house28-Sep-18 03:40 PM
I means yer sellin a shite load ay pirate
Llama28-Sep-18 03:40 PM
and it's actually selling lol
ComputerGenie 👴👴👴28-Sep-18 03:41 PM
paying for services is the opposite of selling
house28-Sep-18 03:41 PM
That’s what we want llama
Llama28-Sep-18 03:41 PM
yeah for sure
but I'm not selling any of mine
house28-Sep-18 03:42 PM
cringes having to trade his kmd
ComputerGenie 👴👴👴28-Sep-18 03:43 PM
sold so much KMD at <$1.25 to buy miners that he refuses to keep count so as to not when the price comes back
house28-Sep-18 03:44 PM
Can’t lie ... that makes me ... happier
*wondered where all that pirate came from
ComputerGenie 👴👴👴28-Sep-18 03:45 PM
has "a few" Z9 minis
house28-Sep-18 03:45 PM
Dagnabit !
Won’t disclose he bought couple of lead weights in the form sc1’s
ComputerGenie 👴👴👴28-Sep-18 03:48 PM
The secret is to buy as many as you can as fast as you can
house28-Sep-18 03:48 PM
Arrr but got me teeth into some them 7nm gpominers ... arrive in couple weeks me hearty
Jolly Roger that ol’ salty
ComputerGenie 👴👴👴28-Sep-18 03:49 PM
is so over mining BTC
Flexatron28-Sep-18 03:50 PM
woke up at 20M diff
ComputerGenie 👴👴👴28-Sep-18 03:51 PM
Short of beta testing ck's public pool, I haven't mined BTC since 2016
there's just no profit in it on any scale less than $500k entry
house28-Sep-18 03:52 PM
Will be fun over the next few months to be sure
ronyi28-Sep-18 03:52 PM
Hi! I'm new in this Discord channel, but old KMD fan. I'm running PIRATE node from 36xxx blocks. Unfortunately, I have the impression that node and gpu miners are not sufficiently appreciated, but stick to the community. Ty(edited)
ComputerGenie 👴👴👴28-Sep-18 03:54 PM
@ronyi It's not that GPUs aren't appreciated, but rather that they are not very profitable in the wake of ASICs(edited)
still runs a ton of GPUs
scubapanda28-Sep-18 03:55 PM
ARRR Pirates! What is a good Pirate z-address (offline) paper wallet generator?(edited)
house28-Sep-18 03:55 PM
Low power cost genie ?
We’re u at
ComputerGenie 👴👴👴28-Sep-18 03:56 PM
not really low (10 cents), but I can't just throw away $50k worth of equipment because it only makes 10% of what it used to
ronyi28-Sep-18 03:56 PM
Sorry... yes i still running 200GPUs in pirate....
house28-Sep-18 03:57 PM
Rojer dodger
Spent $85k hd mining ... good stuff on horizon
Flexatron28-Sep-18 03:58 PM
has zero equipment
house28-Sep-18 03:59 PM
has zero coding skill
Flexatron28-Sep-18 03:59 PM
Yo can't we fork to 50/50 pos/pow?
Verus style
ComputerGenie 👴👴👴28-Sep-18 04:00 PM
Flexatron_official8809 has zero equipment
be glad, this shit is a full-time job and then a full-time job on top of that
Flexatron28-Sep-18 04:00 PM
Ahh shielded staking is hard
@ComputerGenie 👴👴👴 damn, thought you'd get sleeping rich :D
wookie28-Sep-18 04:00 PM
@webworker01 Thank you for helping me sort out my issue of getting the pirates in my wallet! The pool was correct, payments were correct!
1
Somehow my wallet wasn't updating the payments correctly??
mato12128-Sep-18 04:01 PM
andybody willing to trade 20 kmd for 700 pirate
Llama28-Sep-18 04:01 PM
was i supposed to enter a transparent address for my mining software?
ComputerGenie 👴👴👴28-Sep-18 04:01 PM
Yo can't we fork to 50/50 pos/pow?
You write the code to do a z addy staking and I'm sure james will be glad to add it
Llama28-Sep-18 04:01 PM
@mato121 the rate right now is about 12 pirate / 1 KMD
Flexatron28-Sep-18 04:02 PM
stays quiet
ComputerGenie 👴👴👴28-Sep-18 04:02 PM
@mato121 I'll gladly buy that 700 PIRATE for 20 KMD
house28-Sep-18 04:04 PM
Gonna need lemon for that scurvy genie
1
Flexatron28-Sep-18 04:04 PM
thinks of clever psychological numbers to obtain cheap pirate
ComputerGenie 👴👴👴28-Sep-18 04:05 PM
thinks of clever psychological numbers to inflate the price of pirate
house28-Sep-18 04:06 PM
thinks has been mastered already
Flexatron28-Sep-18 04:06 PM
Anyone wants to sell 1773 pirate for 49.99 kmd?
2
2
ComputerGenie 👴👴👴28-Sep-18 04:06 PM
shhhhhhh
Earl Scheib deals going on now
house28-Sep-18 04:08 PM
Aight you swashbuckling scallywags ... till the morrow arrr!
Llama28-Sep-18 04:08 PM
@ComputerGenie 👴👴👴 he wants to buy 700 pirate for that rate
ComputerGenie 👴👴👴28-Sep-18 04:08 PM
gl to him with that
0.0286 is a loss for anyone except super early miners
Llama28-Sep-18 04:14 PM
yeah
ComputerGenie 👴👴👴28-Sep-18 04:15 PM
need to "go to town" to buy a mower, bbl
4
Flexatron28-Sep-18 04:17 PM
has a smirk on his face looking at the hashrate
ComputerGenie 👴👴👴28-Sep-18 04:18 PM
block Diff:<PHONE_NUMBER>95224
still more than 2x that of KMD
Flexatron28-Sep-18 04:59 PM
28Msol again
Berg28-Sep-18 05:02 PM
Is there a reason this doesn't have it's own Discord in it's entirety?
1
Flexatron28-Sep-18 05:03 PM
We should maybe?
polycryptoblog28-Sep-18 05:03 PM
It will
Flexatron28-Sep-18 05:03 PM
With a sub komodo channel
1
Mylo28-Sep-18 05:16 PM
i'd like to see someone do that homomorphic encryption james says is required for z stuff to do crypto conditions. that is the golden pony ride!
with sapling
first discovery of this maths (released to public) was in 2009 @ IBM. some dude called 'Craig Gentry'
Hot28-Sep-18 05:23 PM
i want a golden pony
Cryptoon28-Sep-18 05:24 PM
WTB pirate, anyone still selling?
Mylo28-Sep-18 05:25 PM
mine it
Cryptoon28-Sep-18 05:26 PM
with current difficulty and with no gpu/Z9 not really a chance
Mylo28-Sep-18 05:26 PM
i've got 4 PIRATE with random mining testing.
rent it from miningrigrentals.com
Llama28-Sep-18 05:26 PM
I might sell enough to pay for the 15 KMD that i put in
Mylo28-Sep-18 05:26 PM
i'm on a laptop
Cryptoon28-Sep-18 05:27 PM
same, but need laptop for work so dont really want to have the fan blowing the entire time :p
Mylo28-Sep-18 05:28 PM
maybe install a virtual machine on your work laptop, then visit miningrigrentals.com and you can rent other people's hardware to point to the mining pool.
that's what that screenshot above is.
Llama28-Sep-18 05:28 PM
i mined for 8.5 hours and only got 3 pirate
maybe something went wrong(edited)
Mylo28-Sep-18 05:30 PM
depends what you've got. i tested (by renting from MRR) someone's 1060 and someone elses 1080 and had 1kSol for about 3 hours and 120sol/s for another 10 hours. think it mined 2 PIRATE
scubapanda28-Sep-18 05:30 PM
Divide your hashrate/sols with 25 million x daily rewards of ~360,000.
Llama28-Sep-18 05:31 PM
accurate
1
DR3WSKi28-Sep-18 05:33 PM
I got 170 my first day mining w gpus, about 5.5ksols


Sharing some of my adventures and pictures. Cheers!
Photo by Lori Lopez, Venice 2014
Ken Kaminesky's site is very well put together and visually stunning. A lot of graphics and work went into Ken's site. Very precise sections and coding for those sections. Looks very professional. Each Div section is very well done. I can follow the workflow very easy because of it.


Welcome to Code Friends!
Here you can sing up make posts and see other as well!
log in
View all other users.


--- layout: post title: "April 4, 2019 Meeting" subtitle: "This is the Final(s) countdown" date: 2019-04-04 23:45:13 -0400 background: '/img/posts/03.jpg' categories: Meeting Logs ---
Attendees: JoCee, Zane, and Donovan, Mohit
Everyone has completed their part of the final mostly finished, now it is just bug check fixes and putting all the pieces together.


We’ve all heard that if it sounds too good to be true… it probably is. Fortunately, this isn't one of them
Refund Advocates LLC audits government agencies nationwide to locate money owed to private individuals, Families and companies. The government makes no attempt (nor are they obligated) to notify citizens that they are owed money from any kind of abandonment, other than publishing the list in a newspaper or sending a letter to whatever old address the Agency has on file.
The types of funds these falls under are NOT on government lists that they publish; they are hidden deep in government records and 99% of all citizens do not even know that they exist.
If these funds go unclaimed for too long, they are usually lost to the government agency that is holding them.
See moreOnce we’ve located the funds, great efforts are expended to then locate the rightful owner(s). Our team goes to work with our attorneys, researchers and notaries to work with the agency holding your unclaimed money.
Remember, if these funds go unclaimed for too long, they are usually lost to the government agency holding them.
Once you have spoken to one of our Refund Specialists and verbally agreed to let us work your claim, we will set up a time for you to sign several pages of paperwork to allow us to get started.
Our firm works on a contingent basis – this means that there are no up-front or out- of-pocket expenses to you, EVER. We’re paid ONLY upon successful collection of your claim.  We take all the risk in exchange for an agreed upon percentage of the collected funds – a fair trade!
We will send a local notary public with your paperwork package, once notarized we start processing claims immediately and follow through until the end, making sure to keep you updated all along the way.


---
layout: default
permalink: /categories/angularjs
---
{% include components/categories.html %}
{%
include components/category-title.html
category="AngularJS"
icon="angularjs"
text="All articles on AngularJS (1.x), beginner and advanced posts"
%}
{% for post in site.posts %}
{% if post.tag == 'angularjs' %}
{% include components/post-card.html %}
{% endif %}
{% endfor %}
{% include components/notify.html %}


---
layout: post
section-type: post
title: JAOO Day 3 - summary
date: '2007-09-26T21:12:00.000+02:00'
author: Jørn Ølmheim
category: tech
tags: [ 'jaoo', 'tdd', 'software craftsmanship' ]
modified_time: '2007-09-27T18:16:42.659+02:00'
blogger_id: tag:blogger.com,1999:blog-16320608.post-5806969935136079119
blogger_orig_url: http://joelmheim.blogspot.com/2007/09/jaoo-day-3-summary.html
---
Today was the last day of the conference part of JAOO. It's not over, though, as there will be tutorials tomorrow and
Friday.
I spent most of the day in the track called Professional Developer. This track was hosted by Bob Martin, and featured a
lot of interesting talks. First up was Kevlin Henney, who did a talk called With Economy and Elegance. I always find
Kevlin to be an interesting speaker, and this was no different. The only "problem" with Kevlin is that he is so smart and
such a fast thinker, that it is really hard to keep up with his ideas. I hadn't seen Kevlin until today, and was
wondering where he had got to this year, and I was pleasantly surprised when he came up to me before the talk and said
hello and chatted for a while. He told med that he had been travelling a lot lately, amongst other places, to
Trondheim!!!, and therefore couldn't justify spending the whole week in Aarhus.
Following Kevlin was a talk by Laurent Bossavit that describe the old craftsman societies of France and Europe and how
they were structured and how they handled passing on the craft. There is a resurgence of such societies that also
include software professionals, and the ideas of craftsmen and their apprentices and journeymen are an interesting way
of dealing with training in the software profession.
The third talk of the day, was a chance for me to see and hear Michael Feather speak for the first time. Michael has
written many influential articles and books, from the humble dialog, through rules for unit tests to the book
"Working Effectively with legacy code".
He did a really interesting talk on error prevention, listing several techniques for preventing bugs in code including
inspection, design-by-contract, formal notation for specification and test driven development. His point was that we are
not using these techniques to the extent we should, and that they all have value and we should use at least one of them.
As you may know, I'm a real fan of Test-Driven Development, and prefer that, but I see that something like
design-by-contract can have its benefits as well.
The final talk was by Pete McBreen on Software Craftsmanship. Pete has written a
book by the same
name that I really enjoyed, and I think that looking at software development as a craft has real benefits.
I took the last session off, and just wandered around for a bit, trying to let my impressions sink in a bit. During this
time I finally also caught up with Dave Thomas (Smalltalk Dave or Big Dave, not Prag Dave), who I also hadn't seen
earlier at this conference. I thought that was strange because he is on the program committee, and he told me that he
too came in only last night, having spent the last couple of weeks on safari in Africa. Then I ran into Charlie Nutter
and Thomas Enebo (the JRuby guys), and ended up hanging out with them looking at the JRuby code. I'll talk more about
that in another post, but the thing that really surprised me was that I was able to download their trunk from
subversion, load it up into Netbeans, and successfully run the JUnit tests without failures. That shows great dedication
on their part.
We all went together to listen to the final panel, where Erik Meijer, Eric Evans, Erik Dörenburg (Thoughtworks) and
Diana Larsen (Agile coach) debated about key things they had learned at the conference. The panel was led by Martin
Fowler. Interestingly one of their main points was Glenn Vanderburg's talk on The overlooked power of JavaScript, and
this really got an interesting discussion going in the audience.
Charlie and Thomas were going to the speakers dinner, and the bus was leaving from my hotel, so we went back there and
had a quick beer together before they had to leave. Those two are really interesting individuals, and clearly were
committed to making a Java implementation for Ruby so that the rest of us can enjoy Ruby on the JVM. I'm going to look
into ways to help them with this. This is something I would like to contribute to if I'm able. We'll see.
So the final day is over. Now only the tutorial tomorrow remains. That promises to be interesting, and I'll let you know
how that went tomorrow afternoon.


Timer
Countdown
0:00
Choose how many minutes with the slider and click start.
Start
Minute Timer
How many Minutes? (1 to 120)


--- title: Jekyll Serif - Jekyll Small Business Theme layout: default bodyClass: page-home ---
There's so much information
1). Staying on top is hard
2). Organizing is stressful
3). Self-doubt & information anxiety are common
Are you ready for the next job interview or knowledge test?
We're here to guide
We know the pain, so we built a knowledge management system based on learning science to make this a lot easier.
MasteryPath enables you to store knowledge, stay current on it, and deliver it to an audience.
How it works
1). Break down subjects into small pieces
2). Sequence them in the correct order
3). Add flashcards to test for retention
Here's the plan
1). Start putting all your knowledge into MasteryPath
2). Train on your information with flashcards and spaced-repitition to build permanent memory
3). Show off your hard work and sell the training experience to paying customers.


The Watson Developer Cloud offers a number of Cognitive Services as RESTful APIs. They are among the most popular services on Bluemix. Welcome to the Cognitive Era
Back To Start


Get Curency Exchanger Information
Enter a number:
Enter a country:
United states of America
Australia
Bulgaria
Canada
Chile
United Kingdom
Brazil
Curency-Exchanger


<java-data xmlns="http://www.netbeans.org/ns/freeform-project-java/2">
This section describes any Java-language-specific aspects of the project.
http://www.netbeans.org/ns/freeform-project-java/1
can be used as well, for
compatibility with older IDE versions, but lacks some features; refer to the
schemas for details.
<compilation-unit>
can be listed one or more times
in the <java-data>
section.
A compilation unit is a collection of Java source roots which
are compiled at once and share the same classpath and other attributes.
<compilation-unit> <package-root>${src.dir}</package-root> <classpath mode="compile">${lib.dir}/x.jar:${lib.dir}/y.jar</classpath> <built-to>${classes.dir}</built-to> <built-to>${jar.file}</built-to> <javadoc-built-to>${javadoc.dir}</javadoc-built-to> <source-level>1.5</source-level> </compilation-unit>
Declares that the directory named by ${src.dir}
contains Java sources. They are
expected to be compiled using the named classpath (as usual, /
and \
can be
used interchangeably, as can :
and ;
), so the IDE can offer code completion
and other features accordingly.
The classes will be compiled to the directory
${classes.dir}
and later packed into ${jar.file}
, so any other project using
either of these locations in its classpath will show sources from ${src.dir}
in
code completion, Go to Source, etc.
Javadoc may be built to the directory
${javadoc.dir}
, so if other projects use this source root, and ${javadoc.dir}
exists, it may be used in Javadoc search.
The sources are to be compiled with
-source 1.5
, i.e. they may contain generics and other JDK 5 language features.
It is important to specify an accurate <built-to>
(available in the Properties dialog
in the Output tab) even if no other code compiles against the output. This is because
the IDE’s background Java parser can run much faster on large source trees when most of the classes have
been compiled already and it knows where they are.


| | |
- AeDelete = ae_delete(token_key)
- AeLoad = ae_load(token_key)
- AeSave = ae_save(token, token_key)
- AuthSubStringFromUrl = auth_sub_string_from_url(url, scopes_param_prefix='auth_sub_scopes')
- Finds the token string (and scopes) after the browser is redirected.
After the Google Accounts AuthSub pages redirect the user's broswer back to
the web application (using the 'next' URL from the request) the web app must
extract the token from the current page's URL. The token is provided as a
URL parameter named 'token' and if generate_auth_sub_url was used to create
the request, the token's valid scopes are included in a URL parameter whose
name is specified in scopes_param_prefix.
Args:
url: atom.url.Url or str representing the current URL. The token value
and valid scopes should be included as URL parameters.
scopes_param_prefix: str (optional) The URL parameter key which maps to
the list of valid scopes for the token.
Returns:
A tuple containing the token value as a string, and a tuple of scopes
(as atom.http_core.Uri objects) which are URL prefixes under which this
token grants permission to read and write user data.
(token_string, (scope_uri, scope_uri, scope_uri, ...))
If no scopes were included in the URL, the second value in the tuple is
None. If there was no token param in the url, the tuple returned is
(None, None)
- AuthorizeRequestToken = authorize_request_token(request_token, url)
- Adds information to request token to allow it to become an access token.
Modifies the request_token object passed in by setting and unsetting the
necessary fields to allow this token to form a valid upgrade request.
Args:
request_token: The OAuth request token which has been authorized by the
user. In order for this token to be upgraded to an access token,
certain fields must be extracted from the URL and added to the token
so that they can be passed in an upgrade-token request.
url: The URL of the current page which the user's browser was redirected
to after they authorized access for the app. This function extracts
information from the URL which is needed to upgraded the token from
a request token to an access token.
Returns:
The same token object which was passed in.
- GenerateClientLoginRequestBody = generate_client_login_request_body(email, password, service, source, account_type='HOSTED_OR_GOOGLE', captcha_token=None, captcha_response=None)
- Creates the body of the autentication request
See http://code.google.com/apis/accounts/AuthForInstalledApps.html#Request
for more details.
Args:
email: str
password: str
service: str
source: str
account_type: str (optional) Defaul is 'HOSTED_OR_GOOGLE', other valid
values are 'GOOGLE' and 'HOSTED'
captcha_token: str (optional)
captcha_response: str (optional)
Returns:
The HTTP body to send in a request for a client login token.
- GetCaptchaChallenge = get_captcha_challenge(http_body, captcha_base_url='http://www.google.com/accounts/')
- Returns the URL and token for a CAPTCHA challenge issued by the server.
Args:
http_body: str The body of the HTTP response from the server which
contains the CAPTCHA challenge.
captcha_base_url: str This function returns a full URL for viewing the
challenge image which is built from the server's response. This
base_url is used as the beginning of the URL because the server
only provides the end of the URL. For example the server provides
'Captcha?ctoken=Hi...N' and the URL for the image is
'http://www.google.com/accounts/Captcha?ctoken=Hi...N'
Returns:
A dictionary containing the information needed to repond to the CAPTCHA
challenge, the image URL and the ID token of the challenge. The
dictionary is in the form:
{'token': string identifying the CAPTCHA image,
'url': string containing the URL of the image}
Returns None if there was no CAPTCHA challenge in the response.
- GetClientLoginTokenString = get_client_login_token_string(http_body)
- Returns the token value for a ClientLoginToken.
Reads the token from the server's response to a Client Login request and
creates the token value string to use in requests.
Args:
http_body: str The body of the server's HTTP response to a Client Login
request
Returns:
The token value string for a ClientLoginToken.
- TokenFromBlob = token_from_blob(blob)
- Deserializes a token string from the datastore back into a token object.
Supported token classes: ClientLoginToken, AuthSubToken, SecureAuthSubToken,
OAuthRsaToken, and OAuthHmacToken.
Args:
blob: string created by token_to_blob.
Raises:
UnsupportedTokenType if the token is not one of the supported token
classes listed above.
Returns:
A new token object with members set to the values serialized in the
blob string. Note that any members which were set to '' in the original
token will now be None.
- TokenToBlob = token_to_blob(token)
- Serializes the token data as a string for storage in a datastore.
Supported token classes: ClientLoginToken, AuthSubToken, SecureAuthSubToken,
OAuthRsaToken, and OAuthHmacToken.
Args:
token: A token object which must be of one of the supported token classes.
Raises:
UnsupportedTokenType if the token is not one of the supported token
classes listed above.
Returns:
A string represenging this token. The string can be converted back into
an equivalent token object using token_from_blob. Note that any members
which are set to '' will be set to None when the token is deserialized
by token_from_blob.
- UpgradeToAccessToken = upgrade_to_access_token(request_token, server_response_body)
- Extracts access token information from response to an upgrade request.
Once the server has responded with the new token info for the OAuth
access token, this method modifies the request_token to set and unset
necessary fields to create valid OAuth authorization headers for requests.
Args:
request_token: An OAuth token which this function modifies to allow it
to be used as an access token.
server_response_body: str The server's response to an OAuthAuthorizeToken
request. This should contain the new token and token_secret which
are used to generate the signature and parameters of the Authorization
header in subsequent requests to Google Data APIs.
Returns:
The same token object which was passed in.
- ae_delete(token_key)
- ae_load(token_key)
- ae_save(token, token_key)
- auth_sub_string_from_body(http_body)
- Extracts the AuthSub token from an HTTP body string.
Used to find the new session token after making a request to upgrade a
single use AuthSub token.
Args:
http_body: str The repsonse from the server which contains the AuthSub
key. For example, this function would find the new session token
from the server's response to an upgrade token request.
Returns:
The raw token value string to use in an AuthSubToken object.
- auth_sub_string_from_url(url, scopes_param_prefix='auth_sub_scopes')
- Finds the token string (and scopes) after the browser is redirected.
After the Google Accounts AuthSub pages redirect the user's broswer back to
the web application (using the 'next' URL from the request) the web app must
extract the token from the current page's URL. The token is provided as a
URL parameter named 'token' and if generate_auth_sub_url was used to create
the request, the token's valid scopes are included in a URL parameter whose
name is specified in scopes_param_prefix.
Args:
url: atom.url.Url or str representing the current URL. The token value
and valid scopes should be included as URL parameters.
scopes_param_prefix: str (optional) The URL parameter key which maps to
the list of valid scopes for the token.
Returns:
A tuple containing the token value as a string, and a tuple of scopes
(as atom.http_core.Uri objects) which are URL prefixes under which this
token grants permission to read and write user data.
(token_string, (scope_uri, scope_uri, scope_uri, ...))
If no scopes were included in the URL, the second value in the tuple is
None. If there was no token param in the url, the tuple returned is
(None, None)
- authorize_request_token(request_token, url)
- Adds information to request token to allow it to become an access token.
Modifies the request_token object passed in by setting and unsetting the
necessary fields to allow this token to form a valid upgrade request.
Args:
request_token: The OAuth request token which has been authorized by the
user. In order for this token to be upgraded to an access token,
certain fields must be extracted from the URL and added to the token
so that they can be passed in an upgrade-token request.
url: The URL of the current page which the user's browser was redirected
to after they authorized access for the app. This function extracts
information from the URL which is needed to upgraded the token from
a request token to an access token.
Returns:
The same token object which was passed in.
- build_auth_sub_data(http_request, timestamp, nonce)
- Creates the data string which must be RSA-signed in secure requests.
For more details see the documenation on secure AuthSub requests:
http://code.google.com/apis/accounts/docs/AuthSub.html#signingrequests
Args:
http_request: The request being made to the server. The Request's URL
must be complete before this signature is calculated as any changes
to the URL will invalidate the signature.
nonce: str Random 64-bit, unsigned number encoded as an ASCII string in
decimal format. The nonce/timestamp pair should always be unique to
prevent replay attacks.
timestamp: Integer representing the time the request is sent. The
timestamp should be expressed in number of seconds after January 1,
1970 00:00:00 GMT.
- build_oauth_base_string(http_request, consumer_key, nonce, signaure_type, timestamp, version, next='oob', token=None, verifier=None)
- Generates the base string to be signed in the OAuth request.
Args:
http_request: The request being made to the server. The Request's URL
must be complete before this signature is calculated as any changes
to the URL will invalidate the signature.
consumer_key: Domain identifying the third-party web application. This is
the domain used when registering the application with Google. It
identifies who is making the request on behalf of the user.
nonce: Random 64-bit, unsigned number encoded as an ASCII string in decimal
format. The nonce/timestamp pair should always be unique to prevent
replay attacks.
signaure_type: either RSA_SHA1 or HMAC_SHA1
timestamp: Integer representing the time the request is sent. The
timestamp should be expressed in number of seconds after January 1,
1970 00:00:00 GMT.
version: The OAuth version used by the requesting web application. This
value must be '1.0' or '1.0a'. If not provided, Google assumes version
1.0 is in use.
next: The URL the user should be redirected to after granting access
to a Google service(s). It can include url-encoded query parameters.
The default value is 'oob'. (This is the oauth_callback.)
token: The string for the OAuth request token or OAuth access token.
verifier: str Sent as the oauth_verifier and required when upgrading a
request token to an access token.
- dump_tokens(tokens)
- generate_auth_header(consumer_key, timestamp, nonce, signature_type, signature, version='1.0', next=None, token=None, verifier=None)
- Builds the Authorization header to be sent in the request.
Args:
consumer_key: Identifies the application making the request (str).
timestamp:
nonce:
signature_type: One of either HMAC_SHA1 or RSA_SHA1
signature: The HMAC or RSA signature for the request as a base64
encoded string.
version: The version of the OAuth protocol that this request is using.
Default is '1.0'
next: The URL of the page that the user's browser should be sent to
after they authorize the token. (Optional)
token: str The OAuth token value to be used in the oauth_token parameter
of the header.
verifier: str The OAuth verifier which must be included when you are
upgrading a request token to an access token.
- generate_auth_sub_url(next, scopes, secure=False, session=True, request_url=<atom.http_core.Uri object at 0xb55c90>, domain='default', scopes_param_prefix='auth_sub_scopes')
- Constructs a URI for requesting a multiscope AuthSub token.
The generated token will contain a URL parameter to pass along the
requested scopes to the next URL. When the Google Accounts page
redirects the broswser to the 'next' URL, it appends the single use
AuthSub token value to the URL as a URL parameter with the key 'token'.
However, the information about which scopes were requested is not
included by Google Accounts. This method adds the scopes to the next
URL before making the request so that the redirect will be sent to
a page, and both the token value and the list of scopes for which the token
was requested.
Args:
next: atom.http_core.Uri or string The URL user will be sent to after
authorizing this web application to access their data.
scopes: list containint strings or atom.http_core.Uri objects. The URLs
of the services to be accessed.
secure: boolean (optional) Determines whether or not the issued token
is a secure token.
session: boolean (optional) Determines whether or not the issued token
can be upgraded to a session token.
request_url: atom.http_core.Uri or str The beginning of the request URL.
This is normally
'http://www.google.com/accounts/AuthSubRequest' or
'/accounts/AuthSubRequest'
domain: The domain which the account is part of. This is used for Google
Apps accounts, the default value is 'default' which means that
the requested account is a Google Account (@gmail.com for
example)
scopes_param_prefix: str (optional) The requested scopes are added as a
URL parameter to the next URL so that the page at
the 'next' URL can extract the token value and the
valid scopes from the URL. The key for the URL
parameter defaults to 'auth_sub_scopes'
Returns:
An atom.http_core.Uri which the user's browser should be directed to in
order to authorize this application to access their information.
- generate_client_login_request_body(email, password, service, source, account_type='HOSTED_OR_GOOGLE', captcha_token=None, captcha_response=None)
- Creates the body of the autentication request
See http://code.google.com/apis/accounts/AuthForInstalledApps.html#Request
for more details.
Args:
email: str
password: str
service: str
source: str
account_type: str (optional) Defaul is 'HOSTED_OR_GOOGLE', other valid
values are 'GOOGLE' and 'HOSTED'
captcha_token: str (optional)
captcha_response: str (optional)
Returns:
The HTTP body to send in a request for a client login token.
- generate_hmac_signature(http_request, consumer_key, consumer_secret, timestamp, nonce, version, next='oob', token=None, token_secret=None, verifier=None)
- generate_oauth_authorization_url(token, next=None, hd='default', hl=None, btmpl=None, auth_server='https://www.google.com/accounts/OAuthAuthorizeToken')
- Creates a URL for the page where the request token can be authorized.
Args:
token: str The request token from the OAuth server.
next: str (optional) URL the user should be redirected to after granting
access to a Google service(s). It can include url-encoded query
parameters.
hd: str (optional) Identifies a particular hosted domain account to be
accessed (for example, 'mycollege.edu'). Uses 'default' to specify a
regular Google account ('username@gmail.com').
hl: str (optional) An ISO 639 country code identifying what language the
approval page should be translated in (for example, 'hl=en' for
English). The default is the user's selected language.
btmpl: str (optional) Forces a mobile version of the approval page. The
only accepted value is 'mobile'.
auth_server: str (optional) The start of the token authorization web
page. Defaults to
'https://www.google.com/accounts/OAuthAuthorizeToken'
Returns:
An atom.http_core.Uri pointing to the token authorization page where the
user may allow or deny this app to access their Google data.
- generate_request_for_access_token(request_token, auth_server_url='https://www.google.com/accounts/OAuthGetAccessToken')
- Creates a request to ask the OAuth server for an access token.
Requires a request token which the user has authorized. See the
documentation on OAuth with Google Data for more details:
http://code.google.com/apis/accounts/docs/OAuth.html#AccessToken
Args:
request_token: An OAuthHmacToken or OAuthRsaToken which the user has
approved using their browser.
auth_server_url: (optional) The URL at which the OAuth access token is
requested. Defaults to
https://www.google.com/accounts/OAuthGetAccessToken
Returns:
A new HttpRequest object which can be sent to the OAuth server to
request an OAuth Access Token.
- generate_request_for_request_token(consumer_key, signature_type, scopes, rsa_key=None, consumer_secret=None, auth_server_url='https://www.google.com/accounts/OAuthGetRequestToken', next='oob', version='1.0')
- Creates request to be sent to auth server to get an OAuth request token.
Args:
consumer_key:
signature_type: either RSA_SHA1 or HMAC_SHA1. The rsa_key must be
provided if the signature type is RSA but if the signature method
is HMAC, the consumer_secret must be used.
scopes: List of URL prefixes for the data which we want to access. For
example, to request access to the user's Blogger and Google Calendar
data, we would request
['http://www.blogger.com/feeds/',
'https://www.google.com/calendar/feeds/',
'http://www.google.com/calendar/feeds/']
rsa_key: Only used if the signature method is RSA_SHA1.
consumer_secret: Only used if the signature method is HMAC_SHA1.
auth_server_url: The URL to which the token request should be directed.
Defaults to 'https://www.google.com/accounts/OAuthGetRequestToken'.
next: The URL of the page that the user's browser should be sent to
after they authorize the token. (Optional)
version: The OAuth version used by the requesting web application.
Defaults to '1.0a'
Returns:
An atom.http_core.HttpRequest object with the URL, Authorization header
and body filled in.
- generate_rsa_signature(http_request, consumer_key, rsa_key, timestamp, nonce, version, next='oob', token=None, token_secret=None, verifier=None)
- generate_signature(data, rsa_key)
- Signs the data string for a secure AuthSub request.
- get_captcha_challenge(http_body, captcha_base_url='http://www.google.com/accounts/')
- Returns the URL and token for a CAPTCHA challenge issued by the server.
Args:
http_body: str The body of the HTTP response from the server which
contains the CAPTCHA challenge.
captcha_base_url: str This function returns a full URL for viewing the
challenge image which is built from the server's response. This
base_url is used as the beginning of the URL because the server
only provides the end of the URL. For example the server provides
'Captcha?ctoken=Hi...N' and the URL for the image is
'http://www.google.com/accounts/Captcha?ctoken=Hi...N'
Returns:
A dictionary containing the information needed to repond to the CAPTCHA
challenge, the image URL and the ID token of the challenge. The
dictionary is in the form:
{'token': string identifying the CAPTCHA image,
'url': string containing the URL of the image}
Returns None if there was no CAPTCHA challenge in the response.
- get_client_login_token_string(http_body)
- Returns the token value for a ClientLoginToken.
Reads the token from the server's response to a Client Login request and
creates the token value string to use in requests.
Args:
http_body: str The body of the server's HTTP response to a Client Login
request
Returns:
The token value string for a ClientLoginToken.
- hmac_token_from_body(http_body, consumer_key, consumer_secret, auth_state)
- load_tokens(blob)
- oauth_token_info_from_body(http_body)
- Exracts an OAuth request token from the server's response.
Returns:
A tuple of strings containing the OAuth token and token secret. If
neither of these are present in the body, returns (None, None)
- oauth_token_info_from_url(url)
- Exracts an OAuth access token from the redirected page's URL.
Returns:
A tuple of strings containing the OAuth token and the OAuth verifier which
need to sent when upgrading a request token to an access token.
- rsa_token_from_body(http_body, consumer_key, rsa_private_key, auth_state)
- token_from_blob(blob)
- Deserializes a token string from the datastore back into a token object.
Supported token classes: ClientLoginToken, AuthSubToken, SecureAuthSubToken,
OAuthRsaToken, and OAuthHmacToken.
Args:
blob: string created by token_to_blob.
Raises:
UnsupportedTokenType if the token is not one of the supported token
classes listed above.
Returns:
A new token object with members set to the values serialized in the
blob string. Note that any members which were set to '' in the original
token will now be None.
- token_to_blob(token)
- Serializes the token data as a string for storage in a datastore.
Supported token classes: ClientLoginToken, AuthSubToken, SecureAuthSubToken,
OAuthRsaToken, and OAuthHmacToken.
Args:
token: A token object which must be of one of the supported token classes.
Raises:
UnsupportedTokenType if the token is not one of the supported token
classes listed above.
Returns:
A string represenging this token. The string can be converted back into
an equivalent token object using token_from_blob. Note that any members
which are set to '' will be set to None when the token is deserialized
by token_from_blob.
- upgrade_to_access_token(request_token, server_response_body)
- Extracts access token information from response to an upgrade request.
Once the server has responded with the new token info for the OAuth
access token, this method modifies the request_token to set and unset
necessary fields to create valid OAuth authorization headers for requests.
Args:
request_token: An OAuth token which this function modifies to allow it
to be used as an access token.
server_response_body: str The server's response to an OAuthAuthorizeToken
request. This should contain the new token and token_secret which
are used to generate the signature and parameters of the Authorization
header in subsequent requests to Google Data APIs.
Returns:
The same token object which was passed in.
|


Chez Scheme has several features that support debugging. In addition to providing error messages when fully type-checked code is run, Chez Scheme also permits tracing of procedure calls, interruption of any computation, redefinition of exception and interrupt handlers, and inspection of any object, including the continuations of exceptions and interrupts.
Programmers new to Scheme or Chez Scheme, and even more experienced Scheme programmers, might want to consult the tutorial "How to Debug Chez Scheme Programs." HTML and PDF versions are available at http://www.cs.indiana.edu/chezscheme/debug/.
Tracing is one of the most useful mechanisms for debugging Scheme programs. Chez Scheme permits any primitive or user-defined procedure to be traced. The trace package prints the arguments and return values for each traced procedure with a compact indentation mechanism that shows the nesting depth of calls. The distinction between tail calls and nontail calls is reflected properly by an increase in indentation for nontail calls only. For nesting depths of 10 or greater, a number in brackets is used in place of indentation to signify nesting depth.
This section covers the mechanisms for tracing procedures and controlling trace output.
syntax: (trace-lambda name formals body1 body2 ...)
returns: a traced procedure
libraries: (chezscheme)
A trace-lambda expression is equivalent to a lambda expression with the same formals and body except that trace information is printed to the trace output port whenever the procedure is invoked, using name to identify the procedure. The trace information shows the value of the arguments passed to the procedure and the values returned by the procedure, with indentation to show the nesting of calls.
The traced procedure half defined below returns the integer quotient of its argument and 2.
(define half
(trace-lambda half (x)
(cond
[(zero? x) 0]
[(odd? x) (half (- x 1))]
[(even? x) (+ (half (- x 1)) 1)])))
A trace of the call (half 5), which returns 2, is shown below.
|(half 5)
|(half 4)
| (half 3)
| (half 2)
| |(half 1)
| |(half 0)
| |0
| 1
|2
This example highlights the proper treatment of tail and nontail calls by the trace package. Since half tail calls itself when its argument is odd, the call (half 4) appears at the same level of indentation as the call (half 5). Furthermore, since the return values of (half 5) and (half 4) are necessarily the same, only one return value is shown for both calls.
syntax: (trace-case-lambda name clause ...)
returns: a traced procedure
libraries: (chezscheme)
A trace-case-lambda expression is equivalent to a case-lambda expression with the same clauses except that trace information is printed to the trace output port whenever the procedure is invoked, using name to identify the procedure. The trace information shows the value of the arguments passed to the procedure and the values returned by the procedure, with indentation to show the nesting of calls.
syntax: (trace-let name ((var expr) ...) body1 body2 ...)
returns: the values of the body body1 body2 ...
libraries: (chezscheme)
A trace-let expression is equivalent to a named let expression with the same name, bindings, and body except that trace information is printed to the trace output port on entry or reentry (via invocation of the procedure bound to name) into the trace-let expression.
A trace-let expression of the form
(trace-let name ([var expr] ...)
body1 body2 ...)
can be rewritten in terms of trace-lambda as follows:
((letrec ([name
(trace-lambda name (var ...)
body1 body2 ...)])
name)
expr ...)
trace-let may be used to trace ordinary let expressions as well as let expressions as long as the name inserted along with the trace-let keyword in place of let does not appear free within the body of the let expression. It is also sometimes useful to insert a trace-let expression into a program simply to display the value of an arbitrary expression at the current trace indentation. For example, a call to the following variant of half
(define half
(trace-lambda half (x)
(cond
[(zero? x) 0]
[(odd? x) (half (trace-let decr-value () (- x 1)))]
[(even? x) (+ (half (- x 1)) 1)])))
with argument 5 results in the trace:
|(half 5)
| (decr-value)
| 4
|(half 4)
| (half 3)
| |(decr-value)
| |2
| (half 2)
| |(half 1)
| | (decr-value)
| | 0
| |(half 0)
| 1
|2
syntax: (trace-do ((var init update) ...) (test result ...) expr ...)
returns: the values of the last result expression
libraries: (chezscheme)
A trace-do expression is equivalent to a do expression with the same subforms, except that trace information is printed to the trace output port, showing the values of var ... and each iteration and the final value of the loop on termination. For example, the expression
(trace-do ([old '(a b c) (cdr old)]
[new '() (cons (car old) new)])
((null? old) new))
produces the trace
|(do (a b c) ())
|(do (b c) (a))
|(do (c) (b a))
|(do () (c b a))
|(c b a)
and returns (c b a).
syntax: (trace var1 var2 ...)
returns: a list of var1 var2 ...
syntax: (trace)
returns: a list of all currently traced top-level variables
libraries: (chezscheme)
In the first form, trace reassigns the top-level values of var1 var2 ..., whose values must be procedures, to equivalent procedures that display trace information in the manner of trace-lambda.
trace works by encapsulating the old value of each var in a traced procedure. It could be defined approximately as follows. (The actual version records and returns information about traced variables.)
(define-syntax trace
(syntax-rules ()
[(_ var ...)
(begin
(set-top-level-value! 'var
(let ([p (top-level-value 'var)])
(trace-lambda var args (apply p args))))
...)]))
Tracing for a procedure traced in this manner may be disabled via untrace (see below), an assignment of the corresponding variable to a different, untraced value, or a subsequent use of trace for the same variable. Because the value is traced and not the binding, however, a traced value obtained before tracing is disabled and retained after tracing is disabled will remain traced.
trace without subexpressions evaluates to a list of all currently traced variables. A variable is currently traced if it has been traced and not subsequently untraced or assigned to a different value.
The following transcript demonstrates the use of trace in an interactive session.
> (define half
(lambda (x)
(cond
[(zero? x) 0]
[(odd? x) (half (- x 1))]
[(even? x) (+ (half (- x 1)) 1)])))
> (half 5)
2
> (trace half)
(half)
> (half 5)
|(half 5)
|(half 4)
| (half 3)
| (half 2)
| |(half 1)
| |(half 0)
| |0
| 1
|2
2
> (define traced-half half)
> (untrace half)
(half)
> (half 2)
1
> (traced-half 2)
|(half 2)
|1
1
syntax: (untrace var1 var2 ...)
syntax: (untrace)
returns: a list of untraced variables
libraries: (chezscheme)
untrace restores the original (pre-trace) top-level values of each currently traced variable in var1 var2 ..., effectively disabling the tracing of the values of these variables. Any variable in var1 var2 ... that is not currently traced is ignored. If untrace is called without arguments, the values of all currently traced variables are restored.
The following transcript demonstrates the use of trace and untrace in an interactive session to debug an incorrect procedure definition.
> (define square-minus-one
(lambda (x)
(- (* x x) 2)))
> (square-minus-one 3)
7
> (trace square-minus-one * -)
(square-minus-one * -)
> (square-minus-one 3)
|(square-minus-one 3)
| (* 3 3)
| 9
|(- 9 2)
|7
7
> (define square-minus-one
(lambda (x)
(- (* x x) 1))) ; change the 2 to 1
> (trace)
(- *)
> (square-minus-one 3)
|(* 3 3)
|9
|(- 9 1)
|8
8
> (untrace square-minus-one)
()
> (untrace * -)
(- *)
> (square-minus-one 3)
8
The first call to square-minus-one indicates there is an error, the second (traced) call indicates the step at which the error occurs, the third call demonstrates that the fix works, and the fourth call demonstrates that untrace does not wipe out the fix.
thread parameter: trace-output-port
libraries: (chezscheme)
trace-output-port is a parameter that determines the output port to which tracing information is sent. When called with no arguments, trace-output-port returns the current trace output port. When called with one argument, which must be a textual output port, trace-output-port changes the value of the current trace output port.
thread parameter: trace-print
libraries: (chezscheme)
The value of trace-print must be a procedure of two arguments, an object and an output port. The trace package uses the value of trace-print to print the arguments and return values for each call to a traced procedure. trace-print is set to pretty-print by default.
The trace package sets pretty-initial-indent to an appropriate value for the current nesting level before calling the value of trace-print so that multiline output can be indented properly.
syntax: (trace-define var expr)
syntax: (trace-define (var . idspec) body1 body2 ...)
returns: unspecified
libraries: (chezscheme)
trace-define is a convenient shorthand for defining variables bound to traced procedures of the same name. The first form is equivalent to
(define var
(let ([x expr])
(trace-lambda var args
(apply x args))))
and the second is equivalent to
(define var
(trace-lambda var idspec
body1 body2 ...))
In the former case, expr must evaluate to a procedure.
> (let ()
(trace-define plus
(lambda (x y)
(+ x y)))
(list (plus 3 4) (+ 5 6)))
|(plus 3 4)
|7
(7 11)
syntax: (trace-define-syntax keyword expr)
returns: unspecified
libraries: (chezscheme)
trace-define-syntax traces the input and output to the transformer value of expr, stripped of the contextual information used by the expander to maintain lexical scoping.
> (trace-define-syntax let*
(syntax-rules ()
[(_ () b1 b2 ...)
(let () b1 b2 ...)]
[(_ ((x e) m ...) b1 b2 ...)
(let ((x e))
(let* (m ...) b1 b2 ...))]))
> (let* ([x 3] [y (+ x x)]) (list x y))
|(let* (let* [(x 3) (y (+ x x))] [list x y]))
|(let ([x 3]) (let* ([y (+ x x)]) (list x y)))
|(let* (let* [(y (+ x x))] [list x y]))
|(let ([y (+ x x)]) (let* () (list x y)))
|(let* (let* () [list x y]))
|(let () (list x y))
(3 6)
Without contextual information, the displayed forms are more readable but less precise, since different identifiers with the same name are indistinguishable, as shown in the example below.
> (let ([x 0])
(trace-define-syntax a
(syntax-rules ()
[(_ y) (eq? x y)]))
(let ([x 1])
(a x)))
|(a (a x))
|(eq? x x)
#f
The interactive debugger is entered as a result of a call to the procedure debug after an exception is handled by the default exception handler. It can also be entered directly from the default exception handler, for serious or non-warning conditions, if the parameter debug-on-exception is true.
Within the debugger, the command "?" lists the debugger command options. These include commands to:
The raise continuation is the continuation encapsulated within the condition, if any. The standard exception reporting procedures and forms assert, assertion-violation, and error as well as the Chez Scheme procedures assertion-violationf, errorf, and syntax-error all raise exceptions with conditions that encapsulate the continuations of their calls, allowing the programmer to inspect the frames of pending calls at the point of a violation, error, or failed assertion.
A variant of the interactive debugger, the break handler, is entered as the result of a keyboard interrupt handled by the default keyboard-interrupt handler or an explicit call to the procedure break handled by the default break handler. Again, the command "?" lists the command options. These include commands to:
It is also usually possible to exit from the debugger or break handler by typing the end-of-file character ("control-D" under Unix, "control-Z" under Windows).
procedure: (debug)
returns: does not return
libraries: (chezscheme)
When the default exception handler receives a serious or non-warning condition, it displays the condition and resets to the current café. Before it resets, it saves the condition in the parameter debug-condition. The debug procedure may be used to inspect the condition. Whenever one of the built-in error-reporting mechanisms is used to raise an exception, the continuation at the point where the exception was raised can be inspected as well. More generally, debug allows the continuation contained within any continuation condition created by make-continuation-condition to be inspected.
If the parameter debug-on-exception is set to #t, the default exception handler enters the debugger directly for all serious and non-warning conditions, delaying its reset until after the debugger exits. The --debug-on-exception command-line option may be used to set debug-on-exception to #t from the command line, which is particularly useful when debugging scripts or top-level programs run via the --script or --program command-line options.
The inspector may be called directly via the procedure inspect or indirectly from the debugger. It allows the programmer to examine circular objects, objects such as ports and procedures that do not have a reader syntax, and objects such as continuations and variables that are not directly accessible by the programmer, as well as ordinary printable Scheme objects.
The primary intent of the inspector is examination, not alteration, of objects. The values of assignable variables may be changed from within the inspector, however. Assignable variables are generally limited to those for which assignments occur in the source program. It is also possible to invoke arbitrary procedures (including mutation procedures such as set-car!) on an object. No mechanism is provided for altering objects that are inherently immutable, e.g., nonassignable variables, procedures, and bignums, since doing so can violate assumptions made by the compiler and run-time system.
The user is presented with a prompt line that includes a printed representation of the current object, abbreviated if necessary to fit on the line. Various commands are provided for displaying objects and moving around inside of objects. On-line descriptions of the command options are provided. The command "?" displays commands that apply specifically to the current object. The command "??" displays commands that are always applicable. The command "h" provides a brief description of how to use the inspector. The end-of-file character or the command "q" exits the inspector.
procedure: (inspect obj)
returns: unspecified
libraries: (chezscheme)
Invokes the inspector on obj, as described above. The commands recognized by the inspector are listed below, categorized by the type of the current object.
Generally applicable commands
help or h displays a brief description of how to use the inspector.
? displays commands applicable to the current type of object.
?? displays the generally applicable commands.
print or p prints the current object (using pretty-print).
write or w writes the current object (using write).
size writes the size in bytes occupied by the current object (determined via compute-size), including any objects accessible from the current object except those for which the size was previously requested during the same interactive inspector session.
find expr [ g ] evaluates expr, which should evaluate to a procedure of one argument, and searches (via make-object-finder) for the first occurrence of an object within the current object for which the predicate returns a true value, treating immediate values (e.g., fixnums), values in generations older than g, and values already visited during the search as leaves. If g is not unspecified, it defaults to the current maximum generation, i.e., the value of collect-maximum-generation. If specified, g must be an exact nonnegative integer less than or equal to the current maximum generation or the symbol static representing the static generation. If such an object is found, the inspector's focus moves to that object as if through a series of steps that lead from the current object to the located object, so that the up command can be used to determine where the object was found relative to the original object.
find-next repeats the last find, locating an occurrence not previously found, if any.
up or u n returns to the nth previous level. Used to move outwards in the structure of the inspected object. n defaults to 1.
top or t returns to the outermost level of the inspected object.
forward or f moves to the nth next expression. Used to move from one element to another of an object containing a sequence of elements, such as a list, vector, record, frame, or closure. n defaults to 1.
back or b moves to the nth previous expression. Used to move from one element to another of an object containing a sequence of elements, such as a list, vector, record, frame, or closure. n defaults to 1.
=> expr sends the current object to the procedure value of expr. expr may begin on the current or following line and may span multiple lines.
file path opens the source file at the specified path for listing. The parameter source-directories (Section 12.5) determines the set of directories searched for source files.
list line count lists count lines of the current source file (see file) starting at line. line defaults to the end of the previous set of lines listed and count defaults to ten or the number of lines previously listed. If line is negative, listing begins line lines before the previous set of lines listed.
files shows the currently open source files.
mark or m m marks the current location with the symbolic mark m. If m is not specified, the current location is marked with a unique default mark.
goto or g m returns to the location marked m. If m is not specified, the inspector returns to the location marked with the default mark.
new-cafe or n enters a new read-eval-print loop (café), giving access to the normal top-level environment.
quit or q exits from the inspector.
reset or r resets to the current café.
abort or a x aborts from Scheme with exit status x, which defaults to -1.
Continuation commands
show-frames or sf shows the next n frames. If n is not specified, all frames are displayed.
depth displays the number of frames in the continuation.
down or d n move to the nth frame down in the continuation. n defaults to 1.
show or s shows the continuation (next frame) and, if available, the calling procedure source, the pending call source, the closure, and the frame and free-variable values. Source is available only if generation of inspector information was enabled during compilation of the corresponding lambda expression.
show-local or sl is like show or s except that free variable values are not shown. (If present, free variable values can be found by inspecting the closure.)
length or l displays the number of elements in the topmost frame of the continuation.
ref or r moves to the nth or named frame element. n defaults to 0. If multiple elements have the same name, only one is accessible by name, and the others must be accessed by number.
code or c moves to the source for the calling procedure.
call moves to the source for the pending call.
file opens the source file containing the pending call, if known. The parameter source-directories (Section 12.5) determines the list of source directories searched for source files identified by relative path names.
For absolute pathnames starting with a / (or \ or a directory specifier under Windows), the inspector tries the absolute pathname first, then looks for the last (filename) component of the path in the list of source directories. For pathnames starting with ./ (or .\ under Windows) or ../ (or ..\ under Windows), the inspector looks in "." or ".." first, as appropriate, then for the entire .- or ..-prefixed pathname in the source directories, then for the last (filename) component in the source directories. For other (relative) pathnames, the inspector looks for the entire relative pathname in the list of source directories, then the last (filename) component in the list of source directories.
If a file by the same name as but different contents from the original source file is found during this process, it will be skipped over. This typically happens because the file has been modified since it was compiled. Pass an explicit filename argument to force opening of a particular file (see the generally applicable commands above).
eval or e expr evaluates the expression expr in an environment containing bindings for the elements of the frame. Within the evaluated expression, the value of each frame element n is accessible via the variable %n. Named elements are accessible via their names as well. Names are available only if generation of inspector information was enabled during compilation of the corresponding lambda expression.
set! or ! n e sets the value of the nth frame element to e, if the frame element corresponds to an assignable variable. n defaults to 0.
Procedure commands
show or s shows the source and free variables of the procedure. Source is available only if generation of inspector information was enabled during compilation of the corresponding lambda expression.
code or c moves to the source for the procedure.
file opens the file containing the procedure's source code, if known. See the description of the continuation file entry above for more information.
length or l displays the number of free variables whose values are recorded in the procedure object.
ref or r moves to the nth or named free variable. n defaults to 0. If multiple free variables have the same name, only one is accessible by name, and the others must be accessed by number.
set! or ! n e sets the value of the nth free variable to e, if the variable is assignable. n defaults to 0.
eval or e expr evaluates the expression expr in an environment containing bindings for the free variables of the procedure. Within the evaluated expression, the value of each free variable n is accessible via the variable %n. Named free variables are accessible via their names as well. Names are available only if generation of inspector information was enabled during compilation of the corresponding lambda expression.
Pair (list) commands
show or s n shows the first n elements of the list. If n is not specified, all elements are displayed.
length or l displays the list length.
car moves to the object in the car of the current object.
cdr moves to the object in the cdr.
ref or r n moves to the nth element of the list. n defaults to 0.
tail n moves to the nth cdr of the list. n defaults to 1.
Vector, Bytevector, and Fxvector commands
show or s n shows the first n elements of the vector. If n is not specified, all elements are displayed.
length or l displays the vector length.
ref or r n moves to the nth element of the vector. n defaults to 0.
String commands
show or s n shows the first n elements of the string. If n is not specified, all elements are displayed.
length or l displays the string length.
ref or r n moves to the nth element of the string. n defaults to 0.
unicode n displays the first n elements of the string as hexadecimal Unicode scalar values.
ascii n displays the first n elements of the string as hexadecimal ASCII values, using -- to denote characters whose Unicode scalar values are not in the ASCII range.
Symbol commands
show or s shows the fields of the symbol.
value or v moves to the top-level value of the symbol.
name or n moves to the name of the symbol.
property-list or pl moves to the property list of the symbol.
ref or r n moves to the nth field of the symbol. Field 0 is the top-level value of the symbol, field 1 is the symbol's name, and field 2 is its property list. n defaults to 0.
Character commands
unicode displays the hexadecimal Unicode scalar value for the character.
ascii displays the hexadecimal ASCII code for the character, using -- to denote characters whose Unicode scalar values are not in the ASCII range.
Box commands
show or s shows the contents of the box.
unbox or ref or r moves to the boxed object.
Port commands
show or s shows the fields of the port, including the input and output size, index, and buffer fields.
name moves to the port's name.
handler moves to the port's handler.
output-buffer or ob moves to the port's output buffer.
input-buffer or ib moves to the port's input buffer.
Record commands
show or s shows the contents of the record.
fields moves to the list of field names of the record.
name moves to the name of the record.
rtd moves to the record-type descriptor of the record.
ref or r name moves to the named field of the record, if accessible.
set! or ! name value sets the value of the named field of the record, if mutable.
Transport Link Cell (TLC) commands
show or s shows the fields of the TLC.
keyval moves to the keyval of the TLC.
tconc moves to the tconc of the TLC.
next moves to the next link of the TLC.
ref or r n moves to the nth field of the symbol. Field 0 is the keyval, field 1 the tconc, and field 2 the next link. n defaults to 0.
A facility for noninteractive inspection is also provided to allow construction of different inspection interfaces. Like the interactive facility, it allows objects to be examined in ways not ordinarily possible. The noninteractive system follows a simple, object-oriented protocol. Ordinary Scheme objects are encapsulated in procedures, or inspector objects, that take symbolic messages and return either information about the encapsulated object or new inspector objects that encapsulate pieces of the object.
procedure: (inspect/object object)
returns: an inspector object procedure
libraries: (chezscheme)
inspect/object is used to turn an ordinary Scheme object into an inspector object. All inspector objects accept the messages type, print, write, and size. The type message returns a symbolic representation of the type of the object. The print and write messages must be accompanied by a port parameter. They cause a representation of the object to be written to the port, using the Scheme procedures pretty-print and write. The size message returns a fixnum representing the size in bytes occupied by the object, including any objects accessible from the current object except those for which the size was already requested via an inspector object derived from the argument of the same inspect/object call.
All inspector objects except for variable inspector objects accept the message value, which returns the actual object encapsulated in the inspector object.
(define x (inspect/object '(1 2 3)))
(x 'type) pair
(define p (open-output-string))
(x 'write p)
(get-output-string p) "(1 2 3)"
(x 'length) (proper 3)
(define y (x 'car))
(y 'type) simple
(y 'value) 1
Pair inspector objects. Pair inspector objects contain Scheme pairs.
(pair-object 'type) returns the symbol pair.
(pair-object 'car) returns an inspector object containing the "car" field of the pair.
(pair-object 'cdr) returns an inspector object containing the "cdr" field of the pair.
(pair-object 'length) returns a list of the form (type count). The type field contains the symbol proper, the symbol improper, or the symbol circular, depending on the structure of the list. The count field contains the number of distinct pairs in the list.
Box inspector objects. Box inspector objects contain Chez Scheme boxes.
(box-object 'type) returns the symbol box.
(box-object 'unbox) returns an inspector object containing the contents of the box.
TLC inspector objects. Box inspector objects contain Chez Scheme boxes.
(tlc-object 'type) returns the symbol tlc.
(tlc-object 'keyval) returns an inspector object containing the TLC's keyval.
(tlc-object 'tconc) returns an inspector object containing the TLC's tconc.
(tlc-object 'next) returns an inspector object containing the TLC's next link.
Vector, String, Bytevector, and Fxvector inspector objects. Vector (bytevector, string, fxvector) inspector objects contain Scheme vectors (bytevectors, strings, fxvectors).
(vector-object 'type) returns the symbol vector (string, bytevector, fxvector).
(vector-object 'length) returns the number of elements in the vector or string.
(vector-object 'ref n) returns an inspector object containing the nth element of the vector or string.
Simple inspector objects. Simple inspector objects contain unstructured, unmodifiable objects. These include numbers, booleans, the empty list, the end-of-file object, and the void object. They may be examined directly by asking for the value of the object.
(simple-object 'type) returns the symbol simple.
Unbound inspector objects. Although unbound objects are not normally accessible to Scheme programs, they may be encountered when inspecting variables.
(unbound-object 'type) returns the symbol unbound.
Procedure inspector objects. Procedure inspector objects contain Scheme procedures.
(procedure-object 'type) returns the symbol procedure.
(procedure-object 'length) returns the number of free variables.
(procedure-object 'ref n) returns an inspector object containing the nth free variable of the procedure. See the description below of variable inspector objects. n must be nonnegative and less than the length of the procedure.
(procedure-object 'eval expr) evaluates expr and returns its value. The values of the procedure's free variables are bound within the evaluated expression to identifiers of the form %n, where n is the location number displayed by the inspector. The values of named variables are also bound to their names.
(procedure-object 'code) returns an inspector object containing the procedure's code object. See the description below of code inspector objects.
Continuation inspector objects. Continuations created by call/cc are actually procedures. However, when inspecting such a procedure the underlying data structure that embodies the continuation may be exposed. A continuation structure contains the location at which computation is to resume, the variable values necessary to perform the computation, and a link to the next continuation.
(continuation-object 'type) returns the symbol continuation.
(continuation-object 'length) returns the number of free variables.
(continuation-object 'ref n) returns an inspector object containing the nth free variable of the continuation. See the description below of variable inspector objects. n must be nonnegative and less than the length of the continuation.
(continuation-object 'eval expr) evaluates expr and returns its value. The values of frame locations are bound within the evaluated expression to identifiers of the form %n, where n is the location number displayed by the inspector. The values of named locations are also bound to their names.
(continuation-object 'code) returns an inspector object containing the code object for the procedure that was active when the current continuation frame was created. See the description below of code inspector objects.
(continuation-object 'depth) returns the number of frames in the continuation.
(continuation-object 'link) returns an inspector object containing the next continuation frame. The depth must be greater than 1.
(continuation-object 'link* n) returns an inspector object containing the nth continuation link. n must be less than the depth.
(continuation-object 'source) returns an inspector object containing the source information attached to the continuation (representing the source for the application that resulted in the formation of the continuation) or #f if no source information is attached.
(continuation-object 'source-path) attempts to find the pathname of the file containing the source for the procedure application that resulted in the formation of the continuation. If successful, three values are returned to identify the file and position of the application within the file: path, line, and char. Two values, a file name and an absolute character position, are returned if the file name is known but the named file cannot be found. The search may be unsuccessful even if a file by the expected name is found in the path if the file has been modified since the source code was compiled. If no file name is known, no values are returned. The parameter source-directories (Section 12.5) determines the set of directories searched for source files identified by relative path names.
Code inspector objects. Code inspector objects contain Chez Scheme code objects.
(code-object 'type) returns the symbol code.
(code-object 'name) returns a string or #f. The name associated with a code inspector object is the name of the variable to which the procedure was originally bound or assigned. Since the binding of a variable can be changed, this name association may not always be accurate. #f is returned if the inspector cannot determine a name for the procedure.
(code-object 'source) returns an inspector object containing the source information attached to the code object or #f if no source information is attached.
(code-object 'source-path) attempts to find the pathname of the file containing the source for the lambda expression that produced the code object. If successful, three values are returned to identify the file and position of the application within the file: path, line, and char. Two values, a file name and an absolute character position, are returned if the file name is known but the named file cannot be found. The search may be unsuccessful even if a file by the expected name is found in the path if the file has been modified since the source code was compiled. If no file name is known, no values are returned. The parameter source-directories (Section 12.5) determines the set of directories searched for source files identified by relative path names.
(code-object 'free-count) returns the number of free variables in any procedure for which this is the corresponding code.
Variable inspector objects. Variable inspector objects encapsulate variable bindings. Although the actual underlying representation varies, the variable inspector object provides a uniform interface.
(variable-object 'type) returns the symbol variable.
(variable-object 'name) returns a symbol or #f. #f is returned if the name is not available or if the variable is a compiler-generated temporary variable. Variable names are not retained when the parameter generate-inspector-information (page 12.6) is false during compilation.
(variable-object 'ref) returns an inspector object containing the current value of the variable.
(variable-object 'set! e) returns unspecified, after setting the current value of the variable to e. An exception is raised with condition type &assertion if the variable is not assignable.
Port inspector objects. Port inspector objects contain ports.
(port-object 'type) returns the symbol port.
(port-object 'input?) returns #t if the port is an input port, #f otherwise.
(port-object 'output?) returns #t if the port is an output port, #f otherwise.
(port-object 'binary?) returns #t if the port is a binary port, #f otherwise.
(port-object 'closed?) returns #t if the port is closed, #f if the port is open.
(port-object 'name) returns an inspector object containing the port's name.
(port-object 'handler) returns a procedure inspector object encapsulating the port handler, such as would be returned by port-handler.
(port-object 'output-size) returns the output buffer size as a fixnum if the port is an output port (otherwise the value is unspecified).
(port-object 'output-index) returns the output buffer index as a fixnum if the port is an output port (otherwise the value is unspecified).
(port-object 'output-buffer) returns an inspector object containing the string used for buffered output.
(port-object 'input-size) returns the input buffer size as a fixnum if the port is an input port (otherwise the value is unspecified).
(port-object 'input-index) returns the input buffer index as a fixnum if the port is an input port (otherwise the value is unspecified).
(port-object 'input-buffer) returns an inspector object containing the string used for buffered input.
Symbol inspector objects. Symbol inspector objects contain symbols. These include gensyms.
(symbol-object 'type) returns the symbol symbol.
(symbol-object 'name) returns a string inspector object. The string name associated with a symbol inspector object is the print representation of a symbol, such as would be returned by the procedure symbol->string.
(symbol-object 'gensym?) returns #t if the symbol is a gensym, #f otherwise. Gensyms are created by gensym.
(symbol-object 'top-level-value) returns an inspector object containing the global value of the symbol.
(symbol-object 'property-list) returns an inspector object containing the property list for the symbol.
Record inspector objects. Record inspector objects contain records.
(record-object 'type) returns the symbol record.
(record-object 'name) returns a string inspector object corresponding to the name of the record type.
(record-object 'fields) returns an inspector object containing a list of the field names of the record type.
(record-object 'length) returns the number of fields.
(record-object 'rtd) returns an inspector object containing the record-type descriptor of the record type.
(record-object 'accessible? name) returns #t if the named field is accessible, #f otherwise. A field may be inaccessible if optimized away by the compiler.
(record-object 'ref name) returns an inspector object containing the value of the named field. An exception is raised with condition type &assertion if the named field is not accessible.
(record-object 'mutable? name) returns #t if the named field is mutable, #f otherwise. A field is immutable if it is not declared mutable or if the compiler optimizes away all assignments to the field.
(record-object 'set! name value) sets the value of the named field to value. An exception is raised with condition type &assertion if the named field is not assignable.
procedure: (make-object-finder pred)
procedure: (make-object-finder pred g)
procedure: (make-object-finder pred x g)
returns: see below
libraries: (chezscheme)
The procedure make-object-finder takes a predicate pred and two optional arguments: a starting point x and a maximum generation g. The starting point defaults to the value of the procedure oblist, and the maximum generation defaults to the value of the parameter collect-maximum-generation. make-object-finder returns an object finder p that can be used to search for objects satisfying pred within the starting-point object x. Immediate objects and objects in generations older than g are treated as leaves. p is a procedure accepting no arguments. If an object y satisfying pred can be found starting with x, p returns a list whose first element is y and whose remaining elements represent the path of objects from x to y, listed in reverse order. p can be invoked multiple times to find additional objects satisfying the predicate, if any. p returns #f if no more objects matching the predicate can be found.
p maintains internal state recording where it has been so it can restart at the point of the last found object and not return the same object twice. The state can be several times the size of the starting-point object x and all that is reachable from x.
The interactive inspector provides a convenient interface to the object finder in the form of find and find-next commands.
Relocation tables for static code objects are discarded by default, which prevents object finders from providing accurate results when static code objects are involved. That is, they will not find any objects pointed to directly from a code object that has been promoted to the static generation. If this is a problem, the command-line argument --retain-static-relocation can be used to prevent the relocation tables from being discarded.
The procedures compute-size and compute-composition can be used to determine the size or composition of an object, including anything reachable via pointers from the object. Depending on the number of objects reachable from the object, the procedures potentially allocate a large amount of memory. In an application for which knowing the number, size, generation, and types of all objects in the heap is sufficient, object-counts is potentially much more efficient.
These procedures treat immediate objects such as fixnums, booleans, and characters as zero-count, zero-byte leaves.
By default, these procedures also treat static objects (those in the initial heap) as zero-count, zero-byte leaves. Both procedures accept an optional second argument that specifies the maximum generation of interest, with the symbol static being used to represent the static generation.
Objects sometimes point to a great deal more than one might expect. For example, if static data is included, the procedure value of (lambda (x) x) points indirectly to the exception handling subsystem (because of the argument-count check) and many other things as a result of that.
Relocation tables for static code objects are discarded by default, which prevents these procedures from providing accurate results when static code objects are involved. That is, they will not find any objects pointed to directly from a code object that has been promoted to the static generation. If accurate sizes and compositions for static code objects are required, the command-line argument --retain-static-relocation can be used to prevent the relocation tables from being discarded.
procedure: (compute-size object)
procedure: (compute-size object generation)
returns: see below
libraries: (chezscheme)
object can be any object. generation must be a fixnum between 0 and the value of collect-maximum-generation, inclusive, or the symbol static. If generation is not supplied, it defaults to the value of collect-maximum-generation.
compute-size returns the amount of memory, in bytes, occupied by object and anything reachable from object in any generation less than or equal to generation. Immediate values such as fixnums, booleans, and characters have zero size.
The following examples are valid for machines with 32-bit pointers.
(compute-size 0) 0
(compute-size (cons 0 0)) 8
(compute-size (cons (vector #t #f) 0)) 24
(compute-size
(let ([x (cons 0 0)])
(set-car! x x)
(set-cdr! x x)
x)) 8
(define-record-type frob (fields x))
(collect 1 1) ; force rtd into generation 1
(compute-size
(let ([x (make-frob 0)])
(cons x x))
0) 16
procedure: (compute-composition object)
procedure: (compute-composition object generation)
returns: see below
libraries: (chezscheme)
object can be any object. generation must be a fixnum between 0 and the value of collect-maximum-generation, inclusive, or the symbol static. If generation is not supplied, it defaults to the value of collect-maximum-generation.
compute-composition returns an association list representing the composition of object, including anything reachable from it in any generation less than or equal to generation. The association list has the following structure:
((type count . bytes) ...)
type is either the name of a primitive type, represented as a symbol, e.g., pair, or a record-type descriptor (rtd). count and bytes are nonnegative fixnums.
Immediate values such as fixnums, booleans, and characters are not included in the composition.
The following examples are valid for machines with 32-bit pointers.
(compute-composition 0) ()
(compute-composition (cons 0 0)) ((pair 1 . 8))
(compute-composition
(cons (vector #t #f) 0)) ((pair 1 . 8) (vector 1 . 16))
(compute-composition
(let ([x (cons 0 0)])
(set-car! x x)
(set-cdr! x x)
x)) ((pair 1 . 8)
(define-record-type frob (fields x))
(collect 1 1) ; force rtd into generation 1
(compute-composition
(let ([x (make-frob 0)])
(cons x x))
0) ((pair 1 . 8)
(#<record type frob> 1 . 8))
Chez Scheme Version 9 User's Guide
Copyright © 2016 Cisco Systems, Inc.
Licensed under the Apache License Version 2.0
(full copyright notice.).
Revised June 2016 for Chez Scheme Version 9.4
about this book


This is a basic usage of the popover. Popovers can containcan any content and will flex accordingly. When the height of slide is unknown (which is most of the time), by default the popover will auto adjust its height to each slide. For this reason, it's best to position the popover at the bottom.
You have been logged in!
If you position a popover on top and click the button below you will see the popover position falls out of alignment when the height is changed. Click all the way through the process to see the positioning fail.
You have been logged in!
Top positioned popovers can maintain their height by using the initial slide as the height. This works best when the first slide is taller than the rest. In the event the latter slides are taller than the first, the content will automatically overflow.
You have been logged in!


Some Nest Hello owners have been stuck with Halloween-themed sounds
Source: Android Central
What you need to know
- Google Nest Hello owners could play spooky Halloween doorbells.
- The option to remove or change the theme disappeared from the settings.
- Google is rolling out a fix presently.
Google Nest Hello doorbell owners who wanted in on the Halloween spooky spirit were haunted by their choice for almost a week after the night ended. Some Google Nest doorbell owners reported to Android Police that they were unable to resume normal operation after the option to change themes disappeared from the Doorbell settings app on both iOS and Android, as well as from the web interface.
Google has already worked out a fix and says that owners will see an update shortly. The company still plans on releasing more theme sounds in the future, though perhaps zealous owners will think twice before committing to turkey gobbles every time someone shows up for dinner.
Frankly, it's hard to imagine a worse holiday for this to happen. Certainly, Christmas music would be repetitive, but a week of carols in your house is no worse than at the mall, the office, the car, and everywhere else. Perhaps if Valentine's Day created a moist kiss doorbell that would be more annoying, but spooky noises and screams probably take the cake for worst doorbell option for November.
Scary Smart
Google Nest Hello
A cool way to ring a doorbell
The Nest Hello is an outstanding connected doorbell that really shines when paired with other Nest products. Buy one before the holidays for immersive home entry.
We may earn a commission for purchases using our links. Learn more.