Morcego 3D Network Browser - v0.6.0
http://morcego.arca.ime.usp.br
-----------------------------------
Morcego is a java applet for visualizing and browsing graphs (networks)
in 3D. You can use it to make 3D mind maps. It can be embedded in web
applications and it's goal is to become a visualization framework.
The job of integrating Morcego to your website is becoming easier each version
If this documentation is not enough, don't be afraid to send a message to
developers mailing list at morcego-dev@arca.ime.usp.br. We hope you have as much
fun using Morcego as we do by coding it :-).
Morcego is licensed under GNU LESSER GENERAL PUBLIC LICENSE (LGPL).
This documentation is divided in three parts: first one is about using applet,
second on how to embbed Morcego in other applications and finally how to upgrade
to v0.6.0.
This document is divided in the following sections:
1 - Using the applet
2 - Embedding applet in application
2.1 - Making a server
2.1.1 - Making a static mindmap
2.1.2 - Integrating to your PHP application
2.1.3 - Developing your own XMLRPC server
2.1.4 - Creating a new transport layer
2.2 - Properties for nodes and links
2.3 - Javascript integration
2.4 - Applet configuration
3 - Upgrading
3.1 - From v0.5 to v0.6
3.2 - From v0.4 to v0.5
3.3 - From v0.3 to v0.4
1 - USING THE APPLET
Once Morcego applet window opens, you'll see (after loading, that
may take some moments) an animation of little balls connected to each
other in a network getting arranged in space - a cool effect by the way ;-).
The possible actions:
* ROTATE - Drag mouse on empty space and you'll be able to see the graph
from different angles. If you drag fast and relase, like throwing,
the graph will keep spinning.
* GET INFO - Put the mouse cursor over a node, and it will become a hand. If
there's more info about that node, a description box will appear.
* NAVIGATE - Click on a node and it will go to center. When you do that, the
new neighbourhood will appear in a few moments (wait a bit for
the info to come from server). Clicking on center node will
open the node URL in browser window.
* MOVE NODE - Click on a node and drag to move it. The graph will balance
itself as you move. This is useful to see how a node influences
the whole network.
2 - EMBEDDING APPLET IN APPLICATION
For integrating Morcego applet in your web application, you need an special Morcego server
to feed the applet with graph data. This is usually done with XMLRPC, the only transport
way available until now (check section 2.4 on how to implement other ways).
Implementing this used to be a tough task, but since v0.6 Morcego comes with a demo application
and a set of PHP classes for integration with other softwares. You have several options, depending
on your technical skills and time available. You can:
* Make a static mindmap website by editing some XML data files and templates
* Implement your own server in PHP to make a dynamic map, by extending a PHP class
* Develop a XMLRPC server that implements Morcego's protocol in any language you wish
* Make a new transport layer in java, by extending a java class and creating a server to feed it.
2.1 - MAKING A SERVER
2.1.1 - MAKING A STATIC MINDMAP
If you don't have much technical skills, but would like to make an online mind map, you can do one
by editing some XMl files and putting a simple application in a webserver with PHP:
* Copy demo/ to a directory in your web server, let's say /var/www/morcego_demo for example.
* Copy morcego-$VERSION.jar and php/Morcego to /var/www/morcego_demo
* Give permission to your web user to write to /var/www/morcego_demo/templates_c
* Open a browser and check the results
* Take a look at the XML files under templates/data directory. Edit them to customize the mindmap.
* Check also the .tpl files at templates/ dir. Modify those to customize the layout. For help on that, check http://smarty.php.net
2.1.2 - INTEGRATING TO YOUR PHP APPLICATION
Morcego also comes with a set of PHP classes to make your own server. You'll need two files: your server (let's call it server.php),
a php file available through HTTP, and a subclass of Morcego_Graph (let's call it MyGraph)
* server.php
Very simple, check demo/server.php on how to do that. All you need to do is create a Morcego_Graph object (note that Morcego_Graph is an
abstract class and must be subclassed) and use it to instantiate a Morcego_Server object.
* MyGraph
This is the core of your server. You must implement the method getNode($nodeId), that takes the nodeId and returns a data structure
containing all relevant data about node with id $nodeId and the links it has to/from other nodes.
The data structure has the exact same format of the getSubGraph() method (explained below at 2.3), but you usually want to return
only one node in "nodes" section. I say usually, because it might be useful to return a bigger set of nodes and links, for example
in raw XMl server used by the demo: you might want to defined many nodes in one XML files to make your job easier (note that in the
demo you can't start your navigation in some of the nodes that doesn't have it's own XMl file).
2.1.3 - DEVELOPING YOUR OWN XMLRPC SERVER
The XMLRPC server should implement two methods:
* integer getVersion()
This method returns the XMLRPC protocol version. Current version is 2, so if you're
implementing the server according to instructions below, this method should return "2".
In case this method is not present, version 1 is assumed, and so data structure for
older versions of Morcego (0.4 and below) will be expected.
* struct getSubGraph(string nodeId, int depth)
This method returns a part of the graph containing the node with id
nodeId and all nodes with distance lesser or equal than depth.
The returned struct must be as follow, {} indicates structs and []
arrays, fields marked with * are optional (see section below for complete
list of properties)
{
nodes => {
nodeId => {
* type => "Round",
* color => "#FF0000",
* actionUrl => "http://...",
* description => "node description, shown in box",
},
node1Id => {},
node2Id => {...}
}
links => [
{
from => "nodeId",
to => "node2Id",
* type => "Solid"
},
{
from => "nodeId",
to => "node1Id",
* type => "Dashed"
}
]
}
2.1.4 - CREATING A NEW TRANSPORT LAYER
You can do so by creating a new java class in package br.arca.morcego.transport package that implements Transport.
Your class must have the word "Transport" at end, because it will be appended to the parameter "transport" to
obtain the class name.
You have to implement two methods (check interface):
* setup: will be called once
* retrieveData: will be called once on start and everytime user navigates. The format of hash returned is the same described
above in getSubGraph() from xmlrpc server.
2.2 - PROPERTIES FOR NODES AND LINKS
Each NODE can have the following properties:
* type: "Round", "Square", "Triangle", "Text" or "Image".
Round nodes are represented by balls with a title above (that can be empty).
Square and Triangle have similar behavior, but with other forms
Text nodes have just the title.
Image nodes are represented by image defined by "image" property, an url.
* title: Name of the node, that will appear above R
没有合适的资源?快使用搜索试试~ 我知道了~
温馨提示
【项目资源】:包含前端、后端、移动开发、操作系统、人工智能、物联网、信息化管理、数据库、硬件开发、大数据、课程资源、音视频、网站开发等各种技术项目的源码。包括STM32、ESP8266、PHP、QT、Linux、iOS、C++、Java、python、web、C#、EDA、proteus、RTOS等项目的源码。【项目质量】:所有源码都经过严格测试,可以直接运行。功能在确认正常工作后才上传。【适用人群】:适用于希望学习不同技术领域的小白或进阶学习者。可作为毕设项目、课程设计、大作业、工程实训或初期项目立项。【附加价值】:项目具有较高的学习借鉴价值,也可直接拿来修改复刻。对于有一定基础或热衷于研究的人来说,可以在这些基础代码上进行修改和扩展,实现其他功能。【沟通交流】:有任何使用上的问题,欢迎随时与博主沟通,博主会及时解答。鼓励下载和使用,并欢迎大家互相学习,共同进步。
资源推荐
资源详情
资源评论




























收起资源包目录





































































































共 2000 条
- 1
- 2
- 3
- 4
- 5
- 6
- 20
资源评论


CrMylive.
- 粉丝: 1w+
- 资源: 4万+
上传资源 快速赚钱
我的内容管理 展开
我的资源 快来上传第一个资源
我的收益
登录查看自己的收益我的积分 登录查看自己的积分
我的C币 登录后查看C币余额
我的收藏
我的下载
下载帮助


最新资源
- C语言函数设计秘籍:参数传递、返回值与作用域全解析.pdf
- C语言函数精讲:参数传递、作用域与递归的终极实践手册.pdf
- C语言核心语法精讲:变量、循环、函数三大结构深度拆解.pdf
- C语言核心语法速成:10天掌握变量、循环、函数与指针.pdf
- C语言结构体与联合体:嵌入式开发必备的5个设计模式.pdf
- C语言核心知识树:一张思维导图搞定数据类型+运算符优先级.pdf
- C语言经典案例:282个代码示例从HelloWorld到算法优化.pdf
- C语言竟能写游戏?EasyX图形库入门秘籍.pdf
- C语言开发2048游戏:200行代码实现经典逻辑.pdf
- C语言控制台小游戏开发:贪吃蛇完整代码+设计思路.pdf
- C语言可视化编程:用EasyX图形库开发小游戏.pdf
- C语言开发者必备工具链:VSCode配置+GDB调试+Valgrind内存检测.pdf
- C语言内存管理终极教程:malloc、free原理+5个防泄漏技巧.pdf
- C语言跨平台开发技巧:Windows、Linux兼容性解决方案.pdf
- C语言命令行工具开发:argparse库实战教程.pdf
- C语言内存管理终极教程:malloc、free原理与避坑指南.pdf
资源上传下载、课程学习等过程中有任何疑问或建议,欢迎提出宝贵意见哦~我们会及时处理!
点击此处反馈



安全验证
文档复制为VIP权益,开通VIP直接复制
