Skip to content

Instantly share code, notes, and snippets.

View spockz's full-sized avatar

Alessandro Vermeulen spockz

View GitHub Profile
Fri Apr 2 22:59 2010 Time and Allocation Profiling Report (Final)
raytrace +RTS -P -hc -RTS tests/Input/gml/references/testall.gml
total time = 133.14 secs (6657 ticks @ 20 ms)
total alloc = 34,741,677,700 bytes (excludes profiling overheads)
COST CENTRE MODULE %time %alloc ticks bytes
intervals'_ayaN Base.Shape.Cylinder 19.7 17.9 1313 1552298191
data Zero = Zero
data Succ a = Succ a
class Times x y z | x y -> z where
times :: x -> y -> z
instance Times Zero x Zero where
times Zero x = Zero
instance (Times n x r', Add x r' r) => Times (Succ n) x r where
DSN: pgsql://klantenlogin:*password with a dot*@unix(/var/run/postgresql)/bink_klantenlogin_ng
->
doctrine-version: 1.2.2
error:
PDO Connection Error: SQLSTATE[08006] [7] could not translate host name "unix(" to address: Name or service not known
static public function getByLicenceNumber($aLicenceNumber, $aHydration = Doctrine::HYDRATE_ARRAY) {
$q = Doctrine_Query::create()
->select('c.*, o.*')
->from('Client c')
->leftJoin('c.Orders o')
->where('c.licencenumber = ?', (string) $aLicenceNumber);
return $q->fetchOne();
}
static public function add_order($aLicenceNumber, $aOrderXML) {
[Wed Jun 09 18:04:16 2010] [warn] [client 192.168.***.***] [10661] auth_ldap authenticate: user **** authentication failed; URI /svn [LDAP: ldap_simple_bind_s() failed][Can't contact LDAP server]
<%= link_to "invoice", formatted_invoice_shop_path( :pdf , :id => @invoice.id)
=>http://localhost:3000/shop/invoice?id=2179314940
and
<%= link_to "invoice", formatted_invoice_shop_path( :pdf ) , :id => @invoice.id
=>http://localhost:3000/shop/invoice.pdf
<%= link_to "invoice", :controller => "shop", :action => "invoice", :id => @invoice.id, :format => :pdf %>
Results in: /shop/invoice/#id?format=pdf, I want: /shop/invoice.pdf/#id or /shop/invoice.pdf?id=#id
user_sessions GET /user_sessions(.:format) {:controller=>"user_sessions", :action=>"index"}
POST /user_sessions(.:format) {:controller=>"user_sessions", :action=>"create"}
new_user_session GET /user_sessions/new(.:format) {:controller=>"user_sessions", :action=>"new"}
edit_user_session GET /user_sessions/:id/edit(.:format) {:controller=>"user_sessions", :action=>"edit"}
user_session GET /user_sessions/:id(.:format) {:controller=>"user_sessions", :action=>"show"}
PUT /user_sessions/:id(.:format) {:controller=>"user_sessions", :action=>"update"}
DELETE /user_sessions/:id(.:format) {:controller=>"user_sessions", :action=>"destroy"}
payment_methods GET /payment_methods(.:format) {:controller=>"payment_methods", :action=>"index"}
POST /payment_methods(.:format) {:controller=>"payment_methods", :action=>"create"}
new_paymen
Transaction.find(1).id
=>1
YAML::dump(Transaction.find(1).detail)
=>--- !ruby/object:Transaction::Detail attributes: subscription_plan_name: foobar payment_method: visa feature_level: foobar recurring: true prefix_options: {}
Transaction.find(1).detail.payment_method
=> undefined method `payment_method' for #<Transaction::Detail:0x103e28a70>
Transaction.find(1).detail.attributes.payment_method
package com.twitter.finagle.httpx
import com.twitter.finagle._
import com.twitter.util.{Await, Future}
import org.junit.runner.RunWith
import org.scalatest.junit.JUnitRunner
import org.scalatest.{FunSuite, ShouldMatchers}
import scala.compat.Platform