mirror of
https://github.com/ubf/ubf.git
synced 2026-04-16 17:55:48 +00:00
import ubf-1.9.tgz
This commit is contained in:
74
#ball.erl#
74
#ball.erl#
@@ -1,74 +0,0 @@
|
||||
%% ``The contents of this file are subject to the Erlang Public License,
|
||||
%% Version 1.1, (the "License"); you may not use this file except in
|
||||
%% compliance with the License. You should have received a copy of the
|
||||
%% Erlang Public License along with this software. If not, it can be
|
||||
%% retrieved via the world wide web at http://www.erlang.org/.
|
||||
%%
|
||||
%% Software distributed under the License is distributed on an "AS IS"
|
||||
%% basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See
|
||||
%% the License for the specific language governing rights and limitations
|
||||
%% under the License.
|
||||
%%
|
||||
%% The Initial Developer of the Original Code is Ericsson Utvecklings AB.
|
||||
%% Portions created by Ericsson are Copyright 1999, Ericsson Utvecklings
|
||||
%% AB. All Rights Reserved.''
|
||||
%%
|
||||
%% $Id$
|
||||
%%
|
||||
%% ------------------------------------------------------------
|
||||
%% A simple demo showing a ball
|
||||
%% bouncing in a window.
|
||||
%% ------------------------------------------------------------
|
||||
|
||||
-module(ball).
|
||||
|
||||
-export([start/0,init/0]).
|
||||
|
||||
start() ->
|
||||
spawn(ball,init,[]).
|
||||
|
||||
init() ->
|
||||
I= gs:start(),
|
||||
W= gs:window(I,[{title,"Ball"},{width,300},{height,300},{map,true}]),
|
||||
C= gs:canvas(W,[{width,300},{height,300},{bg,yellow}]),
|
||||
B= gs:button(W,[{label, {text,"Quit Demo"}},{x,100}]),
|
||||
Ball = gs:oval(C,[{coords,[{0,0},{50,50}]},{fill,red}]),
|
||||
ball(Ball,0,0,5.5,4.1).
|
||||
|
||||
ball(Ball,X,Y,DX,DY) ->
|
||||
{NX,NDX} = cc(X,DX),
|
||||
{NY,NDY} = cc(Y,DY),
|
||||
gs:config(Ball,{move,{DX,DY}}),
|
||||
receive
|
||||
{gs,Id,click,_,_} -> exit(normal);
|
||||
{gs,_,destroy,_,_} -> exit(normal)
|
||||
after 20 ->
|
||||
true
|
||||
end,
|
||||
ball(Ball,NX,NY,NDX,NDY).
|
||||
|
||||
cc(X,DX) ->
|
||||
if
|
||||
DX>0 ->
|
||||
if
|
||||
X=<250 ->
|
||||
{X+DX,DX};
|
||||
x>250 ->
|
||||
{X-DX,-DX}
|
||||
end;
|
||||
DX<0 ->
|
||||
if
|
||||
X>=0 ->
|
||||
{X+DX,DX};
|
||||
X<0 ->
|
||||
{X-DX,-DX}
|
||||
end
|
||||
end.
|
||||
|
||||
%% ------------------------------------------------------------
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
188
#irc_plugin.erl#
188
#irc_plugin.erl#
@@ -1,188 +0,0 @@
|
||||
-module(irc_plugin).
|
||||
|
||||
-export([manager_start/2, client_stop/3,
|
||||
managerStartState/0, handlerStartState/0,
|
||||
manager_rpc/2, handle_rpc/4]).
|
||||
|
||||
-import(server, [sendEvent/2, ask_manager/2]).
|
||||
-import(lists, [delete/2, map/2, member/2, foreach/2]).
|
||||
|
||||
%% NOTE the following two lines
|
||||
|
||||
-compile({parse_transform,contract_parser}).
|
||||
-add_contract("irc_plugin").
|
||||
|
||||
-define(S(X), {'#S',X}).
|
||||
s(X) -> {'#S', X}.
|
||||
|
||||
managerStartState() -> new_seed(), ets:new(irc, []).
|
||||
|
||||
handlerStartState() -> myHandlerState.
|
||||
|
||||
%% manager_start(Args, State) is called every time a session is started
|
||||
%% Args comes from client:start(Host,Port,Service,Args)
|
||||
%% Service in the rcp:start must match name()
|
||||
%% manager_start(Args, State) -> {accept, Reply, State} | {reject, Why, State}
|
||||
%% State is the manager state.
|
||||
|
||||
manager_start(_, ManagerState) ->
|
||||
{accept, yes, start, [], ManagerState}.
|
||||
|
||||
client_stop(Pid, Reason, Ets) ->
|
||||
io:format("Client stopped:~p ~p~n",[Pid, Reason]),
|
||||
{Nick, Groups} = facts(Ets, Pid),
|
||||
io:format("Pid has nick~p is in groups~p~n",[Nick, Groups]),
|
||||
ets:delete(Ets, {facts, Pid}),
|
||||
ets:delete(Ets, {pid, Nick}),
|
||||
foreach(fun(G) ->
|
||||
Pids = pids(Ets, G),
|
||||
Pids1 = delete(Pid, Pids),
|
||||
ets:insert(Ets, {{group,G}, Pids1}),
|
||||
broadcast_to_group(Pids1, {leaves, s(Nick), s(G)})
|
||||
end, Groups),
|
||||
Ets.
|
||||
|
||||
%% The manager state
|
||||
%% Is what ??
|
||||
%% We know the Pid of the Client
|
||||
%% The Nick of the client on the Pid
|
||||
%% The set of groups that the client is joined to
|
||||
|
||||
%% This is all in one ets table
|
||||
%% {group, Name} => [Pids] (all the Pids in a group)
|
||||
%% {group, "erlang"} => [Pid1, Pid2, ...]
|
||||
%% {facts, Pid} => {Nick, [Group]}
|
||||
%% The nick and the List of joined groups
|
||||
%% for Pid
|
||||
%% {pid, Nick} => Pid
|
||||
|
||||
%% When somebody joins or leaves a group broadcast that
|
||||
%% they have joined or leaved the group
|
||||
%% When somebody dies remove their nick
|
||||
%% and remove them from all groups
|
||||
|
||||
pids(Ets, Name) ->
|
||||
case ets:lookup(Ets, {group, Name}) of
|
||||
[{_,L}] -> L;
|
||||
[] -> []
|
||||
end.
|
||||
|
||||
facts(Ets, Pid) ->
|
||||
case ets:lookup(Ets, {facts, Pid}) of
|
||||
[{_,L}] -> L;
|
||||
[] -> []
|
||||
end.
|
||||
|
||||
manager_rpc({join, Pid, Group}, Ets) ->
|
||||
%% Nick (Pid) joins the group G
|
||||
{Nick, Gs} = facts(Ets, Pid),
|
||||
case member(Group, Gs) of
|
||||
true -> {ok, Ets};
|
||||
false ->
|
||||
ets:insert(Ets, {{facts, Pid}, {Nick,[Group|Gs]}}),
|
||||
Pids = [Pid|pids(Ets, Group)],
|
||||
ets:insert(Ets, {{group,Group}, Pids}),
|
||||
broadcast_to_group(Pids, {joins, s(Nick), s(Group)}),
|
||||
{ok, Ets}
|
||||
end;
|
||||
manager_rpc({leave, Pid, Group}, Ets) ->
|
||||
{Nick, Gs} = facts(Ets, Pid),
|
||||
case member(Group, Gs) of
|
||||
false -> {ok, Ets};
|
||||
true ->
|
||||
ets:insert(Ets, {{facts, Pid}, {Nick,delete(Group, Gs)}}),
|
||||
Pids = delete(Pid, pids(Ets, Group)),
|
||||
ets:insert(Ets, {{group,Group}, Pids}),
|
||||
broadcast_to_group(Pids, {leaves, s(Nick), s(Group)}),
|
||||
{ok, Ets}
|
||||
end;
|
||||
manager_rpc({msg, Pid, Group, Msg}, Ets) ->
|
||||
{Nick, Gs} = facts(Ets, Pid),
|
||||
case member(Group, Gs) of
|
||||
false -> {notJoined, Ets};
|
||||
true ->
|
||||
broadcast_to_group(pids(Ets, Group),
|
||||
{msg, s(Nick), s(Group), s(Msg)}),
|
||||
{ok, Ets}
|
||||
end;
|
||||
manager_rpc(groups, Ets) ->
|
||||
M = ets:match(Ets, {{group,'$1'},'_'}),
|
||||
io:format("Here Groups=~p~n",[M]),
|
||||
Strs = map(fun([I]) -> s(I) end, M),
|
||||
{Strs, Ets};
|
||||
manager_rpc(P={logon, Pid}, Ets) ->
|
||||
Nick = random_nick(6),
|
||||
case ets:lookup(Ets, {pid, Nick}) of
|
||||
[] ->
|
||||
ets:insert(Ets, {{pid, Nick}, Pid}),
|
||||
ets:insert(Ets, {{facts,Pid}, {Nick, []}}),
|
||||
{Nick, Ets};
|
||||
_ ->
|
||||
manager_rpc(P, Ets)
|
||||
end;
|
||||
manager_rpc({change_nick,Old,New,Pid}, Ets) ->
|
||||
case ets:lookup(Ets, {pid, New}) of
|
||||
[] ->
|
||||
ets:insert(Ets, {{pid, New}, Pid}),
|
||||
ets:delete(Ets, {pid,Old}),
|
||||
{_, Groups} = facts(Ets, Pid),
|
||||
ets:insert(Ets, {{facts,Pid},{New, Groups}}),
|
||||
%% Now tell all groups about the name change
|
||||
foreach(fun(G) ->
|
||||
Pids = pids(Ets, G),
|
||||
broadcast_to_group(Pids, {changesName,
|
||||
s(Old), s(New),
|
||||
s(G)})
|
||||
end, Groups),
|
||||
{ok, Ets};
|
||||
_ ->
|
||||
{error, Ets}
|
||||
end.
|
||||
|
||||
broadcast_to_group(L, Msg) ->
|
||||
foreach(fun(Pid) -> sendEvent(Pid, Msg) end, L).
|
||||
|
||||
handle_rpc(start, logon, State, Manager) ->
|
||||
R = ask_manager(Manager, {logon, self()}),
|
||||
{{ok, s(R)}, active, R};
|
||||
handle_rpc(active, {join, ?S(Group)}, Nick, Manager) ->
|
||||
ask_manager(Manager, {join, self(), Group}),
|
||||
{ok, active, Nick};
|
||||
handle_rpc(active, {leave, ?S(Group)}, Nick, Manager) ->
|
||||
ask_manager(Manager, {leave, self(), Group}),
|
||||
{ok, active, Nick};
|
||||
handle_rpc(active, {msg, ?S(Group), ?S(Msg)}, Nick, Manager) ->
|
||||
ask_manager(Manager, {msg, self(), Group, Msg}),
|
||||
{ok, active, Nick};
|
||||
handle_rpc(active, {nick, ?S(New)}, Nick, Manager) ->
|
||||
case ask_manager(Manager, {change_nick,Nick,New,self()}) of
|
||||
ok ->
|
||||
{nickChanged, active, New};
|
||||
error ->
|
||||
{nickInUse, active, Nick}
|
||||
end;
|
||||
handle_rpc(active, groups, Nick, Manager) ->
|
||||
Groups = ask_manager(Manager, groups),
|
||||
{Groups, active, Nick}.
|
||||
|
||||
random_nick(0) ->
|
||||
[];
|
||||
random_nick(N) ->
|
||||
[$a + random:uniform(26) - 1|random_nick(N-1)].
|
||||
|
||||
new_seed() ->
|
||||
{_,_,X} = erlang:now(),
|
||||
{H,M,S} = time(),
|
||||
H1 = H * X rem 32767,
|
||||
M1 = M * X rem 32767,
|
||||
S1 = S * X rem 32767,
|
||||
put(random_seed, {H1,M1,S1}).
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
2
Makefile
2
Makefile
@@ -12,7 +12,7 @@
|
||||
ERL = ubf proc_socket_server find server\
|
||||
test ubf_driver ubf_test file_client\
|
||||
contracts contract_manager client plugin_handler\
|
||||
leex contract_lex contract_yecc irc_client ubf_utils
|
||||
leex contract_lex contract_yecc irc_client irc_client_gs ubf_utils
|
||||
|
||||
PLUGINS = test_plugin file_plugin irc_plugin server_plugin
|
||||
|
||||
|
||||
68
ball.erl
68
ball.erl
@@ -1,68 +0,0 @@
|
||||
%% ``The contents of this file are subject to the Erlang Public License,
|
||||
%% Version 1.1, (the "License"); you may not use this file except in
|
||||
%% compliance with the License. You should have received a copy of the
|
||||
%% Erlang Public License along with this software. If not, it can be
|
||||
%% retrieved via the world wide web at http://www.erlang.org/.
|
||||
%%
|
||||
%% Software distributed under the License is distributed on an "AS IS"
|
||||
%% basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See
|
||||
%% the License for the specific language governing rights and limitations
|
||||
%% under the License.
|
||||
%%
|
||||
%% The Initial Developer of the Original Code is Ericsson Utvecklings AB.
|
||||
%% Portions created by Ericsson are Copyright 1999, Ericsson Utvecklings
|
||||
%% AB. All Rights Reserved.''
|
||||
%%
|
||||
%% $Id$
|
||||
%%
|
||||
%% ------------------------------------------------------------
|
||||
%% A simple demo showing a ball
|
||||
%% bouncing in a window.
|
||||
%% ------------------------------------------------------------
|
||||
|
||||
-module(ball).
|
||||
|
||||
-export([start/0,init/0]).
|
||||
|
||||
start() ->
|
||||
spawn(ball,init,[]).
|
||||
|
||||
init() ->
|
||||
I= gs:start(),
|
||||
W= gs:window(I,[{title,"Ball"},{width,300},{height,300},{map,true}]),
|
||||
C= gs:canvas(W,[{width,300},{height,300},{bg,yellow}]),
|
||||
B= gs:button(W,[{label, {text,"Quit Demo"}},{x,100}]),
|
||||
Ball = gs:oval(C,[{coords,[{0,0},{50,50}]},{fill,red}]),
|
||||
ball(Ball,0,0,5.5,4.1).
|
||||
|
||||
ball(Ball,X,Y,DX,DY) ->
|
||||
{NX,NDX} = cc(X,DX),
|
||||
{NY,NDY} = cc(Y,DY),
|
||||
gs:config(Ball,{move,{DX,DY}}),
|
||||
receive
|
||||
{gs,Id,click,_,_} -> exit(normal);
|
||||
{gs,_,destroy,_,_} -> exit(normal)
|
||||
after 20 ->
|
||||
true
|
||||
end,
|
||||
ball(Ball,NX,NY,NDX,NDY).
|
||||
|
||||
cc(X,DX) ->
|
||||
if
|
||||
DX>0 ->
|
||||
if
|
||||
X=<250 ->
|
||||
{X+DX,DX};
|
||||
x>250 ->
|
||||
{X-DX,-DX}
|
||||
end;
|
||||
DX<0 ->
|
||||
if
|
||||
X>=0 ->
|
||||
{X+DX,DX};
|
||||
X<0 ->
|
||||
{X-DX,-DX}
|
||||
end
|
||||
end.
|
||||
|
||||
%% ------------------------------------------------------------
|
||||
BIN
client.beam
BIN
client.beam
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
BIN
contracts.beam
BIN
contracts.beam
Binary file not shown.
171
doc/site/downloads.html
Normal file
171
doc/site/downloads.html
Normal file
@@ -0,0 +1,171 @@
|
||||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
||||
<HTML>
|
||||
<HEAD>
|
||||
<META HTTP-EQUIV='Content-Type' CONTENT='text/html; charset=iso-8859-1'>
|
||||
<TITLE>Site</TITLE>
|
||||
</HEAD>
|
||||
<BODY TEXT='#222222' BGCOLOR='#DDDDDD'
|
||||
TOPMARGIN='0' LEFTMARGIN='0' MARGINWIDTH='10'
|
||||
MARGINHEIGHT='0'><p>
|
||||
<table>
|
||||
<tr>
|
||||
<td valign='top' width='15%'>
|
||||
<TABLE BORDER=0 CELLSPACING=0 CELLPADDING=0 WIDTH='100%' >
|
||||
<TR VALIGN=TOP BGCOLOR='#cc000000'>
|
||||
<TD BGCOLOR='#DDDDDD'><IMG SRC='../images/pix.gif' ALT='' HEIGHT=3 WIDTH=3></TD>
|
||||
<TD><IMG SRC='../images/cl.png' ALT='' HEIGHT=10 WIDTH=7></TD>
|
||||
<TD><B><FONT FACE='verdana,helvetica,arial'><FONT
|
||||
COLOR='#FFFFFF'><FONT
|
||||
SIZE=-1>Documents</FONT></FONT></FONT></B></TD>
|
||||
<TD ALIGN=RIGHT><IMG SRC='../images/cr.png' ALT='' HEIGHT=10 WIDTH=7></TD>
|
||||
<TD ALIGN=RIGHT BGCOLOR='#DDDDDD'><IMG SRC='../images/pix.gif' ALT='' HEIGHT=3 WIDTH=3></TD>
|
||||
</TR>
|
||||
</TABLE>
|
||||
<TABLE BORDER=0 CELLSPACING=0 CELLPADDING=0 WIDTH='100%' >
|
||||
<TR BGCOLOR='#cc000000'>
|
||||
<TD COLSPAN='3'><IMG SRC='../images/pix.gif' HEIGHT=1 WIDTH=1 ALT=''></TD>
|
||||
</TR>
|
||||
<TR BGCOLOR='#FFFFFF'>
|
||||
<TD BACKGROUND='../images/sl.png'><IMG SRC='../images/pix.gif' ALT='' HEIGHT=3 WIDTH=3></TD>
|
||||
<TD WIDTH='100%'>
|
||||
<TABLE BORDER=0 CELLSPACING=0 CELLPADDING=5 WIDTH='100%' >
|
||||
<TR><TD>
|
||||
<a href="home.html">Home</a>
|
||||
<br><a href="white.html">White paper</a>
|
||||
<br><a href="ubfa.html">UBF(A) spec</a>
|
||||
<br><a href="ubfb.html">UBF(B) spec</a>
|
||||
</TD></TR>
|
||||
</TABLE>
|
||||
</TD>
|
||||
<TD ALIGN=RIGHT BACKGROUND='../images/sr.png'><IMG SRC='../images/pix.gif' ALT='' HEIGHT=3 WIDTH=3></TD>
|
||||
</TR>
|
||||
<TR>
|
||||
<TD COLSPAN='3' BGCOLOR='#cc000000'><IMG SRC='../images/pix.gif' HEIGHT=1 WIDTH=1 ALT=''></TD>
|
||||
</TR>
|
||||
</TABLE>
|
||||
<p>
|
||||
<TABLE BORDER=0 CELLSPACING=0 CELLPADDING=0 WIDTH='100%' >
|
||||
<TR VALIGN=TOP BGCOLOR='#cc000000'>
|
||||
<TD BGCOLOR='#DDDDDD'><IMG SRC='../images/pix.gif' ALT='' HEIGHT=3 WIDTH=3></TD>
|
||||
<TD><IMG SRC='../images/cl.png' ALT='' HEIGHT=10 WIDTH=7></TD>
|
||||
<TD><B><FONT FACE='verdana,helvetica,arial'><FONT
|
||||
COLOR='#FFFFFF'><FONT
|
||||
SIZE=-1>Tutorials</FONT></FONT></FONT></B></TD>
|
||||
<TD ALIGN=RIGHT><IMG SRC='../images/cr.png' ALT='' HEIGHT=10 WIDTH=7></TD>
|
||||
<TD ALIGN=RIGHT BGCOLOR='#DDDDDD'><IMG SRC='../images/pix.gif' ALT='' HEIGHT=3 WIDTH=3></TD>
|
||||
</TR>
|
||||
</TABLE>
|
||||
<TABLE BORDER=0 CELLSPACING=0 CELLPADDING=0 WIDTH='100%' >
|
||||
<TR BGCOLOR='#cc000000'>
|
||||
<TD COLSPAN='3'><IMG SRC='../images/pix.gif' HEIGHT=1 WIDTH=1 ALT=''></TD>
|
||||
</TR>
|
||||
<TR BGCOLOR='#FFFFFF'>
|
||||
<TD BACKGROUND='../images/sl.png'><IMG SRC='../images/pix.gif' ALT='' HEIGHT=3 WIDTH=3></TD>
|
||||
<TD WIDTH='100%'>
|
||||
<TABLE BORDER=0 CELLSPACING=0 CELLPADDING=5 WIDTH='100%' >
|
||||
<TR><TD>
|
||||
<a href="quick.html">Quick start</a>
|
||||
<br><a href="eserve.html">Erlang servers</a>
|
||||
<br><a href="javac.html">Java clients</a>
|
||||
</TD></TR>
|
||||
</TABLE>
|
||||
</TD>
|
||||
<TD ALIGN=RIGHT BACKGROUND='../images/sr.png'><IMG SRC='../images/pix.gif' ALT='' HEIGHT=3 WIDTH=3></TD>
|
||||
</TR>
|
||||
<TR>
|
||||
<TD COLSPAN='3' BGCOLOR='#cc000000'><IMG SRC='../images/pix.gif' HEIGHT=1 WIDTH=1 ALT=''></TD>
|
||||
</TR>
|
||||
</TABLE>
|
||||
<p>
|
||||
<TABLE BORDER=0 CELLSPACING=0 CELLPADDING=0 WIDTH='100%' >
|
||||
<TR VALIGN=TOP BGCOLOR='#cc000000'>
|
||||
<TD BGCOLOR='#DDDDDD'><IMG SRC='../images/pix.gif' ALT='' HEIGHT=3 WIDTH=3></TD>
|
||||
<TD><IMG SRC='../images/cl.png' ALT='' HEIGHT=10 WIDTH=7></TD>
|
||||
<TD><B><FONT FACE='verdana,helvetica,arial'><FONT
|
||||
COLOR='#FFFFFF'><FONT
|
||||
SIZE=-1>Services</FONT></FONT></FONT></B></TD>
|
||||
<TD ALIGN=RIGHT><IMG SRC='../images/cr.png' ALT='' HEIGHT=10 WIDTH=7></TD>
|
||||
<TD ALIGN=RIGHT BGCOLOR='#DDDDDD'><IMG SRC='../images/pix.gif' ALT='' HEIGHT=3 WIDTH=3></TD>
|
||||
</TR>
|
||||
</TABLE>
|
||||
<TABLE BORDER=0 CELLSPACING=0 CELLPADDING=0 WIDTH='100%' >
|
||||
<TR BGCOLOR='#cc000000'>
|
||||
<TD COLSPAN='3'><IMG SRC='../images/pix.gif' HEIGHT=1 WIDTH=1 ALT=''></TD>
|
||||
</TR>
|
||||
<TR BGCOLOR='#FFFFFF'>
|
||||
<TD BACKGROUND='../images/sl.png'><IMG SRC='../images/pix.gif' ALT='' HEIGHT=3 WIDTH=3></TD>
|
||||
<TD WIDTH='100%'>
|
||||
<TABLE BORDER=0 CELLSPACING=0 CELLPADDING=5 WIDTH='100%' >
|
||||
<TR><TD>
|
||||
<a href="irc.html">IRC</a>
|
||||
<br><a href="messagebox.html">Message Box</a>
|
||||
<br><a href="file.html">File server</a>
|
||||
</TD></TR>
|
||||
</TABLE>
|
||||
</TD>
|
||||
<TD ALIGN=RIGHT BACKGROUND='../images/sr.png'><IMG SRC='../images/pix.gif' ALT='' HEIGHT=3 WIDTH=3></TD>
|
||||
</TR>
|
||||
<TR>
|
||||
<TD COLSPAN='3' BGCOLOR='#cc000000'><IMG SRC='../images/pix.gif' HEIGHT=1 WIDTH=1 ALT=''></TD>
|
||||
</TR>
|
||||
</TABLE>
|
||||
<p>
|
||||
<TABLE BORDER=0 CELLSPACING=0 CELLPADDING=0 WIDTH='100%' >
|
||||
<TR VALIGN=TOP BGCOLOR='#cc000000'>
|
||||
<TD BGCOLOR='#DDDDDD'><IMG SRC='../images/pix.gif' ALT='' HEIGHT=3 WIDTH=3></TD>
|
||||
<TD><IMG SRC='../images/cl.png' ALT='' HEIGHT=10 WIDTH=7></TD>
|
||||
<TD><B><FONT FACE='verdana,helvetica,arial'><FONT
|
||||
COLOR='#FFFFFF'><FONT
|
||||
SIZE=-1>Downloads</FONT></FONT></FONT></B></TD>
|
||||
<TD ALIGN=RIGHT><IMG SRC='../images/cr.png' ALT='' HEIGHT=10 WIDTH=7></TD>
|
||||
<TD ALIGN=RIGHT BGCOLOR='#DDDDDD'><IMG SRC='../images/pix.gif' ALT='' HEIGHT=3 WIDTH=3></TD>
|
||||
</TR>
|
||||
</TABLE>
|
||||
<TABLE BORDER=0 CELLSPACING=0 CELLPADDING=0 WIDTH='100%' >
|
||||
<TR BGCOLOR='#cc000000'>
|
||||
<TD COLSPAN='3'><IMG SRC='../images/pix.gif' HEIGHT=1 WIDTH=1 ALT=''></TD>
|
||||
</TR>
|
||||
<TR BGCOLOR='#FFFFFF'>
|
||||
<TD BACKGROUND='../images/sl.png'><IMG SRC='../images/pix.gif' ALT='' HEIGHT=3 WIDTH=3></TD>
|
||||
<TD WIDTH='100%'>
|
||||
<TABLE BORDER=0 CELLSPACING=0 CELLPADDING=5 WIDTH='100%' >
|
||||
<TR><TD>
|
||||
<a href="downloads.html">Downloads</a>
|
||||
</TD></TR>
|
||||
</TABLE>
|
||||
</TD>
|
||||
<TD ALIGN=RIGHT BACKGROUND='../images/sr.png'><IMG SRC='../images/pix.gif' ALT='' HEIGHT=3 WIDTH=3></TD>
|
||||
</TR>
|
||||
<TR>
|
||||
<TD COLSPAN='3' BGCOLOR='#cc000000'><IMG SRC='../images/pix.gif' HEIGHT=1 WIDTH=1 ALT=''></TD>
|
||||
</TR>
|
||||
</TABLE>
|
||||
<p>
|
||||
<p>
|
||||
</td>
|
||||
<td valign='top'>
|
||||
<TABLE BORDER=0 CELLSPACING=0 CELLPADDING=0 WIDTH='100%'> <TR VALIGN=TOP><TD BGCOLOR='#cc0000'><IMG SRC='../images/cl.png' ALT='' HEIGHT=10 WIDTH=7><IMG SRC='../images/pix.gif' ALT='' HEIGHT=4 WIDTH=4></TD>
|
||||
<TD WIDTH='100%' BGCOLOR='#cc0000'> <TABLE BORDER=0 CELLSPACING=0 CELLPADDING=2 WIDTH='100%' > <TR> <TD BGCOLOR='#cc0000'><B><FONT FACE='verdana,helvetica,arial'><FONT COLOR='#FFFFFF'><FONT SIZE='+0'>UBF(B)</FONT></FONT></FONT></B></TD></TR></TABLE></TD>
|
||||
<TD ALIGN=RIGHT BGCOLOR='#cc0000'><IMG SRC='../images/cr.png' ALT='' HEIGHT=10 WIDTH=7></TD></TR></TABLE>
|
||||
<TABLE BORDER=0 CELLSPACING=0 CELLPADDING=0 WIDTH='100%' ><TR><TD BACKGROUND='../images/gl.png'><IMG SRC='../images/pix.gif' ALT='' HEIGHT=11 WIDTH=11></TD>
|
||||
<TD WIDTH='100%' BGCOLOR='#cc0000'><TABLE BORDER=0 CELLSPACING=0 CELLPADDING=5 WIDTH='100%' ><TR><TD BGCOLOR='#E6E6E6'><FONT FACE='verdana,helvetica,arial'><FONT SIZE=-2>2002-03-05</FONT></FONT></TD></TR></TABLE></TD>
|
||||
<TD BACKGROUND='../images/gr.png'><IMG SRC='../images/pix.gif' ALT='' HEIGHT=11 WIDTH=11></TD></TR><TR><TD COLSPAN='3' BGCOLOR='#006666'><IMG SRC='../images/pix.gif' HEIGHT=1 WIDTH=1 ALT=''></TD></TR>
|
||||
<TR><TD BACKGROUND='../images/wl.png'><IMG SRC='../images/pix.gif' ALT='' HEIGHT=11 WIDTH=11></TD><TD WIDTH='100%' BGCOLOR='#FFFFFF'><TABLE BORDER=0 CELLSPACING=0 CELLPADDING=5 WIDTH='100%' ><TR><TD BGCOLOR='#FFFFFF'>
|
||||
<h3>Downloads</h3>
|
||||
<ul>
|
||||
<li><a href="../downloads">Download directory<a>
|
||||
</ul>
|
||||
</TD>
|
||||
</TR></TABLE></TD><TD BACKGROUND='../images/wr.png'><IMG SRC='../images/pix.gif' ALT='' HEIGHT=11 WIDTH=11></TD></TR>
|
||||
<TR BGCOLOR='#cc0000'><TD COLSPAN='3'><IMG SRC='../images/pix.gif' HEIGHT=1 WIDTH=1 ALT=''></TD></TR></TABLE><TABLE BORDER=0 CELLSPACING=0 CELLPADDING=0 WIDTH='100%'>
|
||||
<TR><TD BACKGROUND='../images/wl_cccccc.png'><IMG SRC='../images/pix.gif' ALT='' HEIGHT=11 WIDTH=11></TD><TD WIDTH='100%' BGCOLOR='#FFFFFF'>
|
||||
<TABLE BORDER=0 CELLSPACING=0 CELLPADDING=5 WIDTH='100%' ><TR><TD BGCOLOR='#CCCCCC'><B><FONT FACE='verdana,helvetica,arial'><FONT SIZE=-1>(
|
||||
<A HREF=''></A>
|
||||
)</FONT></FONT></B></TD></TR></TABLE></TD><TD BACKGROUND='../images/wr_cccccc.png'><IMG SRC='../images/pix.gif' ALT='' HEIGHT=11 WIDTH=11></TD></TR>
|
||||
<TR><TD COLSPAN='3' BGCOLOR='#cc0000'><IMG SRC='../images/pix.gif' HEIGHT=1
|
||||
WIDTH=1 ALT=''></TD></TR></TABLE>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</body>
|
||||
</html>
|
||||
233
doc/site/eserve.html
Normal file
233
doc/site/eserve.html
Normal file
@@ -0,0 +1,233 @@
|
||||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
||||
<HTML>
|
||||
<HEAD>
|
||||
<META HTTP-EQUIV='Content-Type' CONTENT='text/html; charset=iso-8859-1'>
|
||||
<TITLE>Site</TITLE>
|
||||
</HEAD>
|
||||
<BODY TEXT='#222222' BGCOLOR='#DDDDDD'
|
||||
TOPMARGIN='0' LEFTMARGIN='0' MARGINWIDTH='10'
|
||||
MARGINHEIGHT='0'><p>
|
||||
<table>
|
||||
<tr>
|
||||
<td valign='top' width='15%'>
|
||||
<TABLE BORDER=0 CELLSPACING=0 CELLPADDING=0 WIDTH='100%' >
|
||||
<TR VALIGN=TOP BGCOLOR='#cc000000'>
|
||||
<TD BGCOLOR='#DDDDDD'><IMG SRC='../images/pix.gif' ALT='' HEIGHT=3 WIDTH=3></TD>
|
||||
<TD><IMG SRC='../images/cl.png' ALT='' HEIGHT=10 WIDTH=7></TD>
|
||||
<TD><B><FONT FACE='verdana,helvetica,arial'><FONT
|
||||
COLOR='#FFFFFF'><FONT
|
||||
SIZE=-1>Documents</FONT></FONT></FONT></B></TD>
|
||||
<TD ALIGN=RIGHT><IMG SRC='../images/cr.png' ALT='' HEIGHT=10 WIDTH=7></TD>
|
||||
<TD ALIGN=RIGHT BGCOLOR='#DDDDDD'><IMG SRC='../images/pix.gif' ALT='' HEIGHT=3 WIDTH=3></TD>
|
||||
</TR>
|
||||
</TABLE>
|
||||
<TABLE BORDER=0 CELLSPACING=0 CELLPADDING=0 WIDTH='100%' >
|
||||
<TR BGCOLOR='#cc000000'>
|
||||
<TD COLSPAN='3'><IMG SRC='../images/pix.gif' HEIGHT=1 WIDTH=1 ALT=''></TD>
|
||||
</TR>
|
||||
<TR BGCOLOR='#FFFFFF'>
|
||||
<TD BACKGROUND='../images/sl.png'><IMG SRC='../images/pix.gif' ALT='' HEIGHT=3 WIDTH=3></TD>
|
||||
<TD WIDTH='100%'>
|
||||
<TABLE BORDER=0 CELLSPACING=0 CELLPADDING=5 WIDTH='100%' >
|
||||
<TR><TD>
|
||||
<a href="home.html">Home</a>
|
||||
<br><a href="white.html">White paper</a>
|
||||
<br><a href="ubfa.html">UBF(A) spec</a>
|
||||
<br><a href="ubfb.html">UBF(B) spec</a>
|
||||
</TD></TR>
|
||||
</TABLE>
|
||||
</TD>
|
||||
<TD ALIGN=RIGHT BACKGROUND='../images/sr.png'><IMG SRC='../images/pix.gif' ALT='' HEIGHT=3 WIDTH=3></TD>
|
||||
</TR>
|
||||
<TR>
|
||||
<TD COLSPAN='3' BGCOLOR='#cc000000'><IMG SRC='../images/pix.gif' HEIGHT=1 WIDTH=1 ALT=''></TD>
|
||||
</TR>
|
||||
</TABLE>
|
||||
<p>
|
||||
<TABLE BORDER=0 CELLSPACING=0 CELLPADDING=0 WIDTH='100%' >
|
||||
<TR VALIGN=TOP BGCOLOR='#cc000000'>
|
||||
<TD BGCOLOR='#DDDDDD'><IMG SRC='../images/pix.gif' ALT='' HEIGHT=3 WIDTH=3></TD>
|
||||
<TD><IMG SRC='../images/cl.png' ALT='' HEIGHT=10 WIDTH=7></TD>
|
||||
<TD><B><FONT FACE='verdana,helvetica,arial'><FONT
|
||||
COLOR='#FFFFFF'><FONT
|
||||
SIZE=-1>Tutorials</FONT></FONT></FONT></B></TD>
|
||||
<TD ALIGN=RIGHT><IMG SRC='../images/cr.png' ALT='' HEIGHT=10 WIDTH=7></TD>
|
||||
<TD ALIGN=RIGHT BGCOLOR='#DDDDDD'><IMG SRC='../images/pix.gif' ALT='' HEIGHT=3 WIDTH=3></TD>
|
||||
</TR>
|
||||
</TABLE>
|
||||
<TABLE BORDER=0 CELLSPACING=0 CELLPADDING=0 WIDTH='100%' >
|
||||
<TR BGCOLOR='#cc000000'>
|
||||
<TD COLSPAN='3'><IMG SRC='../images/pix.gif' HEIGHT=1 WIDTH=1 ALT=''></TD>
|
||||
</TR>
|
||||
<TR BGCOLOR='#FFFFFF'>
|
||||
<TD BACKGROUND='../images/sl.png'><IMG SRC='../images/pix.gif' ALT='' HEIGHT=3 WIDTH=3></TD>
|
||||
<TD WIDTH='100%'>
|
||||
<TABLE BORDER=0 CELLSPACING=0 CELLPADDING=5 WIDTH='100%' >
|
||||
<TR><TD>
|
||||
<a href="quick.html">Quick start</a>
|
||||
<br><a href="eserve.html">Erlang servers</a>
|
||||
<br><a href="javac.html">Java clients</a>
|
||||
</TD></TR>
|
||||
</TABLE>
|
||||
</TD>
|
||||
<TD ALIGN=RIGHT BACKGROUND='../images/sr.png'><IMG SRC='../images/pix.gif' ALT='' HEIGHT=3 WIDTH=3></TD>
|
||||
</TR>
|
||||
<TR>
|
||||
<TD COLSPAN='3' BGCOLOR='#cc000000'><IMG SRC='../images/pix.gif' HEIGHT=1 WIDTH=1 ALT=''></TD>
|
||||
</TR>
|
||||
</TABLE>
|
||||
<p>
|
||||
<TABLE BORDER=0 CELLSPACING=0 CELLPADDING=0 WIDTH='100%' >
|
||||
<TR VALIGN=TOP BGCOLOR='#cc000000'>
|
||||
<TD BGCOLOR='#DDDDDD'><IMG SRC='../images/pix.gif' ALT='' HEIGHT=3 WIDTH=3></TD>
|
||||
<TD><IMG SRC='../images/cl.png' ALT='' HEIGHT=10 WIDTH=7></TD>
|
||||
<TD><B><FONT FACE='verdana,helvetica,arial'><FONT
|
||||
COLOR='#FFFFFF'><FONT
|
||||
SIZE=-1>Services</FONT></FONT></FONT></B></TD>
|
||||
<TD ALIGN=RIGHT><IMG SRC='../images/cr.png' ALT='' HEIGHT=10 WIDTH=7></TD>
|
||||
<TD ALIGN=RIGHT BGCOLOR='#DDDDDD'><IMG SRC='../images/pix.gif' ALT='' HEIGHT=3 WIDTH=3></TD>
|
||||
</TR>
|
||||
</TABLE>
|
||||
<TABLE BORDER=0 CELLSPACING=0 CELLPADDING=0 WIDTH='100%' >
|
||||
<TR BGCOLOR='#cc000000'>
|
||||
<TD COLSPAN='3'><IMG SRC='../images/pix.gif' HEIGHT=1 WIDTH=1 ALT=''></TD>
|
||||
</TR>
|
||||
<TR BGCOLOR='#FFFFFF'>
|
||||
<TD BACKGROUND='../images/sl.png'><IMG SRC='../images/pix.gif' ALT='' HEIGHT=3 WIDTH=3></TD>
|
||||
<TD WIDTH='100%'>
|
||||
<TABLE BORDER=0 CELLSPACING=0 CELLPADDING=5 WIDTH='100%' >
|
||||
<TR><TD>
|
||||
<a href="irc.html">IRC</a>
|
||||
<br><a href="messagebox.html">Message Box</a>
|
||||
<br><a href="file.html">File server</a>
|
||||
</TD></TR>
|
||||
</TABLE>
|
||||
</TD>
|
||||
<TD ALIGN=RIGHT BACKGROUND='../images/sr.png'><IMG SRC='../images/pix.gif' ALT='' HEIGHT=3 WIDTH=3></TD>
|
||||
</TR>
|
||||
<TR>
|
||||
<TD COLSPAN='3' BGCOLOR='#cc000000'><IMG SRC='../images/pix.gif' HEIGHT=1 WIDTH=1 ALT=''></TD>
|
||||
</TR>
|
||||
</TABLE>
|
||||
<p>
|
||||
<TABLE BORDER=0 CELLSPACING=0 CELLPADDING=0 WIDTH='100%' >
|
||||
<TR VALIGN=TOP BGCOLOR='#cc000000'>
|
||||
<TD BGCOLOR='#DDDDDD'><IMG SRC='../images/pix.gif' ALT='' HEIGHT=3 WIDTH=3></TD>
|
||||
<TD><IMG SRC='../images/cl.png' ALT='' HEIGHT=10 WIDTH=7></TD>
|
||||
<TD><B><FONT FACE='verdana,helvetica,arial'><FONT
|
||||
COLOR='#FFFFFF'><FONT
|
||||
SIZE=-1>Downloads</FONT></FONT></FONT></B></TD>
|
||||
<TD ALIGN=RIGHT><IMG SRC='../images/cr.png' ALT='' HEIGHT=10 WIDTH=7></TD>
|
||||
<TD ALIGN=RIGHT BGCOLOR='#DDDDDD'><IMG SRC='../images/pix.gif' ALT='' HEIGHT=3 WIDTH=3></TD>
|
||||
</TR>
|
||||
</TABLE>
|
||||
<TABLE BORDER=0 CELLSPACING=0 CELLPADDING=0 WIDTH='100%' >
|
||||
<TR BGCOLOR='#cc000000'>
|
||||
<TD COLSPAN='3'><IMG SRC='../images/pix.gif' HEIGHT=1 WIDTH=1 ALT=''></TD>
|
||||
</TR>
|
||||
<TR BGCOLOR='#FFFFFF'>
|
||||
<TD BACKGROUND='../images/sl.png'><IMG SRC='../images/pix.gif' ALT='' HEIGHT=3 WIDTH=3></TD>
|
||||
<TD WIDTH='100%'>
|
||||
<TABLE BORDER=0 CELLSPACING=0 CELLPADDING=5 WIDTH='100%' >
|
||||
<TR><TD>
|
||||
<a href="downloads.html">Downloads</a>
|
||||
</TD></TR>
|
||||
</TABLE>
|
||||
</TD>
|
||||
<TD ALIGN=RIGHT BACKGROUND='../images/sr.png'><IMG SRC='../images/pix.gif' ALT='' HEIGHT=3 WIDTH=3></TD>
|
||||
</TR>
|
||||
<TR>
|
||||
<TD COLSPAN='3' BGCOLOR='#cc000000'><IMG SRC='../images/pix.gif' HEIGHT=1 WIDTH=1 ALT=''></TD>
|
||||
</TR>
|
||||
</TABLE>
|
||||
<p>
|
||||
<p>
|
||||
</td>
|
||||
<td valign='top'>
|
||||
<TABLE BORDER=0 CELLSPACING=0 CELLPADDING=0 WIDTH='100%'> <TR VALIGN=TOP><TD BGCOLOR='#cc0000'><IMG SRC='../images/cl.png' ALT='' HEIGHT=10 WIDTH=7><IMG SRC='../images/pix.gif' ALT='' HEIGHT=4 WIDTH=4></TD>
|
||||
<TD WIDTH='100%' BGCOLOR='#cc0000'> <TABLE BORDER=0 CELLSPACING=0 CELLPADDING=2 WIDTH='100%' > <TR> <TD BGCOLOR='#cc0000'><B><FONT FACE='verdana,helvetica,arial'><FONT COLOR='#FFFFFF'><FONT SIZE='+0'>Quick start</FONT></FONT></FONT></B></TD></TR></TABLE></TD>
|
||||
<TD ALIGN=RIGHT BGCOLOR='#cc0000'><IMG SRC='../images/cr.png' ALT='' HEIGHT=10 WIDTH=7></TD></TR></TABLE>
|
||||
<TABLE BORDER=0 CELLSPACING=0 CELLPADDING=0 WIDTH='100%' ><TR><TD BACKGROUND='../images/gl.png'><IMG SRC='../images/pix.gif' ALT='' HEIGHT=11 WIDTH=11></TD>
|
||||
<TD WIDTH='100%' BGCOLOR='#cc0000'><TABLE BORDER=0 CELLSPACING=0 CELLPADDING=5 WIDTH='100%' ><TR><TD BGCOLOR='#E6E6E6'><FONT FACE='verdana,helvetica,arial'><FONT SIZE=-2>2002-03-05</FONT></FONT></TD></TR></TABLE></TD>
|
||||
<TD BACKGROUND='../images/gr.png'><IMG SRC='../images/pix.gif' ALT='' HEIGHT=11 WIDTH=11></TD></TR><TR><TD COLSPAN='3' BGCOLOR='#006666'><IMG SRC='../images/pix.gif' HEIGHT=1 WIDTH=1 ALT=''></TD></TR>
|
||||
<TR><TD BACKGROUND='../images/wl.png'><IMG SRC='../images/pix.gif' ALT='' HEIGHT=11 WIDTH=11></TD><TD WIDTH='100%' BGCOLOR='#FFFFFF'><TABLE BORDER=0 CELLSPACING=0 CELLPADDING=5 WIDTH='100%' ><TR><TD BGCOLOR='#FFFFFF'>
|
||||
<TABLE BGCOLOR=#ccccff WIDTH=100% BORDER=1 BORDERCOLOR=#0000ff>
|
||||
<TR>
|
||||
<TD><b>Erlang servers</B></TD></TR></TABLE>
|
||||
<p>an example of a server plugin
|
||||
<p><TABLE BORDER=2><tr><td><pre>-module(file_plugin).
|
||||
|
||||
-export([manager_start/2, client_stop/3,
|
||||
managerStartState/0, handlerStartState/0,
|
||||
manager_rpc/2, handle_rpc/4]).
|
||||
|
||||
-import(lists, [map/2, member/2]).
|
||||
|
||||
%% NOTE the following two lines
|
||||
|
||||
-compile({parse_transform,contract_parser}).
|
||||
-add_contract("file_plugin").
|
||||
|
||||
-define(S(X), {'#S',X}).
|
||||
s(X) -> {'#S', X}.
|
||||
|
||||
%% The initial state of the manager
|
||||
|
||||
managerStartState() -> myManagerState.
|
||||
|
||||
handlerStartState() -> myHandlerState.
|
||||
|
||||
%% manager_start(Args, State) is called every time a session is started
|
||||
%% Args comes from client:start(Host,Port,Service,Args)
|
||||
%% Service in the rcp:start must match name()
|
||||
%% manager_start(Args, State) -> {accept, Reply, State} | {reject, Why, State}
|
||||
%% State is the manager state.
|
||||
|
||||
manager_start(_, ManagerState) ->
|
||||
Reply = yesOffWeGo,
|
||||
HandlerState = start,
|
||||
HandlerData = myInitailData0,
|
||||
{accept, Reply, HandlerState, HandlerData, ManagerState}.
|
||||
|
||||
client_stop(Pid, Reason, State) ->
|
||||
io:format("Client stopped:~p ~p~n",[Pid, Reason]),
|
||||
State.
|
||||
|
||||
manager_rpc(secret, State) ->
|
||||
{accept, welcomeToFTP, State};
|
||||
manager_rpc(_, State) ->
|
||||
{reject, badPassword, State}.
|
||||
|
||||
handle_rpc(start, {logon, ?S("jimmy")}, State, Env) ->
|
||||
{ok, active, State};
|
||||
handle_rpc(active, ls, State, Env) ->
|
||||
{ok, Files} = file:list_dir("."),
|
||||
Ret = map(fun(I) -> s(I) end, Files),
|
||||
{{files, Ret}, active, State};
|
||||
handle_rpc(active, {get, ?S(File)}, State, Env) ->
|
||||
{ok, Files} = file:list_dir("."),
|
||||
case member(File, Files) of
|
||||
true ->
|
||||
{ok, Bin} = file:read_file(File),
|
||||
{Bin, active, State};
|
||||
false ->
|
||||
{noSuchFile, stop, State}
|
||||
end.
|
||||
|
||||
|
||||
|
||||
|
||||
</pre></td></tr></table> </TD>
|
||||
</TR></TABLE></TD><TD BACKGROUND='../images/wr.png'><IMG SRC='../images/pix.gif' ALT='' HEIGHT=11 WIDTH=11></TD></TR>
|
||||
<TR BGCOLOR='#cc0000'><TD COLSPAN='3'><IMG SRC='../images/pix.gif' HEIGHT=1 WIDTH=1 ALT=''></TD></TR></TABLE><TABLE BORDER=0 CELLSPACING=0 CELLPADDING=0 WIDTH='100%'>
|
||||
<TR><TD BACKGROUND='../images/wl_cccccc.png'><IMG SRC='../images/pix.gif' ALT='' HEIGHT=11 WIDTH=11></TD><TD WIDTH='100%' BGCOLOR='#FFFFFF'>
|
||||
<TABLE BORDER=0 CELLSPACING=0 CELLPADDING=5 WIDTH='100%' ><TR><TD BGCOLOR='#CCCCCC'><B><FONT FACE='verdana,helvetica,arial'><FONT SIZE=-1>(
|
||||
<A HREF=''></A>
|
||||
)</FONT></FONT></B></TD></TR></TABLE></TD><TD BACKGROUND='../images/wr_cccccc.png'><IMG SRC='../images/pix.gif' ALT='' HEIGHT=11 WIDTH=11></TD></TR>
|
||||
<TR><TD COLSPAN='3' BGCOLOR='#cc0000'><IMG SRC='../images/pix.gif' HEIGHT=1
|
||||
WIDTH=1 ALT=''></TD></TR></TABLE>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</body>
|
||||
</html>
|
||||
@@ -145,7 +145,26 @@ SIZE=-1>Downloads</FONT></FONT></FONT></B></TD>
|
||||
</td>
|
||||
<td valign='top'>
|
||||
<TABLE BORDER=0 CELLSPACING=0 CELLPADDING=0 WIDTH='100%'> <TR VALIGN=TOP><TD BGCOLOR='#cc0000'><IMG SRC='../images/cl.png' ALT='' HEIGHT=10 WIDTH=7><IMG SRC='../images/pix.gif' ALT='' HEIGHT=4 WIDTH=4></TD>
|
||||
<TD WIDTH='100%' BGCOLOR='#cc0000'> <TABLE BORDER=0 CELLSPACING=0 CELLPADDING=2 WIDTH='100%' > <TR> <TD BGCOLOR='#cc0000'><B><FONT FACE='verdana,helvetica,arial'><FONT COLOR='#FFFFFF'><FONT SIZE='+0'>White paper</FONT></FONT></FONT></B></TD></TR></TABLE></TD>
|
||||
<TD WIDTH='100%' BGCOLOR='#cc0000'> <TABLE BORDER=0 CELLSPACING=0 CELLPADDING=2 WIDTH='100%' > <TR> <TD BGCOLOR='#cc0000'><B><FONT FACE='verdana,helvetica,arial'><FONT COLOR='#FFFFFF'><FONT SIZE='+0'>Warning</FONT></FONT></FONT></B></TD></TR></TABLE></TD>
|
||||
<TD ALIGN=RIGHT BGCOLOR='#cc0000'><IMG SRC='../images/cr.png' ALT='' HEIGHT=10 WIDTH=7></TD></TR></TABLE>
|
||||
<TABLE BORDER=0 CELLSPACING=0 CELLPADDING=0 WIDTH='100%' ><TR><TD BACKGROUND='../images/gl.png'><IMG SRC='../images/pix.gif' ALT='' HEIGHT=11 WIDTH=11></TD>
|
||||
<TD WIDTH='100%' BGCOLOR='#cc0000'><TABLE BORDER=0 CELLSPACING=0 CELLPADDING=5 WIDTH='100%' ><TR><TD BGCOLOR='#E6E6E6'><FONT FACE='verdana,helvetica,arial'><FONT SIZE=-2>2002-03-05</FONT></FONT></TD></TR></TABLE></TD>
|
||||
<TD BACKGROUND='../images/gr.png'><IMG SRC='../images/pix.gif' ALT='' HEIGHT=11 WIDTH=11></TD></TR><TR><TD COLSPAN='3' BGCOLOR='#006666'><IMG SRC='../images/pix.gif' HEIGHT=1 WIDTH=1 ALT=''></TD></TR>
|
||||
<TR><TD BACKGROUND='../images/wl.png'><IMG SRC='../images/pix.gif' ALT='' HEIGHT=11 WIDTH=11></TD><TD WIDTH='100%' BGCOLOR='#FFFFFF'><TABLE BORDER=0 CELLSPACING=0 CELLPADDING=5 WIDTH='100%' ><TR><TD BGCOLOR='#FFFFFF'>
|
||||
<p>
|
||||
Pre-release. Be warned. Things change frequently
|
||||
</TD>
|
||||
</TR></TABLE></TD><TD BACKGROUND='../images/wr.png'><IMG SRC='../images/pix.gif' ALT='' HEIGHT=11 WIDTH=11></TD></TR>
|
||||
<TR BGCOLOR='#cc0000'><TD COLSPAN='3'><IMG SRC='../images/pix.gif' HEIGHT=1 WIDTH=1 ALT=''></TD></TR></TABLE><TABLE BORDER=0 CELLSPACING=0 CELLPADDING=0 WIDTH='100%'>
|
||||
<TR><TD BACKGROUND='../images/wl_cccccc.png'><IMG SRC='../images/pix.gif' ALT='' HEIGHT=11 WIDTH=11></TD><TD WIDTH='100%' BGCOLOR='#FFFFFF'>
|
||||
<TABLE BORDER=0 CELLSPACING=0 CELLPADDING=5 WIDTH='100%' ><TR><TD BGCOLOR='#CCCCCC'><B><FONT FACE='verdana,helvetica,arial'><FONT SIZE=-1>(
|
||||
<A HREF=''></A>
|
||||
)</FONT></FONT></B></TD></TR></TABLE></TD><TD BACKGROUND='../images/wr_cccccc.png'><IMG SRC='../images/pix.gif' ALT='' HEIGHT=11 WIDTH=11></TD></TR>
|
||||
<TR><TD COLSPAN='3' BGCOLOR='#cc0000'><IMG SRC='../images/pix.gif' HEIGHT=1
|
||||
WIDTH=1 ALT=''></TD></TR></TABLE>
|
||||
<p>
|
||||
<TABLE BORDER=0 CELLSPACING=0 CELLPADDING=0 WIDTH='100%'> <TR VALIGN=TOP><TD BGCOLOR='#cc0000'><IMG SRC='../images/cl.png' ALT='' HEIGHT=10 WIDTH=7><IMG SRC='../images/pix.gif' ALT='' HEIGHT=4 WIDTH=4></TD>
|
||||
<TD WIDTH='100%' BGCOLOR='#cc0000'> <TABLE BORDER=0 CELLSPACING=0 CELLPADDING=2 WIDTH='100%' > <TR> <TD BGCOLOR='#cc0000'><B><FONT FACE='verdana,helvetica,arial'><FONT COLOR='#FFFFFF'><FONT SIZE='+0'>UBF Home</FONT></FONT></FONT></B></TD></TR></TABLE></TD>
|
||||
<TD ALIGN=RIGHT BGCOLOR='#cc0000'><IMG SRC='../images/cr.png' ALT='' HEIGHT=10 WIDTH=7></TD></TR></TABLE>
|
||||
<TABLE BORDER=0 CELLSPACING=0 CELLPADDING=0 WIDTH='100%' ><TR><TD BACKGROUND='../images/gl.png'><IMG SRC='../images/pix.gif' ALT='' HEIGHT=11 WIDTH=11></TD>
|
||||
<TD WIDTH='100%' BGCOLOR='#cc0000'><TABLE BORDER=0 CELLSPACING=0 CELLPADDING=5 WIDTH='100%' ><TR><TD BGCOLOR='#E6E6E6'><FONT FACE='verdana,helvetica,arial'><FONT SIZE=-2>2002-03-05</FONT></FONT></TD></TR></TABLE></TD>
|
||||
|
||||
171
doc/site/javac.html
Normal file
171
doc/site/javac.html
Normal file
@@ -0,0 +1,171 @@
|
||||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
||||
<HTML>
|
||||
<HEAD>
|
||||
<META HTTP-EQUIV='Content-Type' CONTENT='text/html; charset=iso-8859-1'>
|
||||
<TITLE>Site</TITLE>
|
||||
</HEAD>
|
||||
<BODY TEXT='#222222' BGCOLOR='#DDDDDD'
|
||||
TOPMARGIN='0' LEFTMARGIN='0' MARGINWIDTH='10'
|
||||
MARGINHEIGHT='0'><p>
|
||||
<table>
|
||||
<tr>
|
||||
<td valign='top' width='15%'>
|
||||
<TABLE BORDER=0 CELLSPACING=0 CELLPADDING=0 WIDTH='100%' >
|
||||
<TR VALIGN=TOP BGCOLOR='#cc000000'>
|
||||
<TD BGCOLOR='#DDDDDD'><IMG SRC='../images/pix.gif' ALT='' HEIGHT=3 WIDTH=3></TD>
|
||||
<TD><IMG SRC='../images/cl.png' ALT='' HEIGHT=10 WIDTH=7></TD>
|
||||
<TD><B><FONT FACE='verdana,helvetica,arial'><FONT
|
||||
COLOR='#FFFFFF'><FONT
|
||||
SIZE=-1>Documents</FONT></FONT></FONT></B></TD>
|
||||
<TD ALIGN=RIGHT><IMG SRC='../images/cr.png' ALT='' HEIGHT=10 WIDTH=7></TD>
|
||||
<TD ALIGN=RIGHT BGCOLOR='#DDDDDD'><IMG SRC='../images/pix.gif' ALT='' HEIGHT=3 WIDTH=3></TD>
|
||||
</TR>
|
||||
</TABLE>
|
||||
<TABLE BORDER=0 CELLSPACING=0 CELLPADDING=0 WIDTH='100%' >
|
||||
<TR BGCOLOR='#cc000000'>
|
||||
<TD COLSPAN='3'><IMG SRC='../images/pix.gif' HEIGHT=1 WIDTH=1 ALT=''></TD>
|
||||
</TR>
|
||||
<TR BGCOLOR='#FFFFFF'>
|
||||
<TD BACKGROUND='../images/sl.png'><IMG SRC='../images/pix.gif' ALT='' HEIGHT=3 WIDTH=3></TD>
|
||||
<TD WIDTH='100%'>
|
||||
<TABLE BORDER=0 CELLSPACING=0 CELLPADDING=5 WIDTH='100%' >
|
||||
<TR><TD>
|
||||
<a href="home.html">Home</a>
|
||||
<br><a href="white.html">White paper</a>
|
||||
<br><a href="ubfa.html">UBF(A) spec</a>
|
||||
<br><a href="ubfb.html">UBF(B) spec</a>
|
||||
</TD></TR>
|
||||
</TABLE>
|
||||
</TD>
|
||||
<TD ALIGN=RIGHT BACKGROUND='../images/sr.png'><IMG SRC='../images/pix.gif' ALT='' HEIGHT=3 WIDTH=3></TD>
|
||||
</TR>
|
||||
<TR>
|
||||
<TD COLSPAN='3' BGCOLOR='#cc000000'><IMG SRC='../images/pix.gif' HEIGHT=1 WIDTH=1 ALT=''></TD>
|
||||
</TR>
|
||||
</TABLE>
|
||||
<p>
|
||||
<TABLE BORDER=0 CELLSPACING=0 CELLPADDING=0 WIDTH='100%' >
|
||||
<TR VALIGN=TOP BGCOLOR='#cc000000'>
|
||||
<TD BGCOLOR='#DDDDDD'><IMG SRC='../images/pix.gif' ALT='' HEIGHT=3 WIDTH=3></TD>
|
||||
<TD><IMG SRC='../images/cl.png' ALT='' HEIGHT=10 WIDTH=7></TD>
|
||||
<TD><B><FONT FACE='verdana,helvetica,arial'><FONT
|
||||
COLOR='#FFFFFF'><FONT
|
||||
SIZE=-1>Tutorials</FONT></FONT></FONT></B></TD>
|
||||
<TD ALIGN=RIGHT><IMG SRC='../images/cr.png' ALT='' HEIGHT=10 WIDTH=7></TD>
|
||||
<TD ALIGN=RIGHT BGCOLOR='#DDDDDD'><IMG SRC='../images/pix.gif' ALT='' HEIGHT=3 WIDTH=3></TD>
|
||||
</TR>
|
||||
</TABLE>
|
||||
<TABLE BORDER=0 CELLSPACING=0 CELLPADDING=0 WIDTH='100%' >
|
||||
<TR BGCOLOR='#cc000000'>
|
||||
<TD COLSPAN='3'><IMG SRC='../images/pix.gif' HEIGHT=1 WIDTH=1 ALT=''></TD>
|
||||
</TR>
|
||||
<TR BGCOLOR='#FFFFFF'>
|
||||
<TD BACKGROUND='../images/sl.png'><IMG SRC='../images/pix.gif' ALT='' HEIGHT=3 WIDTH=3></TD>
|
||||
<TD WIDTH='100%'>
|
||||
<TABLE BORDER=0 CELLSPACING=0 CELLPADDING=5 WIDTH='100%' >
|
||||
<TR><TD>
|
||||
<a href="quick.html">Quick start</a>
|
||||
<br><a href="eserve.html">Erlang servers</a>
|
||||
<br><a href="javac.html">Java clients</a>
|
||||
</TD></TR>
|
||||
</TABLE>
|
||||
</TD>
|
||||
<TD ALIGN=RIGHT BACKGROUND='../images/sr.png'><IMG SRC='../images/pix.gif' ALT='' HEIGHT=3 WIDTH=3></TD>
|
||||
</TR>
|
||||
<TR>
|
||||
<TD COLSPAN='3' BGCOLOR='#cc000000'><IMG SRC='../images/pix.gif' HEIGHT=1 WIDTH=1 ALT=''></TD>
|
||||
</TR>
|
||||
</TABLE>
|
||||
<p>
|
||||
<TABLE BORDER=0 CELLSPACING=0 CELLPADDING=0 WIDTH='100%' >
|
||||
<TR VALIGN=TOP BGCOLOR='#cc000000'>
|
||||
<TD BGCOLOR='#DDDDDD'><IMG SRC='../images/pix.gif' ALT='' HEIGHT=3 WIDTH=3></TD>
|
||||
<TD><IMG SRC='../images/cl.png' ALT='' HEIGHT=10 WIDTH=7></TD>
|
||||
<TD><B><FONT FACE='verdana,helvetica,arial'><FONT
|
||||
COLOR='#FFFFFF'><FONT
|
||||
SIZE=-1>Services</FONT></FONT></FONT></B></TD>
|
||||
<TD ALIGN=RIGHT><IMG SRC='../images/cr.png' ALT='' HEIGHT=10 WIDTH=7></TD>
|
||||
<TD ALIGN=RIGHT BGCOLOR='#DDDDDD'><IMG SRC='../images/pix.gif' ALT='' HEIGHT=3 WIDTH=3></TD>
|
||||
</TR>
|
||||
</TABLE>
|
||||
<TABLE BORDER=0 CELLSPACING=0 CELLPADDING=0 WIDTH='100%' >
|
||||
<TR BGCOLOR='#cc000000'>
|
||||
<TD COLSPAN='3'><IMG SRC='../images/pix.gif' HEIGHT=1 WIDTH=1 ALT=''></TD>
|
||||
</TR>
|
||||
<TR BGCOLOR='#FFFFFF'>
|
||||
<TD BACKGROUND='../images/sl.png'><IMG SRC='../images/pix.gif' ALT='' HEIGHT=3 WIDTH=3></TD>
|
||||
<TD WIDTH='100%'>
|
||||
<TABLE BORDER=0 CELLSPACING=0 CELLPADDING=5 WIDTH='100%' >
|
||||
<TR><TD>
|
||||
<a href="irc.html">IRC</a>
|
||||
<br><a href="messagebox.html">Message Box</a>
|
||||
<br><a href="file.html">File server</a>
|
||||
</TD></TR>
|
||||
</TABLE>
|
||||
</TD>
|
||||
<TD ALIGN=RIGHT BACKGROUND='../images/sr.png'><IMG SRC='../images/pix.gif' ALT='' HEIGHT=3 WIDTH=3></TD>
|
||||
</TR>
|
||||
<TR>
|
||||
<TD COLSPAN='3' BGCOLOR='#cc000000'><IMG SRC='../images/pix.gif' HEIGHT=1 WIDTH=1 ALT=''></TD>
|
||||
</TR>
|
||||
</TABLE>
|
||||
<p>
|
||||
<TABLE BORDER=0 CELLSPACING=0 CELLPADDING=0 WIDTH='100%' >
|
||||
<TR VALIGN=TOP BGCOLOR='#cc000000'>
|
||||
<TD BGCOLOR='#DDDDDD'><IMG SRC='../images/pix.gif' ALT='' HEIGHT=3 WIDTH=3></TD>
|
||||
<TD><IMG SRC='../images/cl.png' ALT='' HEIGHT=10 WIDTH=7></TD>
|
||||
<TD><B><FONT FACE='verdana,helvetica,arial'><FONT
|
||||
COLOR='#FFFFFF'><FONT
|
||||
SIZE=-1>Downloads</FONT></FONT></FONT></B></TD>
|
||||
<TD ALIGN=RIGHT><IMG SRC='../images/cr.png' ALT='' HEIGHT=10 WIDTH=7></TD>
|
||||
<TD ALIGN=RIGHT BGCOLOR='#DDDDDD'><IMG SRC='../images/pix.gif' ALT='' HEIGHT=3 WIDTH=3></TD>
|
||||
</TR>
|
||||
</TABLE>
|
||||
<TABLE BORDER=0 CELLSPACING=0 CELLPADDING=0 WIDTH='100%' >
|
||||
<TR BGCOLOR='#cc000000'>
|
||||
<TD COLSPAN='3'><IMG SRC='../images/pix.gif' HEIGHT=1 WIDTH=1 ALT=''></TD>
|
||||
</TR>
|
||||
<TR BGCOLOR='#FFFFFF'>
|
||||
<TD BACKGROUND='../images/sl.png'><IMG SRC='../images/pix.gif' ALT='' HEIGHT=3 WIDTH=3></TD>
|
||||
<TD WIDTH='100%'>
|
||||
<TABLE BORDER=0 CELLSPACING=0 CELLPADDING=5 WIDTH='100%' >
|
||||
<TR><TD>
|
||||
<a href="downloads.html">Downloads</a>
|
||||
</TD></TR>
|
||||
</TABLE>
|
||||
</TD>
|
||||
<TD ALIGN=RIGHT BACKGROUND='../images/sr.png'><IMG SRC='../images/pix.gif' ALT='' HEIGHT=3 WIDTH=3></TD>
|
||||
</TR>
|
||||
<TR>
|
||||
<TD COLSPAN='3' BGCOLOR='#cc000000'><IMG SRC='../images/pix.gif' HEIGHT=1 WIDTH=1 ALT=''></TD>
|
||||
</TR>
|
||||
</TABLE>
|
||||
<p>
|
||||
<p>
|
||||
</td>
|
||||
<td valign='top'>
|
||||
<TABLE BORDER=0 CELLSPACING=0 CELLPADDING=0 WIDTH='100%'> <TR VALIGN=TOP><TD BGCOLOR='#cc0000'><IMG SRC='../images/cl.png' ALT='' HEIGHT=10 WIDTH=7><IMG SRC='../images/pix.gif' ALT='' HEIGHT=4 WIDTH=4></TD>
|
||||
<TD WIDTH='100%' BGCOLOR='#cc0000'> <TABLE BORDER=0 CELLSPACING=0 CELLPADDING=2 WIDTH='100%' > <TR> <TD BGCOLOR='#cc0000'><B><FONT FACE='verdana,helvetica,arial'><FONT COLOR='#FFFFFF'><FONT SIZE='+0'>Quick start</FONT></FONT></FONT></B></TD></TR></TABLE></TD>
|
||||
<TD ALIGN=RIGHT BGCOLOR='#cc0000'><IMG SRC='../images/cr.png' ALT='' HEIGHT=10 WIDTH=7></TD></TR></TABLE>
|
||||
<TABLE BORDER=0 CELLSPACING=0 CELLPADDING=0 WIDTH='100%' ><TR><TD BACKGROUND='../images/gl.png'><IMG SRC='../images/pix.gif' ALT='' HEIGHT=11 WIDTH=11></TD>
|
||||
<TD WIDTH='100%' BGCOLOR='#cc0000'><TABLE BORDER=0 CELLSPACING=0 CELLPADDING=5 WIDTH='100%' ><TR><TD BGCOLOR='#E6E6E6'><FONT FACE='verdana,helvetica,arial'><FONT SIZE=-2>2002-03-05</FONT></FONT></TD></TR></TABLE></TD>
|
||||
<TD BACKGROUND='../images/gr.png'><IMG SRC='../images/pix.gif' ALT='' HEIGHT=11 WIDTH=11></TD></TR><TR><TD COLSPAN='3' BGCOLOR='#006666'><IMG SRC='../images/pix.gif' HEIGHT=1 WIDTH=1 ALT=''></TD></TR>
|
||||
<TR><TD BACKGROUND='../images/wl.png'><IMG SRC='../images/pix.gif' ALT='' HEIGHT=11 WIDTH=11></TD><TD WIDTH='100%' BGCOLOR='#FFFFFF'><TABLE BORDER=0 CELLSPACING=0 CELLPADDING=5 WIDTH='100%' ><TR><TD BGCOLOR='#FFFFFF'>
|
||||
<TABLE BGCOLOR=#ccccff WIDTH=100% BORDER=1 BORDERCOLOR=#0000ff>
|
||||
<TR>
|
||||
<TD><b>Java clients</B></TD></TR></TABLE>
|
||||
<p>Not yet written.
|
||||
</TD>
|
||||
</TR></TABLE></TD><TD BACKGROUND='../images/wr.png'><IMG SRC='../images/pix.gif' ALT='' HEIGHT=11 WIDTH=11></TD></TR>
|
||||
<TR BGCOLOR='#cc0000'><TD COLSPAN='3'><IMG SRC='../images/pix.gif' HEIGHT=1 WIDTH=1 ALT=''></TD></TR></TABLE><TABLE BORDER=0 CELLSPACING=0 CELLPADDING=0 WIDTH='100%'>
|
||||
<TR><TD BACKGROUND='../images/wl_cccccc.png'><IMG SRC='../images/pix.gif' ALT='' HEIGHT=11 WIDTH=11></TD><TD WIDTH='100%' BGCOLOR='#FFFFFF'>
|
||||
<TABLE BORDER=0 CELLSPACING=0 CELLPADDING=5 WIDTH='100%' ><TR><TD BGCOLOR='#CCCCCC'><B><FONT FACE='verdana,helvetica,arial'><FONT SIZE=-1>(
|
||||
<A HREF=''></A>
|
||||
)</FONT></FONT></B></TD></TR></TABLE></TD><TD BACKGROUND='../images/wr_cccccc.png'><IMG SRC='../images/pix.gif' ALT='' HEIGHT=11 WIDTH=11></TD></TR>
|
||||
<TR><TD COLSPAN='3' BGCOLOR='#cc0000'><IMG SRC='../images/pix.gif' HEIGHT=1
|
||||
WIDTH=1 ALT=''></TD></TR></TABLE>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</body>
|
||||
</html>
|
||||
169
doc/site/messagebox.html
Normal file
169
doc/site/messagebox.html
Normal file
@@ -0,0 +1,169 @@
|
||||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
||||
<HTML>
|
||||
<HEAD>
|
||||
<META HTTP-EQUIV='Content-Type' CONTENT='text/html; charset=iso-8859-1'>
|
||||
<TITLE>Site</TITLE>
|
||||
</HEAD>
|
||||
<BODY TEXT='#222222' BGCOLOR='#DDDDDD'
|
||||
TOPMARGIN='0' LEFTMARGIN='0' MARGINWIDTH='10'
|
||||
MARGINHEIGHT='0'><p>
|
||||
<table>
|
||||
<tr>
|
||||
<td valign='top' width='15%'>
|
||||
<TABLE BORDER=0 CELLSPACING=0 CELLPADDING=0 WIDTH='100%' >
|
||||
<TR VALIGN=TOP BGCOLOR='#cc000000'>
|
||||
<TD BGCOLOR='#DDDDDD'><IMG SRC='../images/pix.gif' ALT='' HEIGHT=3 WIDTH=3></TD>
|
||||
<TD><IMG SRC='../images/cl.png' ALT='' HEIGHT=10 WIDTH=7></TD>
|
||||
<TD><B><FONT FACE='verdana,helvetica,arial'><FONT
|
||||
COLOR='#FFFFFF'><FONT
|
||||
SIZE=-1>Documents</FONT></FONT></FONT></B></TD>
|
||||
<TD ALIGN=RIGHT><IMG SRC='../images/cr.png' ALT='' HEIGHT=10 WIDTH=7></TD>
|
||||
<TD ALIGN=RIGHT BGCOLOR='#DDDDDD'><IMG SRC='../images/pix.gif' ALT='' HEIGHT=3 WIDTH=3></TD>
|
||||
</TR>
|
||||
</TABLE>
|
||||
<TABLE BORDER=0 CELLSPACING=0 CELLPADDING=0 WIDTH='100%' >
|
||||
<TR BGCOLOR='#cc000000'>
|
||||
<TD COLSPAN='3'><IMG SRC='../images/pix.gif' HEIGHT=1 WIDTH=1 ALT=''></TD>
|
||||
</TR>
|
||||
<TR BGCOLOR='#FFFFFF'>
|
||||
<TD BACKGROUND='../images/sl.png'><IMG SRC='../images/pix.gif' ALT='' HEIGHT=3 WIDTH=3></TD>
|
||||
<TD WIDTH='100%'>
|
||||
<TABLE BORDER=0 CELLSPACING=0 CELLPADDING=5 WIDTH='100%' >
|
||||
<TR><TD>
|
||||
<a href="home.html">Home</a>
|
||||
<br><a href="white.html">White paper</a>
|
||||
<br><a href="ubfa.html">UBF(A) spec</a>
|
||||
<br><a href="ubfb.html">UBF(B) spec</a>
|
||||
</TD></TR>
|
||||
</TABLE>
|
||||
</TD>
|
||||
<TD ALIGN=RIGHT BACKGROUND='../images/sr.png'><IMG SRC='../images/pix.gif' ALT='' HEIGHT=3 WIDTH=3></TD>
|
||||
</TR>
|
||||
<TR>
|
||||
<TD COLSPAN='3' BGCOLOR='#cc000000'><IMG SRC='../images/pix.gif' HEIGHT=1 WIDTH=1 ALT=''></TD>
|
||||
</TR>
|
||||
</TABLE>
|
||||
<p>
|
||||
<TABLE BORDER=0 CELLSPACING=0 CELLPADDING=0 WIDTH='100%' >
|
||||
<TR VALIGN=TOP BGCOLOR='#cc000000'>
|
||||
<TD BGCOLOR='#DDDDDD'><IMG SRC='../images/pix.gif' ALT='' HEIGHT=3 WIDTH=3></TD>
|
||||
<TD><IMG SRC='../images/cl.png' ALT='' HEIGHT=10 WIDTH=7></TD>
|
||||
<TD><B><FONT FACE='verdana,helvetica,arial'><FONT
|
||||
COLOR='#FFFFFF'><FONT
|
||||
SIZE=-1>Tutorials</FONT></FONT></FONT></B></TD>
|
||||
<TD ALIGN=RIGHT><IMG SRC='../images/cr.png' ALT='' HEIGHT=10 WIDTH=7></TD>
|
||||
<TD ALIGN=RIGHT BGCOLOR='#DDDDDD'><IMG SRC='../images/pix.gif' ALT='' HEIGHT=3 WIDTH=3></TD>
|
||||
</TR>
|
||||
</TABLE>
|
||||
<TABLE BORDER=0 CELLSPACING=0 CELLPADDING=0 WIDTH='100%' >
|
||||
<TR BGCOLOR='#cc000000'>
|
||||
<TD COLSPAN='3'><IMG SRC='../images/pix.gif' HEIGHT=1 WIDTH=1 ALT=''></TD>
|
||||
</TR>
|
||||
<TR BGCOLOR='#FFFFFF'>
|
||||
<TD BACKGROUND='../images/sl.png'><IMG SRC='../images/pix.gif' ALT='' HEIGHT=3 WIDTH=3></TD>
|
||||
<TD WIDTH='100%'>
|
||||
<TABLE BORDER=0 CELLSPACING=0 CELLPADDING=5 WIDTH='100%' >
|
||||
<TR><TD>
|
||||
<a href="quick.html">Quick start</a>
|
||||
<br><a href="eserve.html">Erlang servers</a>
|
||||
<br><a href="javac.html">Java clients</a>
|
||||
</TD></TR>
|
||||
</TABLE>
|
||||
</TD>
|
||||
<TD ALIGN=RIGHT BACKGROUND='../images/sr.png'><IMG SRC='../images/pix.gif' ALT='' HEIGHT=3 WIDTH=3></TD>
|
||||
</TR>
|
||||
<TR>
|
||||
<TD COLSPAN='3' BGCOLOR='#cc000000'><IMG SRC='../images/pix.gif' HEIGHT=1 WIDTH=1 ALT=''></TD>
|
||||
</TR>
|
||||
</TABLE>
|
||||
<p>
|
||||
<TABLE BORDER=0 CELLSPACING=0 CELLPADDING=0 WIDTH='100%' >
|
||||
<TR VALIGN=TOP BGCOLOR='#cc000000'>
|
||||
<TD BGCOLOR='#DDDDDD'><IMG SRC='../images/pix.gif' ALT='' HEIGHT=3 WIDTH=3></TD>
|
||||
<TD><IMG SRC='../images/cl.png' ALT='' HEIGHT=10 WIDTH=7></TD>
|
||||
<TD><B><FONT FACE='verdana,helvetica,arial'><FONT
|
||||
COLOR='#FFFFFF'><FONT
|
||||
SIZE=-1>Services</FONT></FONT></FONT></B></TD>
|
||||
<TD ALIGN=RIGHT><IMG SRC='../images/cr.png' ALT='' HEIGHT=10 WIDTH=7></TD>
|
||||
<TD ALIGN=RIGHT BGCOLOR='#DDDDDD'><IMG SRC='../images/pix.gif' ALT='' HEIGHT=3 WIDTH=3></TD>
|
||||
</TR>
|
||||
</TABLE>
|
||||
<TABLE BORDER=0 CELLSPACING=0 CELLPADDING=0 WIDTH='100%' >
|
||||
<TR BGCOLOR='#cc000000'>
|
||||
<TD COLSPAN='3'><IMG SRC='../images/pix.gif' HEIGHT=1 WIDTH=1 ALT=''></TD>
|
||||
</TR>
|
||||
<TR BGCOLOR='#FFFFFF'>
|
||||
<TD BACKGROUND='../images/sl.png'><IMG SRC='../images/pix.gif' ALT='' HEIGHT=3 WIDTH=3></TD>
|
||||
<TD WIDTH='100%'>
|
||||
<TABLE BORDER=0 CELLSPACING=0 CELLPADDING=5 WIDTH='100%' >
|
||||
<TR><TD>
|
||||
<a href="irc.html">IRC</a>
|
||||
<br><a href="messagebox.html">Message Box</a>
|
||||
<br><a href="file.html">File server</a>
|
||||
</TD></TR>
|
||||
</TABLE>
|
||||
</TD>
|
||||
<TD ALIGN=RIGHT BACKGROUND='../images/sr.png'><IMG SRC='../images/pix.gif' ALT='' HEIGHT=3 WIDTH=3></TD>
|
||||
</TR>
|
||||
<TR>
|
||||
<TD COLSPAN='3' BGCOLOR='#cc000000'><IMG SRC='../images/pix.gif' HEIGHT=1 WIDTH=1 ALT=''></TD>
|
||||
</TR>
|
||||
</TABLE>
|
||||
<p>
|
||||
<TABLE BORDER=0 CELLSPACING=0 CELLPADDING=0 WIDTH='100%' >
|
||||
<TR VALIGN=TOP BGCOLOR='#cc000000'>
|
||||
<TD BGCOLOR='#DDDDDD'><IMG SRC='../images/pix.gif' ALT='' HEIGHT=3 WIDTH=3></TD>
|
||||
<TD><IMG SRC='../images/cl.png' ALT='' HEIGHT=10 WIDTH=7></TD>
|
||||
<TD><B><FONT FACE='verdana,helvetica,arial'><FONT
|
||||
COLOR='#FFFFFF'><FONT
|
||||
SIZE=-1>Downloads</FONT></FONT></FONT></B></TD>
|
||||
<TD ALIGN=RIGHT><IMG SRC='../images/cr.png' ALT='' HEIGHT=10 WIDTH=7></TD>
|
||||
<TD ALIGN=RIGHT BGCOLOR='#DDDDDD'><IMG SRC='../images/pix.gif' ALT='' HEIGHT=3 WIDTH=3></TD>
|
||||
</TR>
|
||||
</TABLE>
|
||||
<TABLE BORDER=0 CELLSPACING=0 CELLPADDING=0 WIDTH='100%' >
|
||||
<TR BGCOLOR='#cc000000'>
|
||||
<TD COLSPAN='3'><IMG SRC='../images/pix.gif' HEIGHT=1 WIDTH=1 ALT=''></TD>
|
||||
</TR>
|
||||
<TR BGCOLOR='#FFFFFF'>
|
||||
<TD BACKGROUND='../images/sl.png'><IMG SRC='../images/pix.gif' ALT='' HEIGHT=3 WIDTH=3></TD>
|
||||
<TD WIDTH='100%'>
|
||||
<TABLE BORDER=0 CELLSPACING=0 CELLPADDING=5 WIDTH='100%' >
|
||||
<TR><TD>
|
||||
<a href="downloads.html">Downloads</a>
|
||||
</TD></TR>
|
||||
</TABLE>
|
||||
</TD>
|
||||
<TD ALIGN=RIGHT BACKGROUND='../images/sr.png'><IMG SRC='../images/pix.gif' ALT='' HEIGHT=3 WIDTH=3></TD>
|
||||
</TR>
|
||||
<TR>
|
||||
<TD COLSPAN='3' BGCOLOR='#cc000000'><IMG SRC='../images/pix.gif' HEIGHT=1 WIDTH=1 ALT=''></TD>
|
||||
</TR>
|
||||
</TABLE>
|
||||
<p>
|
||||
<p>
|
||||
</td>
|
||||
<td valign='top'>
|
||||
<TABLE BORDER=0 CELLSPACING=0 CELLPADDING=0 WIDTH='100%'> <TR VALIGN=TOP><TD BGCOLOR='#cc0000'><IMG SRC='../images/cl.png' ALT='' HEIGHT=10 WIDTH=7><IMG SRC='../images/pix.gif' ALT='' HEIGHT=4 WIDTH=4></TD>
|
||||
<TD WIDTH='100%' BGCOLOR='#cc0000'> <TABLE BORDER=0 CELLSPACING=0 CELLPADDING=2 WIDTH='100%' > <TR> <TD BGCOLOR='#cc0000'><B><FONT FACE='verdana,helvetica,arial'><FONT COLOR='#FFFFFF'><FONT SIZE='+0'>UBF(B)</FONT></FONT></FONT></B></TD></TR></TABLE></TD>
|
||||
<TD ALIGN=RIGHT BGCOLOR='#cc0000'><IMG SRC='../images/cr.png' ALT='' HEIGHT=10 WIDTH=7></TD></TR></TABLE>
|
||||
<TABLE BORDER=0 CELLSPACING=0 CELLPADDING=0 WIDTH='100%' ><TR><TD BACKGROUND='../images/gl.png'><IMG SRC='../images/pix.gif' ALT='' HEIGHT=11 WIDTH=11></TD>
|
||||
<TD WIDTH='100%' BGCOLOR='#cc0000'><TABLE BORDER=0 CELLSPACING=0 CELLPADDING=5 WIDTH='100%' ><TR><TD BGCOLOR='#E6E6E6'><FONT FACE='verdana,helvetica,arial'><FONT SIZE=-2>2002-03-05</FONT></FONT></TD></TR></TABLE></TD>
|
||||
<TD BACKGROUND='../images/gr.png'><IMG SRC='../images/pix.gif' ALT='' HEIGHT=11 WIDTH=11></TD></TR><TR><TD COLSPAN='3' BGCOLOR='#006666'><IMG SRC='../images/pix.gif' HEIGHT=1 WIDTH=1 ALT=''></TD></TR>
|
||||
<TR><TD BACKGROUND='../images/wl.png'><IMG SRC='../images/pix.gif' ALT='' HEIGHT=11 WIDTH=11></TD><TD WIDTH='100%' BGCOLOR='#FFFFFF'><TABLE BORDER=0 CELLSPACING=0 CELLPADDING=5 WIDTH='100%' ><TR><TD BGCOLOR='#FFFFFF'>
|
||||
<h3>Message box</h3>
|
||||
<p>Not yet wrtten - will be something like nntp.
|
||||
</TD>
|
||||
</TR></TABLE></TD><TD BACKGROUND='../images/wr.png'><IMG SRC='../images/pix.gif' ALT='' HEIGHT=11 WIDTH=11></TD></TR>
|
||||
<TR BGCOLOR='#cc0000'><TD COLSPAN='3'><IMG SRC='../images/pix.gif' HEIGHT=1 WIDTH=1 ALT=''></TD></TR></TABLE><TABLE BORDER=0 CELLSPACING=0 CELLPADDING=0 WIDTH='100%'>
|
||||
<TR><TD BACKGROUND='../images/wl_cccccc.png'><IMG SRC='../images/pix.gif' ALT='' HEIGHT=11 WIDTH=11></TD><TD WIDTH='100%' BGCOLOR='#FFFFFF'>
|
||||
<TABLE BORDER=0 CELLSPACING=0 CELLPADDING=5 WIDTH='100%' ><TR><TD BGCOLOR='#CCCCCC'><B><FONT FACE='verdana,helvetica,arial'><FONT SIZE=-1>(
|
||||
<A HREF=''></A>
|
||||
)</FONT></FONT></B></TD></TR></TABLE></TD><TD BACKGROUND='../images/wr_cccccc.png'><IMG SRC='../images/pix.gif' ALT='' HEIGHT=11 WIDTH=11></TD></TR>
|
||||
<TR><TD COLSPAN='3' BGCOLOR='#cc0000'><IMG SRC='../images/pix.gif' HEIGHT=1
|
||||
WIDTH=1 ALT=''></TD></TR></TABLE>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</body>
|
||||
</html>
|
||||
@@ -1,7 +1,8 @@
|
||||
|
||||
## Add your modules here
|
||||
|
||||
EHTML = home white irc file ubfb ubfb_quick ubfa ubfa_quick quick
|
||||
EHTML = downloads eserve messagebox \
|
||||
javac home white irc file ubfb ubfb_quick ubfa ubfa_quick quick
|
||||
|
||||
## Do not change below this line
|
||||
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
|
||||
## Add your modules here
|
||||
|
||||
EHTML = home white irc ftp ubfb ubfb_quick ubfa ubfa_quick quick
|
||||
EHTML = home white irc file ubfb ubfb_quick ubfa ubfa_quick quick
|
||||
|
||||
## Do not change below this line
|
||||
|
||||
|
||||
21
doc/src/downloads.ehtml
Normal file
21
doc/src/downloads.ehtml
Normal file
@@ -0,0 +1,21 @@
|
||||
<include>layout.mac</include>
|
||||
<top/>
|
||||
|
||||
<article title="UBF(B)"
|
||||
date="2002-03-05"
|
||||
link=""
|
||||
linktitle="">
|
||||
|
||||
<h3>Downloads</h3>
|
||||
|
||||
<ul>
|
||||
<li><a href="../downloads">Download directory<a>
|
||||
</ul>
|
||||
</article>
|
||||
<bot/>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
35
doc/src/downloads.ehtml~
Normal file
35
doc/src/downloads.ehtml~
Normal file
@@ -0,0 +1,35 @@
|
||||
<include>layout.mac</include>
|
||||
<top/>
|
||||
|
||||
<article title="UBF(B)"
|
||||
date="2002-03-05"
|
||||
link=""
|
||||
linktitle="">
|
||||
|
||||
<h3>File server</h3>
|
||||
|
||||
<h3>Description</h3>
|
||||
<h3>The contract</h3>
|
||||
|
||||
<quotefile>../../file_plugin.con</quotefile>
|
||||
|
||||
<h3>A telnet session</h3>
|
||||
|
||||
<p>A full telnet session using the server can be found in the
|
||||
<a href="quick.html">quick start tutorial</a>
|
||||
|
||||
<h3>An Erlang client</h3>
|
||||
<quotefile>../../file_client.erl</quotefile>
|
||||
|
||||
<h3>The Erlang file server plugin</h3>
|
||||
|
||||
<quotefile>../../file_plugin.erl</quotefile>
|
||||
|
||||
</article>
|
||||
<bot/>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
24
doc/src/eserve.ehtml
Normal file
24
doc/src/eserve.ehtml
Normal file
@@ -0,0 +1,24 @@
|
||||
<include>layout.mac</include>
|
||||
<top/>
|
||||
|
||||
<article title="Quick start"
|
||||
date="2002-03-05"
|
||||
link=""
|
||||
linktitle="">
|
||||
|
||||
<banner>Erlang servers</banner>
|
||||
|
||||
|
||||
|
||||
<p>an example of a server plugin
|
||||
|
||||
<quotefile>../../file_plugin.erl</quotefile>
|
||||
|
||||
</article>
|
||||
<bot/>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
24
doc/src/eserver.ehtml
Normal file
24
doc/src/eserver.ehtml
Normal file
@@ -0,0 +1,24 @@
|
||||
<include>layout.mac</include>
|
||||
<top/>
|
||||
|
||||
<article title="Quick start"
|
||||
date="2002-03-05"
|
||||
link=""
|
||||
linktitle="">
|
||||
|
||||
<banner>Erlang servers</banner>
|
||||
|
||||
|
||||
|
||||
<p>an example of a server plugin
|
||||
|
||||
<quotefile>../../file_plugin.erl</quotefile>
|
||||
|
||||
</article>
|
||||
<bot/>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
75
doc/src/eserver.ehtml~
Normal file
75
doc/src/eserver.ehtml~
Normal file
@@ -0,0 +1,75 @@
|
||||
<include>layout.mac</include>
|
||||
<top/>
|
||||
|
||||
<article title="Quick start"
|
||||
date="2002-03-05"
|
||||
link=""
|
||||
linktitle="">
|
||||
|
||||
<banner>Quick start with UBF</banner>
|
||||
|
||||
<p>This will jump start you with UBF.
|
||||
|
||||
<p>All you need is an internet connection and Telnet to get started.
|
||||
<p>First read the contract - in the next section. Then
|
||||
fire up Telnet and investigate the server (by hand) - then you can see
|
||||
what's really going on
|
||||
<banner>The Contract</banner>
|
||||
<p>
|
||||
<quotefile>../../file_plugin.con</quotefile>
|
||||
<p>
|
||||
<banner>A telnet session</banner>
|
||||
|
||||
<p>
|
||||
The following is a telnet session.
|
||||
|
||||
<p>User input is in red. Server output is in black, some lines have
|
||||
been omitted:
|
||||
|
||||
<p>
|
||||
<box>
|
||||
<font color="red">telnet enfield.sics.se 2000</font>
|
||||
Trying 127.0.0.1...
|
||||
Connected to localhost.localdomain.
|
||||
Escape character is '^]'.
|
||||
{'ubf1.0',"meta_server","I am a meta server
|
||||
See http://www.sics.se/~joe/ubf.html
|
||||
This server speaks Universal Binary Format 1.0
|
||||
For more information type 'description'$ at the dollar prompt
|
||||
Remember the $ and quote marks :-)
|
||||
"}$
|
||||
<font color="red">{'rpc',{'startService',"file_server",#}}$</font>
|
||||
|
||||
{'rpcReply',{'ok','yesOffWeGo'},'start'}$
|
||||
|
||||
<font color="red">{'rpc',{'logon',"jimmy"}}$</font>
|
||||
|
||||
{'rpcReply','ok','active'}$
|
||||
|
||||
<font color="red">{'rpc','ls'}$</font>
|
||||
|
||||
{'rpcReply',{'files',#"ubf.erl"&"client.erl"&
|
||||
...
|
||||
|
||||
<font color="red">{'rpc',{'get',"ubf.erl"}}$</font>
|
||||
|
||||
{'rpcReply',7852~-module(ubf).
|
||||
|
||||
-compile(export_all).
|
||||
|
||||
-export([decode_init/0, decode/1, decode/2, encode/1, encode/2]).
|
||||
-export([encode_print/1, ubf2term/1, deabstract/1]).
|
||||
|
||||
...
|
||||
|
||||
Connection closed by foreign host.
|
||||
[joe@enfield joe]$ exit
|
||||
</box>
|
||||
</article>
|
||||
<bot/>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -1,7 +1,15 @@
|
||||
<include>layout.mac</include>
|
||||
<top/>
|
||||
|
||||
<article title="White paper"
|
||||
<article title="Warning"
|
||||
date="2002-03-05"
|
||||
link=""
|
||||
linktitle="">
|
||||
<p>
|
||||
Pre-release. Be warned. Things change frequently
|
||||
</article>
|
||||
<p>
|
||||
<article title="UBF Home"
|
||||
date="2002-03-05"
|
||||
link=""
|
||||
linktitle="">
|
||||
|
||||
@@ -1,53 +1,54 @@
|
||||
<include>layout.mac</include>
|
||||
<top/>
|
||||
|
||||
<article title="Manifesto"
|
||||
date="2001-06-10"
|
||||
<article title="White paper"
|
||||
date="2002-03-05"
|
||||
link=""
|
||||
linktitle="">
|
||||
|
||||
<p>Magna virtus tua et vivebam etiam Et quoniam cum me, formasti mihi quasi
|
||||
necesse esset nisi vero; illa prior. Item si cum in quam me urgeret
|
||||
quod non est, innocentia est, fit, ut eam ut vides, haec ipsa tamen
|
||||
loqui quoniam itaque.
|
||||
|
||||
<p>Iactabam domine, et confiteri me delicta mea,
|
||||
deus, es domine, non servientibus (et magistris a paedagogis et mineris
|
||||
ingentes miserias)? Salus tua, relicto te vult homo circumferens
|
||||
mortalitem suam, circumferens mortalitem inrisormeus, cui loquor. <P>
|
||||
|
||||
<p>Hocadum i et confiteri me delicta mea,
|
||||
deus, es domine, non servientibus (et magistris a paedagogis et mineris
|
||||
ingentes miserias)? Salus tua, relicto te vult homo circumferens
|
||||
<a href="http://www.dedicated-servers.co.uk/">www.dedicated-servers.co.uk</a>
|
||||
ingentes miserias)? Salus tua, relicto te vult homo circumferens.
|
||||
|
||||
</article>
|
||||
|
||||
<p>
|
||||
|
||||
<article title="Design"
|
||||
date="2001-06-10"
|
||||
link="http://hadess.net/"
|
||||
linktitle="click for more">
|
||||
<p>This design was shamlessly stolen from
|
||||
<a href="http://hadess.net/">http://hadess.net/</a>.
|
||||
and recoded in Erlang.
|
||||
</article>
|
||||
<p>
|
||||
|
||||
<article title="To do"
|
||||
date="2001-06-10"
|
||||
link=""
|
||||
linktitle="">
|
||||
<p>UBF is a language for transporting and describing complex data structures across a network. It has two components:
|
||||
<ul>
|
||||
<li>Recode this using a nice red color - done
|
||||
<li>Make sure it passes html_check
|
||||
<li>Change ehtml to write the output files in a different
|
||||
directory
|
||||
<li>Write a makefile for this.
|
||||
</article>
|
||||
<li>
|
||||
|
||||
<a href="ubfa.html">UBF(A)</a> is a data transport format, roughly
|
||||
equivalent to well-formed XML.
|
||||
|
||||
<li><a href="ubfb.html">UBF(B)</a> is a programming langauge
|
||||
for describing types in UBF(A) and protocols between clients
|
||||
and servers.
|
||||
UBF(B) is roughly equivalent to to Verified XML,
|
||||
XML-schemas, SOAP and WDSL.
|
||||
|
||||
</ul>
|
||||
|
||||
<p>While the XML series of languages had the goal of having a human
|
||||
readable format the UBF languages take the opposite view and provide a
|
||||
"machine friendly" format.
|
||||
|
||||
<p>UBF is designed to be easy to implement. As a proof of concept - UBF drivers
|
||||
For Erlang, Oz, Java and TCL can be found in the download area.
|
||||
Implementors are welcome to add new languages.
|
||||
|
||||
<p>UBF is designed to be "language neutral" - UBF(A) defines a
|
||||
language neutral binary format for transporting data across a
|
||||
network. UBF(B) is a type system for describing client/server
|
||||
interactions which use UBF(A).
|
||||
|
||||
<h3>Programming by Contract</h3>
|
||||
<center>
|
||||
<img src="$ROOT/images/ubf.gif">
|
||||
</center>
|
||||
|
||||
<p>Central to UBF is the idea of a "contract" which regulates the
|
||||
set of legal conversations that can take place between a client and a server.
|
||||
|
||||
<p>A software component (the contract checker) is place between a client and server which checks that all interactions between thew client and server are legal.
|
||||
|
||||
<p>The digram shows a Java client talking to a C++ server.
|
||||
|
||||
|
||||
</article>
|
||||
<bot/>
|
||||
|
||||
|
||||
|
||||
22
doc/src/javac.ehtml
Normal file
22
doc/src/javac.ehtml
Normal file
@@ -0,0 +1,22 @@
|
||||
<include>layout.mac</include>
|
||||
<top/>
|
||||
|
||||
<article title="Quick start"
|
||||
date="2002-03-05"
|
||||
link=""
|
||||
linktitle="">
|
||||
|
||||
<banner>Java clients</banner>
|
||||
|
||||
|
||||
|
||||
<p>Not yet written.
|
||||
|
||||
</article>
|
||||
<bot/>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
24
doc/src/javac.ehtml~
Normal file
24
doc/src/javac.ehtml~
Normal file
@@ -0,0 +1,24 @@
|
||||
<include>layout.mac</include>
|
||||
<top/>
|
||||
|
||||
<article title="Quick start"
|
||||
date="2002-03-05"
|
||||
link=""
|
||||
linktitle="">
|
||||
|
||||
<banner>Erlang servers</banner>
|
||||
|
||||
|
||||
|
||||
<p>an example of a server plugin
|
||||
|
||||
<quotefile>../../file_plugin.erl</quotefile>
|
||||
|
||||
</article>
|
||||
<bot/>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
20
doc/src/messagebox.ehtml
Normal file
20
doc/src/messagebox.ehtml
Normal file
@@ -0,0 +1,20 @@
|
||||
<include>layout.mac</include>
|
||||
<top/>
|
||||
|
||||
<article title="UBF(B)"
|
||||
date="2002-03-05"
|
||||
link=""
|
||||
linktitle="">
|
||||
|
||||
<h3>Message box</h3>
|
||||
|
||||
<p>Not yet wrtten - will be something like nntp.
|
||||
|
||||
</article>
|
||||
<bot/>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
35
doc/src/messagebox.ehtml~
Normal file
35
doc/src/messagebox.ehtml~
Normal file
@@ -0,0 +1,35 @@
|
||||
<include>layout.mac</include>
|
||||
<top/>
|
||||
|
||||
<article title="UBF(B)"
|
||||
date="2002-03-05"
|
||||
link=""
|
||||
linktitle="">
|
||||
|
||||
<h3>File server</h3>
|
||||
|
||||
<h3>Description</h3>
|
||||
<h3>The contract</h3>
|
||||
|
||||
<quotefile>../../file_plugin.con</quotefile>
|
||||
|
||||
<h3>A telnet session</h3>
|
||||
|
||||
<p>A full telnet session using the server can be found in the
|
||||
<a href="quick.html">quick start tutorial</a>
|
||||
|
||||
<h3>An Erlang client</h3>
|
||||
<quotefile>../../file_client.erl</quotefile>
|
||||
|
||||
<h3>The Erlang file server plugin</h3>
|
||||
|
||||
<quotefile>../../file_plugin.erl</quotefile>
|
||||
|
||||
</article>
|
||||
<bot/>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
BIN
file_client.beam
BIN
file_client.beam
Binary file not shown.
BIN
file_plugin.beam
BIN
file_plugin.beam
Binary file not shown.
@@ -1,2 +1,3 @@
|
||||
#! /bin/sh
|
||||
erl -noshell -s irc_client batch $1
|
||||
make
|
||||
erl -noshell -s irc_client_gs batch $1
|
||||
|
||||
BIN
irc_client.beam
BIN
irc_client.beam
Binary file not shown.
@@ -25,8 +25,6 @@ start(Nick) ->
|
||||
end,
|
||||
io:format("client stops~n").
|
||||
|
||||
|
||||
|
||||
loop(Pid, Group, Gs, Nick) ->
|
||||
io:format("Status: Nick=~s Group=~s Joined groups=~p~n",[Nick, Group, Gs]),
|
||||
case io:get_line('> ') of
|
||||
|
||||
Binary file not shown.
@@ -7,21 +7,34 @@
|
||||
-define(S(X), {'#S',X}).
|
||||
s(X) -> {'#S', X}.
|
||||
|
||||
start() ->
|
||||
spawn(fun() -> init1() end).
|
||||
batch([Nick]) ->
|
||||
start(atom_to_list(Nick)).
|
||||
|
||||
start(Nick) ->
|
||||
spawn(fun() -> init1(Nick) end).
|
||||
|
||||
init1() ->
|
||||
{ok, Pid, Name} = client:start("localhost", 2000),
|
||||
{reply, {ok,yes}, start} = rpc(Pid, {startService, s("irc"), []}),
|
||||
Self = self(),
|
||||
client:install_handler(Pid, fun(M) ->
|
||||
send_self(M, Self)
|
||||
end),
|
||||
case rpc(Pid, logon) of
|
||||
{reply, {ok,?S(Nick)}, active} ->
|
||||
init(Pid, Nick);
|
||||
_ ->
|
||||
exit(connect)
|
||||
init1(Nick) ->
|
||||
case client:start("enfield.sics.se", 2000) of
|
||||
{ok, Pid, Name} ->
|
||||
{reply, {ok,yes}, start} = rpc(Pid, {startService, s("irc"), []}),
|
||||
client:install_handler(Pid, fun print_msg/1),
|
||||
{reply, _, _} = rpc(Pid, logon),
|
||||
Self = self(),
|
||||
client:install_handler(Pid, fun(M) ->
|
||||
send_self(M, Self)
|
||||
end),
|
||||
case rpc(Pid, {nick, s(Nick)}) of
|
||||
{reply, nickInUse, _} ->
|
||||
client:stop(Pid),
|
||||
io:format("Nick was in use try again~n"),
|
||||
erlang:halt();
|
||||
{reply, nickChanged, active} ->
|
||||
init(Pid, Nick)
|
||||
end,
|
||||
io:format("client stops~n");
|
||||
{error, socket} ->
|
||||
io:format("Cannot make TCP connection~n"),
|
||||
erlang:halt()
|
||||
end.
|
||||
|
||||
init(Pid, Nick) ->
|
||||
@@ -32,6 +45,7 @@ init(Pid, Nick) ->
|
||||
L1 = gs:label(W, [{x,10},{y,10},{label,{text,"Nick:" ++ Nick}}]),
|
||||
E1=gs:entry(W, [{x,10},{y,40},{width, 120}]),
|
||||
gs:button(W,[{x,130},{y,40},{data, join},{label,{text,"Join Group"}}]),
|
||||
gs:config(E1, {text, "erlang"}),
|
||||
E2=gs:entry(W, [{x,10},{y,70},{width, 120}]),
|
||||
gs:button(W,[{x,130},{y,70}, {data,nick},{label,{text,"Change Nick"}}]),
|
||||
gs:button(W,[{x,10},{y,110}, {data,quit}, {label,{text,"Quit"}}]),
|
||||
@@ -52,6 +66,17 @@ loop(S, Dict, Pid, L1, E1, E2) ->
|
||||
loop(S, Dict, Pid, L1, E1, E2)
|
||||
end,
|
||||
loop(S, Dict, Pid, L1, E1, E2);
|
||||
{gs,_,click,{leave,Group},_} ->
|
||||
io:format("I leave: ~s~n",[Group]),
|
||||
case dict:find(Group, Dict) of
|
||||
{ok, {W,_}} ->
|
||||
gs:destroy(W),
|
||||
Dict1 = dict:erase(Group, Dict),
|
||||
rpc(Pid, {leave, s(Group)}),
|
||||
loop(S, Dict1, Pid, L1, E1, E2);
|
||||
error ->
|
||||
loop(S, Dict, Pid, L1, E1, E2)
|
||||
end;
|
||||
{gs,_,click,join,_} ->
|
||||
Group = gs:read(E1, text),
|
||||
io:format("Join:~s~n",[Group]),
|
||||
@@ -70,25 +95,40 @@ loop(S, Dict, Pid, L1, E1, E2) ->
|
||||
end
|
||||
end;
|
||||
{gs,_,click,quit,_} ->
|
||||
exit(1);
|
||||
erlang:halt();
|
||||
{gs,Obj,keypress,G,['Return'|_]} ->
|
||||
Str = gs:read(Obj, text),
|
||||
gs:config(Obj, {text, ""}),
|
||||
io:format("Send: ~s to ~s~n",[Str, G]),
|
||||
rpc(Pid, {msg, s(G), s(Str ++ "\n")}),
|
||||
loop(S, Dict, Pid, L1, E1, E2);
|
||||
{gs,Obj,keypress,G,_} ->
|
||||
loop(S, Dict, Pid, L1, E1, E2);
|
||||
{event, {leaves, Who, Group}} ->
|
||||
display(Group, Dict, Who ++ " leaves the group\n"),
|
||||
loop(S, Dict, Pid, L1, E1, E2);
|
||||
{event, {joins, Who, Group}} ->
|
||||
display(Group, Dict, Who ++ " joins the group\n"),
|
||||
loop(S, Dict, Pid, L1, E1, E2);
|
||||
{event, {changesName, Old, New, Group}} ->
|
||||
display(Group, Dict, Old ++ " changes name to " ++ New ++ "\n"),
|
||||
loop(S, Dict, Pid, L1, E1, E2);
|
||||
{event, {msg, From, Group, Msg}} ->
|
||||
case dict:find(Group, Dict) of
|
||||
{ok, {W, Txt}} ->
|
||||
gs:config(Txt, {insert, {'end', From ++ " > " ++ Msg}});
|
||||
error ->
|
||||
io:format("Msg:~s ~s ~s~n",[From, Group, Msg])
|
||||
end,
|
||||
display(Group, Dict, From ++ " > " ++ Msg),
|
||||
loop(S, Dict, Pid, L1, E1, E2);
|
||||
X ->
|
||||
io:format("man: got other: ~w~n",[X]),
|
||||
loop(S, Dict, Pid, L1, E1, E2)
|
||||
end.
|
||||
|
||||
display(Group, Dict, Str) ->
|
||||
case dict:find(Group, Dict) of
|
||||
{ok, {W, Txt}} ->
|
||||
gs:config(Txt, {insert, {'end', Str}});
|
||||
error ->
|
||||
io:format("Cannot display:~s ~s~n",[Group, Str])
|
||||
end.
|
||||
|
||||
new_group(S, Name) ->
|
||||
Width=450,Height=350,
|
||||
W = gs:window(S,[{title,"Name"},
|
||||
@@ -125,3 +165,6 @@ print_msg(X) ->
|
||||
io:format("==> ~p~n",[Other])
|
||||
end,
|
||||
fun print_msg/1.
|
||||
|
||||
|
||||
|
||||
|
||||
170
irc_client_gs.erl~
Normal file
170
irc_client_gs.erl~
Normal file
@@ -0,0 +1,170 @@
|
||||
-module(irc_client_gs).
|
||||
|
||||
-compile(export_all).
|
||||
|
||||
-import(client, [rpc/2]).
|
||||
|
||||
-define(S(X), {'#S',X}).
|
||||
s(X) -> {'#S', X}.
|
||||
|
||||
batch([Nick]) ->
|
||||
start(atom_to_list(Nick)).
|
||||
|
||||
start(Nick) ->
|
||||
spawn(fun() -> init1(Nick) end).
|
||||
|
||||
init1(Nick) ->
|
||||
case client:start("localhost", 2000) of
|
||||
{ok, Pid, Name} ->
|
||||
{reply, {ok,yes}, start} = rpc(Pid, {startService, s("irc"), []}),
|
||||
client:install_handler(Pid, fun print_msg/1),
|
||||
{reply, _, _} = rpc(Pid, logon),
|
||||
Self = self(),
|
||||
client:install_handler(Pid, fun(M) ->
|
||||
send_self(M, Self)
|
||||
end),
|
||||
case rpc(Pid, {nick, s(Nick)}) of
|
||||
{reply, nickInUse, _} ->
|
||||
client:stop(Pid),
|
||||
io:format("Nick was in use try again~n"),
|
||||
erlang:halt();
|
||||
{reply, nickChanged, active} ->
|
||||
init(Pid, Nick)
|
||||
end,
|
||||
io:format("client stops~n");
|
||||
{error, socket} ->
|
||||
io:format("Cannot make TCP connection~n"),
|
||||
erlang:halt()
|
||||
end.
|
||||
|
||||
init(Pid, Nick) ->
|
||||
S=gs:start(),
|
||||
Width=250,Height=170,
|
||||
W= gs:window(S,[{title,"IRC client"},
|
||||
{width,Width},{height,Height},{map,true}]),
|
||||
L1 = gs:label(W, [{x,10},{y,10},{label,{text,"Nick:" ++ Nick}}]),
|
||||
E1=gs:entry(W, [{x,10},{y,40},{width, 120}]),
|
||||
gs:button(W,[{x,130},{y,40},{data, join},{label,{text,"Join Group"}}]),
|
||||
gs:config(E1, {text, "erlang"}),
|
||||
E2=gs:entry(W, [{x,10},{y,70},{width, 120}]),
|
||||
gs:button(W,[{x,130},{y,70}, {data,nick},{label,{text,"Change Nick"}}]),
|
||||
gs:button(W,[{x,10},{y,110}, {data,quit}, {label,{text,"Quit"}}]),
|
||||
loop(S, dict:new(), Pid, L1, E1,E2).
|
||||
|
||||
loop(S, Dict, Pid, L1, E1, E2) ->
|
||||
receive
|
||||
{gs,_,click,nick,_} ->
|
||||
Nick = gs:read(E2, text),
|
||||
io:format("Change nick to:~s~n",[Nick]),
|
||||
case rpc(Pid, {nick, s(Nick)}) of
|
||||
{reply, nickInUse, _} ->
|
||||
gs:config(E2, {text, "** bad nick **"}),
|
||||
loop(S, Dict, Pid, L1, E1, E2);
|
||||
{reply, nickChanged, active} ->
|
||||
io:format("nick was changed~n"),
|
||||
gs:config(L1, {label, {text, "Nick: " ++ Nick}}),
|
||||
loop(S, Dict, Pid, L1, E1, E2)
|
||||
end,
|
||||
loop(S, Dict, Pid, L1, E1, E2);
|
||||
{gs,_,click,{leave,Group},_} ->
|
||||
io:format("I leave: ~s~n",[Group]),
|
||||
case dict:find(Group, Dict) of
|
||||
{ok, {W,_}} ->
|
||||
gs:destroy(W),
|
||||
Dict1 = dict:erase(Group, Dict),
|
||||
rpc(Pid, {leave, s(Group)}),
|
||||
loop(S, Dict1, Pid, L1, E1, E2);
|
||||
error ->
|
||||
loop(S, Dict, Pid, L1, E1, E2)
|
||||
end;
|
||||
{gs,_,click,join,_} ->
|
||||
Group = gs:read(E1, text),
|
||||
io:format("Join:~s~n",[Group]),
|
||||
case Group of
|
||||
"" ->
|
||||
loop(S, Dict, Pid, L1, E1, E2);
|
||||
_ ->
|
||||
case dict:find(Group, Dict) of
|
||||
{ok, W} ->
|
||||
loop(S, Dict, Pid, L1, E1, E2);
|
||||
error ->
|
||||
W = new_group(S, Group),
|
||||
rpc(Pid, {join, s(Group)}),
|
||||
loop(S, dict:store(Group, W, Dict), Pid,
|
||||
L1, E1, E2)
|
||||
end
|
||||
end;
|
||||
{gs,_,click,quit,_} ->
|
||||
erlang:halt();
|
||||
{gs,Obj,keypress,G,['Return'|_]} ->
|
||||
Str = gs:read(Obj, text),
|
||||
gs:config(Obj, {text, ""}),
|
||||
io:format("Send: ~s to ~s~n",[Str, G]),
|
||||
rpc(Pid, {msg, s(G), s(Str ++ "\n")}),
|
||||
loop(S, Dict, Pid, L1, E1, E2);
|
||||
{gs,Obj,keypress,G,_} ->
|
||||
loop(S, Dict, Pid, L1, E1, E2);
|
||||
{event, {leaves, Who, Group}} ->
|
||||
display(Group, Dict, Who ++ " leaves the group\n"),
|
||||
loop(S, Dict, Pid, L1, E1, E2);
|
||||
{event, {joins, Who, Group}} ->
|
||||
display(Group, Dict, Who ++ " joins the group\n"),
|
||||
loop(S, Dict, Pid, L1, E1, E2);
|
||||
{event, {changesName, Old, New, Group}} ->
|
||||
display(Group, Dict, Old ++ " changes name to " ++ New ++ "\n"),
|
||||
loop(S, Dict, Pid, L1, E1, E2);
|
||||
{event, {msg, From, Group, Msg}} ->
|
||||
display(Group, Dict, From ++ " > " ++ Msg),
|
||||
loop(S, Dict, Pid, L1, E1, E2);
|
||||
X ->
|
||||
io:format("man: got other: ~w~n",[X]),
|
||||
loop(S, Dict, Pid, L1, E1, E2)
|
||||
end.
|
||||
|
||||
display(Group, Dict, Str) ->
|
||||
case dict:find(Group, Dict) of
|
||||
{ok, {W, Txt}} ->
|
||||
gs:config(Txt, {insert, {'end', Str}});
|
||||
error ->
|
||||
io:format("Cannot display:~s ~s~n",[Group, Str])
|
||||
end.
|
||||
|
||||
new_group(S, Name) ->
|
||||
Width=450,Height=350,
|
||||
W = gs:window(S,[{title,"Name"},
|
||||
{width,Width},{height,Height},{map,true}]),
|
||||
L1 = gs:label(W, [{x,10},{y,10},{label,{text,"Group:" ++ Name}}]),
|
||||
T1 = gs:editor(W, [{x,10},{y,40},
|
||||
{width,Width-20},
|
||||
{height,Height-120},
|
||||
{vscroll, right}]),
|
||||
E1 = gs:entry(W, [{x,10},{y,Height-70},{width, Width-20},
|
||||
{data, Name},
|
||||
{keypress,true}]),
|
||||
gs:button(W,[{x,10},{y,Height-35},
|
||||
{data, {leave, Name}},{label,{text,"Leave Group"}}]),
|
||||
{W, T1}.
|
||||
|
||||
send_self(Msg, Pid) ->
|
||||
Pid ! {event, ubf:deabstract(Msg)},
|
||||
fun(I) -> send_self(I, Pid) end.
|
||||
|
||||
|
||||
print_msg(X) ->
|
||||
case ubf:deabstract(X) of
|
||||
{joins, Who, Group} ->
|
||||
io:format("~s joins the group ~s~n",[Who, Group]);
|
||||
{leaves, Who, Group} ->
|
||||
io:format("~s leaves the group ~s~n",[Who, Group]);
|
||||
{msg, Who, Group, Msg} ->
|
||||
io:format("Msg from ~s to ~s => ~s~n",[Who, Group,Msg]);
|
||||
{changesName, Old, New, Group} ->
|
||||
io:format("~s is now called ~s in group ~s~n",
|
||||
[Old, New, Group]);
|
||||
Other ->
|
||||
io:format("==> ~p~n",[Other])
|
||||
end,
|
||||
fun print_msg/1.
|
||||
|
||||
|
||||
|
||||
BIN
irc_plugin.beam
BIN
irc_plugin.beam
Binary file not shown.
Binary file not shown.
Binary file not shown.
BIN
server.beam
BIN
server.beam
Binary file not shown.
Binary file not shown.
BIN
test_plugin.beam
BIN
test_plugin.beam
Binary file not shown.
BIN
ubf_driver.beam
BIN
ubf_driver.beam
Binary file not shown.
@@ -35,7 +35,7 @@ loop(Socket, Pid, Cont) ->
|
||||
{Pid, Term} ->
|
||||
%% io:format("ubf_driver sending:~p~n",[Term]),
|
||||
Data = ubf:encode(Term),
|
||||
io:format("ubf_driver sending:~s~n",[Data]),
|
||||
%% io:format("ubf_driver sending:~s~n",[Data]),
|
||||
gen_tcp:send(Socket, Data),
|
||||
loop(Socket, Pid, Cont);
|
||||
stop ->
|
||||
@@ -49,7 +49,7 @@ loop(Socket, Pid, Cont) ->
|
||||
exit(socket_closed);
|
||||
{tcp, Socket, Data} ->
|
||||
T = binary_to_list(Data),
|
||||
io:format("ubf driver received raw=|~s|~n",[T]),
|
||||
%% io:format("ubf driver received raw=|~s|~n",[T]),
|
||||
Cont1 = ubf:decode(T, Cont),
|
||||
%% io:format("Cont1=~p~n",[Cont1]),
|
||||
handle_data(Socket, Pid, Cont1);
|
||||
|
||||
BIN
ubf_test.beam
BIN
ubf_test.beam
Binary file not shown.
BIN
ubf_utils.beam
BIN
ubf_utils.beam
Binary file not shown.
Reference in New Issue
Block a user