This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
; ----------------------------------------------------------------------------- | |
; main.asm - FASt Server - Main FASt Server entry point and loader. | |
; http://www.jamesladdcode.com/ | |
; | |
; ----------------------------------------------------------------------------- | |
; | |
.686 ; create 32 bit code | |
.model flat, stdcall ; 32 bit memory model | |
option casemap :none ; case sensitive |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
ProtoObject, null | |
Object, ProtoObject | |
Behavior, Object | |
ClassDescription, Behavior | |
Metaclass, ClassDescription | |
Class, ClassDescription | |
Collection, Object | |
SequenceableCollection, Collection | |
ArrayedCollection, SequenceableCollection | |
String, ArrayedCollection |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
program returns [Program n] | |
: (chunk)* EOF | |
; | |
chunk returns [Chunk n] | |
: sequence EOF | |
| sequence '!' | |
| '!' sequence '!' | |
| messagePattern sequence '! !' | |
; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
gem list | cut -d" " -f1 | xargs gem uninstall -aIx |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require 'rubygems' | |
require 'koala' | |
# | |
# initialize a Graph API connection | |
@oauth = Koala::Facebook::OAuth.new(app_id, code, "https://www.facebook.com/connect/login_success.html") | |
@url_for_oauth_code = @oauth.url_for_oauth_code(:permissions => "publish_stream") | |
puts @url_for_oauth_code.inspect | |
# Goto the URL printed above in your browser - it should print 'success' and in the |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require 'rubygems' | |
require 'koala' | |
# | |
# initialize a Graph API connection | |
@oauth = Koala::Facebook::OAuth.new(app_id, app_secret, "https://www.facebook.com/connect/login_success.html") | |
@url_for_oauth_code = @oauth.url_for_oauth_code(:permissions => "publish_stream") | |
puts @url_for_oauth_code.inspect | |
@your_oauth_token = "goto above printed url and copy code= upto # into this string, then run again." |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
to create Facebook events with a picture through the Graph API you need to use a multipart post request and give the image the key "picture". | |
This is not documented. At all. Anywhere. Except here. | |
To do this in Koala, you can use a line like this: | |
graph = Koala::Facebook::GraphAPI.new( oauth.get_app_access_token ) | |
graph.put_object( APP_ID, "events", { | |
:name => "Some event", | |
:start_time => Time.now.to_s, | |
:description => "Facebook API docs suck", |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
****** | |
IN DynamicJavaClassAdaptor.build | |
"@: smallTalkClassesThatAdaptJavaClasses.java.util.ArrayListAdaptor" | |
import: 'java.util.List' as: 'smallTalkClassesThatAdaptJavaClasses_java_util_ListAdaptor'. | |
import: 'java.util.ListIterator' as: 'smallTalkClassesThatAdaptJavaClasses_java_util_ListIteratorAdaptor'. | |
import: 'java.util.Iterator' as: 'smallTalkClassesThatAdaptJavaClasses_java_util_IteratorAdaptor'. | |
import: 'java.lang.Object' as: 'smallTalkClassesThatAdaptJavaClasses_java_lang_ObjectAdaptor'. | |
Object < #ArrayListAdaptor. | |
ArrayListAdaptor class atSelector: #withCollection: put: [ :args || obj | | |
JVM new:'java/util/ArrayList'. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# - ORIGINAL - Requires 12 test cases the provide to_ansi does what it should | |
# 1. Test empty commands map returns "" | |
# 2. 11 Tests to test each if/elsif. | |
# | |
class Clear; end | |
class HideCursor; end | |
class ShowCursor; end | |
class SetPos < Value.new(:row, :column); end | |
class FG < Value.new(:red, :green, :blue); end |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package com.east; | |
import java.util.*; | |
interface ContainedListener { | |
void notifyContained(Object item, boolean matched); | |
} | |
public class PermissionService implements ContainedListener { |
OlderNewer