Database Driven Menu in JAVA

February 11, 2012

Menu management is an important part of today’s software development. If we develop an enterprise software with 100s pages, it would be stupidity to write code for menu at every page. We have to have a common menu configuration file, where we can change menu elements. But, there are also some problem, file may be deleted by any developer. After deployment the project, we cannot change menu items at run time. Moreover its very difficult to give roles to menu items at file. Its mandatory to create database driven menu for a dynamic, role based enterprise project.

Here we are going to discuss about building a database driven menu step by step.

1. Create a user table with login name, password and other static information of a user.

2.  Create a ROLE_MASTER table with all role_id, role_description and maker_id.

3.  Create a ROLE_DETAILS table, which contains mapping of role_id and page link. Columns this table will be ROLE_ID & ROLE_FUNCTION. This table will contain which role get which page. One page may be assigned to multiple role_id.

4.  Now you have to create a table named EM_MENUMAS with the column of SLNO,NM,PARENTNM,NODETYPE & PAGE_NAME. Here, SLNO is just row number, NM is menu item name which will be shown at pages, PARENTNM is the NM under which this sub-menu is used. if this item is not under any item, then, this column will be blank. NODETYPE will M or L. if it is leaf item or sub menu, then use L other which use M. PAGE_NAME is page link for this menu item. This will be exactly same with ROLE_FUNCTION of ROLE_DETAILS table.

5. Create a table USERROLES with column of USERID & ROLEID. Here we map roles to users.

6. Create a stored function named TREE_MENU. Code of the function is :

CREATE OR REPLACE function DBBL.tree_menu ( v_user_id in varchar2 )
return varchar2 is
v_ret   varchar2(5000) := ”;
t_ret   varchar2(5000);
type t_rec is record (lvl number, slno number, nm varchar2(50), nodetype varchar2(10));
type t_tab is table of t_rec index by binary_integer;
v_tab   t_tab;
pos     integer := 1;
begin
/*for i in (select level lvl, slno, nm, lpad(‘ ‘, level * 14, ‘ ‘) || nm menu,  parentnm,nodetype, page_name from em_menumas
start with parentnm is null
connect by prior nm = parentnm
order siblings by slno)*/
for i in (select level lvl, slno, nm, lpad(‘ ‘, level * 14, ‘ ‘) || nm menu,  parentnm,nodetype, page_name from em_menumas
where (page_name in ( select role_function from  role_detail
where role_id  in ( select roleid from userroles where userid= v_user_id  )
) and  nodetype=’L') or nodetype=’M’ and (parentnm in (select roleid from USERROLES where userid=v_user_id)
or parentnm in (select ‘Remittance’ from dual) or parentnm is null )

and nm not in (select ROLE_ID from ROLE_MASTER where role_id not in  (select roleid from USERROLES where userid=v_user_id))
start with parentnm is null
connect by prior nm = parentnm
order  by slno)
loop
if i.nodetype = ‘M’ then

if pos> 1 then
for k in reverse 1 .. v_tab.count
loop
if v_tab(k).lvl = i.lvl then
t_ret := t_ret || ‘</ul></li>’;
goto lbl;
end if;
end loop;
end if;

<<lbl>>

v_tab(pos).lvl          := i.lvl;
v_tab(pos).slno         := i.slno;
v_tab(pos).nm           := i.nm;
v_tab(pos).nodetype     := i.nodetype;

t_ret := t_ret || ‘<li>’ || i.nm || ‘<ul>’;
pos := pos + 1;

else
–t_ret := t_ret || ‘<li>’ || case when i.PAGE_NAME is not null then ‘<a onclick=”getPage(“‘ || i.PAGE_NAME || ‘”)”>’ else ” end ||  ” || i.nm || ‘</li>’;
– t_ret := t_ret || ‘<li>’ || case when i.PAGE_NAME is not null then ‘<a onclick=”getPage(”’ || i.PAGE_NAME || ”’)”>’ ||  i.nm || ‘</a></li>’ else  i.nm || ‘</li>’ end;
if i.PAGE_NAME=’ViewProjectDetails.jsp’ then
t_ret := t_ret || ‘<li>’ || case when i.PAGE_NAME is not null then ‘<a onclick=”getPage(”’ || i.PAGE_NAME || ‘?prjID=’ || v_user_id || ”’)”>’ ||  i.nm || ‘</a></li>’ else  i.nm || ‘</li>’ end;
else
t_ret := t_ret || ‘<li>’ || case when i.PAGE_NAME is not null then ‘<a onclick=”getPage(”’ || i.PAGE_NAME || ”’)”>’ ||  i.nm || ‘</a></li>’ else  i.nm || ‘</li>’ end;
end if;
end if;
end loop;
for k in 1 .. v_tab(v_tab.count).lvl
loop
t_ret := t_ret || ‘</ul></li>’;
end loop;
v_ret := t_ret  ;
return (v_ret);
end;
/

7. Create a method in JAVA data access layer to call the stored function like this:
public String menuString(String logedInUser)
{
String menu = “”, ret;

Statement stmt = null;
conn = DBConnect.getConnection();
CallableStatement cal_stmt = null;

if(conn != null)
{
try{
stmt = conn.createStatement();

cal_stmt = conn.prepareCall(“{? = call tree_menu(?)}”);

cal_stmt.registerOutParameter(1, Types.VARCHAR);

cal_stmt.setString(2, logedInUser);

cal_stmt.execute();

ret = cal_stmt.getString(1);

menu = “<ul  id=\”treemenu1\” class=\”treeview\”>” + ret + “</ul>”;
menu += “<script type=\”text/javascript\”>” +
“ddtreemenu.createTree(\”treemenu1\”, true) ” +
“</script>”;

}
catch(Exception e)
{
menu = e.getMessage();
}
finally
{
try {
conn.close();
} catch (SQLException e) {
// TODO Auto-generated catch block
e.printStackTrace();
}
}
}

return menu;

}

 

8.  Take a JSP page like this:

<%
response.setHeader(“Cache-Control”,”no-cache”);
response.setHeader(“Pragma”,”no-cache”);
response.setDateHeader (“Expires”, -1);

%>
<%@ page session=”true” language=”java” contentType=”text/html; charset=ISO-8859-1″
pageEncoding=”ISO-8859-1″
%>
<%@ page language=”java” import=”java.util.*” %>
<%@ page import=”dal.*” %>
<%@page import=”dal.dao.*”%>
<%@ page import=”dal.servlet.*” %>

<!DOCTYPE html PUBLIC “-//W3C//DTD HTML 4.01 Transitional//EN” “http://www.w3.org/TR/html4/loose.dtd”>

<%@page import=”dal.HelperCls”%><html>
<head>
<meta http-equiv=”Content-Type” content=”text/html; charset=ISO-8859-1″>
<title>Wellcome  ! </title>
<script type=”text/javascript” src=”simpletreemenu.js”>
</script>
<script type=”text/javascript” src=”call.js”>
</script>
<link rel=”stylesheet” type=”text/css” href=”../css/style.css”>
<link rel=”stylesheet” type=”text/css” href=”simpletree.css” />
<style type=”text/css”>
div.scroll
{

width:80%;
height:780px;
overflow:scroll;
}

p.one
{
width: 300px; height: 100%;
border-style: solid;
border-width: 1px;
border-color: fuchsia;
border-spacing: 2px;
}

</style>
<script type=”text/javascript”>

function logout()
{
document.location.href = “index.jsp”;
}
</script>

</head>
<body >

<table Border=”0″ cellpadding=”0″ cellspacing=”0″ width=”100%” “>
<tr>
<td width=”100%” align=”center”>
<a href=”<%=basePath%>”><div id=”logo”></div></a>
</td>
</tr>
<tr>
<td align=”right”>
<font color=”red”><b>Status :<i><%=dayStatus %>,&nbsp;&nbsp; </i>  </b></font>
<font color=”red”><b>Server Date :<i><%=serverCurrentDt %></i>  </b></font>
</td>
</tr>

<tr><td><hr style=”height: 5px; color: green” /></td></tr>
<tr>
<td>
<table  Border=”0″ cellpadding=”2″ width=”100%” >

<tr>
<td width=”20%” valign=”top” >

<div>
<%

%>
<%= new HelperCls().menuString(loginID) %>
<p align=”center”>
<input type=”image” src=”logout.jpg” alt=”Log Out”  onclick=”logout()”/>
<br>
</p>
</div>

<!–  <table  width=”80%” border=”1″ align=”left” cellspacing=”2″ cellpadding=”2″>
<tr>
<td colspan=”2″ align=”center”>
<font size=”5″ face=”arial” color=”green”>
<b>Login Branch Code</b></font>
</td>
</tr>
<tr>
<td>
Login User :
</td>
<td >
–>
<font size=”3″ face=”arial”  color=”green”>
<!– login name  –>
</font>
<!–
</td>
</tr>
<tr>
<td>
Login Role :
</td>
<td >
<font size=”3″ face=”arial”  color=”green”> –>
<!– </font>
</td>
</tr>
<tr>
<td>
Login ID :
</td>
<td >
<font size=”3″ face=”arial”  color=”green”> –>
<!– </font>
</td>
</tr>
</table>  –>

</td>
<td id=”innerContent” width=”100%” valign=”top”>

</td>
</tr>
<tr>
<td colspan=”2″ align=”center”>
<div id=”slice-66″>
© DBBL,2010. All right reserved by Dutch-Bangla Bank Limited.
<br>
Website developed by IT Division | http://www.dutchbanglabank.com </div>
</td>
</tr>
</table>
</td>
</tr>
</table>
</body>
</html>

 

Here, this page will be used as master page and all other pages will be loaded as inner page.

 

9. We have to use following CSS and Javascript pages:

a) simpletree.css:

.treeview ul{ /*CSS for Simple Tree Menu*/
margin: 0;
padding: 0;
text-align: left;
white-space: nowrap;
margin: 0px 0px 0px 0px;
padding: 0px;
}

.treeview li{ /*Style for LI elements in general (excludes an LI that contains sub lists)*/
list-style-type: none;
padding-left: 22px;
margin-bottom: 3px;
}

.treeview li.submenu{ /* Style for LI that contains sub lists (other ULs). */
background-color:#D6E7F1;
cursor: hand !important;
cursor: pointer !important;
list-style-image: none;
list-style-type: none;
white-space: nowrap;
margin:0px;
padding: 5px 0px 7px 8px;
width:179px;
font-weight: bold;
border-bottom:1px solid #a1a3a5;
border-left:1px solid #a1a3a5;
border-right:1px solid #a1a3a5;
}

.treeview li.submenu ul{ /*Style for ULs that are children of LIs (submenu) */
display: none; /*Hide them by default. Don’t delete. */
cursor: hand !important;
cursor: pointer !important;
}

.treeview .submenu ul li{ /*Style for LIs of ULs that are children of LIs (submenu) */
cursor: default;
cursor: hand !important;
cursor: pointer !important;
}

/******************** Sub Menu ****************/

.treeview.ul.submenu {
text-align: left;
white-space: nowrap;
margin: 0px 0px 0px 0px;
padding: 5px;
}

.treeview.ul.submenu li {
list-style-image: none;
list-style-type: none;
white-space: nowrap;
margin:0px;
padding: 5px 0px 7px 8px;
width:179px;
font-weight: bold;
border-top:1px solid #a1a3a5;
}

.treeview.ul.submenu li.selected a{color:#0E2199;}

.treeview.ul.submenu li.selected {
border: 1px solid #a3a4a6;
background-color: #ffffff;

}

.treeview.ul.submenu li a {
display: block;
width: 100%;
color: #444;
font-weight: bold;
font-size:13px;
text-decoration: none;
}

.treeview.ul.submenu li a:hover {
text-decoration:none;
color:#0E2199;
}

 

b) simpletreemenu.js:

var persisteduls=new Object()
var ddtreemenu=new Object()

ddtreemenu.closefolder=”" //set image path to “closed” folder image
ddtreemenu.openfolder=”" //set image path to “open” folder image

//////////No need to edit beyond here///////////////////////////

ddtreemenu.createTree=function(treeid, enablepersist, persistdays){
var ultags=document.getElementById(treeid).getElementsByTagName(“ul”)
if (typeof persisteduls[treeid]==”undefined”)
persisteduls[treeid]=(enablepersist==true && ddtreemenu.getCookie(treeid)!=”")? ddtreemenu.getCookie(treeid).split(“,”) : “”
for (var i=0; i<ultags.length; i++)
ddtreemenu.buildSubTree(treeid, ultags[i], i)
if (enablepersist==true){ //if enable persist feature
var durationdays=(typeof persistdays==”undefined”)? 1 : parseInt(persistdays)
ddtreemenu.dotask(window, function(){ddtreemenu.rememberstate(treeid, durationdays)}, “unload”) //save opened UL indexes on body unload
}
}

ddtreemenu.buildSubTree=function(treeid, ulelement, index){
ulelement.parentNode.className=”submenu”
if (typeof persisteduls[treeid]==”object”){ //if cookie exists (persisteduls[treeid] is an array versus “” string)
if (ddtreemenu.searcharray(persisteduls[treeid], index)){
ulelement.setAttribute(“rel”, “open”)
ulelement.style.display=”block”
ulelement.parentNode.style.backgroundImage=”url(“+ddtreemenu.openfolder+”)”
}
else
ulelement.setAttribute(“rel”, “closed”)
} //end cookie persist code
else if (ulelement.getAttribute(“rel”)==null || ulelement.getAttribute(“rel”)==false) //if no cookie and UL has NO rel attribute explicted added by user
ulelement.setAttribute(“rel”, “closed”)
else if (ulelement.getAttribute(“rel”)==”open”) //else if no cookie and this UL has an explicit rel value of “open”
ddtreemenu.expandSubTree(treeid, ulelement) //expand this UL plus all parent ULs (so the most inner UL is revealed!)
ulelement.parentNode.onclick=function(e){
var submenu=this.getElementsByTagName(“ul”)[0]
if (submenu.getAttribute(“rel”)==”closed”){
submenu.style.display=”block”
submenu.setAttribute(“rel”, “open”)
ulelement.parentNode.style.backgroundImage=”url(“+ddtreemenu.openfolder+”)”
}
else if (submenu.getAttribute(“rel”)==”open”){
submenu.style.display=”none”
submenu.setAttribute(“rel”, “closed”)
ulelement.parentNode.style.backgroundImage=”url(“+ddtreemenu.closefolder+”)”
}
ddtreemenu.preventpropagate(e)
}
ulelement.onclick=function(e){
ddtreemenu.preventpropagate(e)
}
}

ddtreemenu.expandSubTree=function(treeid, ulelement){ //expand a UL element and any of its parent ULs
var rootnode=document.getElementById(treeid)
var currentnode=ulelement
currentnode.style.display=”block”
currentnode.parentNode.style.backgroundImage=”url(“+ddtreemenu.openfolder+”)”
while (currentnode!=rootnode){
if (currentnode.tagName==”UL”){ //if parent node is a UL, expand it too
currentnode.style.display=”block”
currentnode.setAttribute(“rel”, “open”) //indicate it’s open
currentnode.parentNode.style.backgroundImage=”url(“+ddtreemenu.openfolder+”)”
}
currentnode=currentnode.parentNode
}
}

ddtreemenu.flatten=function(treeid, action){ //expand or contract all UL elements
var ultags=document.getElementById(treeid).getElementsByTagName(“ul”)
for (var i=0; i<ultags.length; i++){
ultags[i].style.display=(action==”expand”)? “block” : “none”
var relvalue=(action==”expand”)? “open” : “closed”
ultags[i].setAttribute(“rel”, relvalue)
ultags[i].parentNode.style.backgroundImage=(action==”expand”)? “url(“+ddtreemenu.openfolder+”)” : “url(“+ddtreemenu.closefolder+”)”
}
}

ddtreemenu.rememberstate=function(treeid, durationdays){ //store index of opened ULs relative to other ULs in Tree into cookie
var ultags=document.getElementById(treeid).getElementsByTagName(“ul”)
var openuls=new Array()
for (var i=0; i<ultags.length; i++){
if (ultags[i].getAttribute(“rel”)==”open”)
openuls[openuls.length]=i //save the index of the opened UL (relative to the entire list of ULs) as an array element
}
if (openuls.length==0) //if there are no opened ULs to save/persist
openuls[0]=”none open” //set array value to string to simply indicate all ULs should persist with state being closed
ddtreemenu.setCookie(treeid, openuls.join(“,”), durationdays) //populate cookie with value treeid=1,2,3 etc (where 1,2… are the indexes of the opened ULs)
}

////A few utility functions below//////////////////////

ddtreemenu.getCookie=function(Name){ //get cookie value
var re=new RegExp(Name+”=[^;]+”, “i”); //construct RE to search for target name/value pair
if (document.cookie.match(re)) //if cookie found
return document.cookie.match(re)[0].split(“=”)[1] //return its value
return “”
}

ddtreemenu.setCookie=function(name, value, days){ //set cookei value
var expireDate = new Date()
//set “expstring” to either future or past date, to set or delete cookie, respectively
var expstring=expireDate.setDate(expireDate.getDate()+parseInt(days))
document.cookie = name+”=”+value+”; expires=”+expireDate.toGMTString()+”; path=/”;
}

ddtreemenu.searcharray=function(thearray, value){ //searches an array for the entered value. If found, delete value from array
var isfound=false
for (var i=0; i<thearray.length; i++){
if (thearray[i]==value){
isfound=true
thearray.shift() //delete this element from array for efficiency sake
break
}
}
return isfound
}

ddtreemenu.preventpropagate=function(e){ //prevent action from bubbling upwards
if (typeof e!=”undefined”)
e.stopPropagation()
else
event.cancelBubble=true
}

ddtreemenu.dotask=function(target, functionref, tasktype){ //assign a function to execute to an event handler (ie: onunload)
var tasktype=(window.addEventListener)? tasktype : “on”+tasktype
if (target.addEventListener)
target.addEventListener(tasktype, functionref, false)
else if (target.attachEvent)
target.attachEvent(tasktype, functionref)
}

 

Enjoy your database driven menu.

 


Delete Particular Rows in Excel

July 25, 2011

I have found an interesting macro to format excel.  Suppose, I have an excel file just like this:

SL Roll Name GPA Year
1 33001 Tukhrejul Inam 3.27 2008
2 33002 Ali Hossain 3.87 2007
4 33003 Jahangir Hossain 3.54 2006
5 33004 Moyen Hossain 3.29 2009

I want to delete all rows which contain name like ‘Hossain’. Then I hae to run a macro just like this:

Sub Test()
Dim Rng As Range
Dim x As Long
Set Rng = Range(“C1:C” & Range(“A65536″).End(xlUp).Row)
For x = Rng.Rows.Count To 1 Step -1
If InStr(1, Rng.Cells(x, 1).Value, “Hossain“) = 1 Then
Rng.Cells(x, 1).EntireRow.Delete
End If
Next x
End Sub

Here, C1:C will be column which contains the particular text. =1 means all rows which have the match, will be deleted. If I use ’0′, then all rows which don’t have the match, will be deleted.


Picking up rate for all dates from few day’s rate

May 18, 2011

I want to discuss an important query just now. I have done today it. Suppose, I have a rate_info table like this

dt rate
01/01/2011 24.50
5/01/2011 23.45
15/01/2011 20.34
25/01/2011 28.22
10/02/2011 15.25

Now I have to calculate rate for all dates. The rate will be same until the rate has been changed. Then the query will be like this:

select a.*,(select rate from rate_info where dt=(select max(dt) from rate_info where dt <=a.dt_new))rate_new from
(select to_char((select min(dt) from rate_info)+(level – 1),’DD-MON-RRRR’)dt_new from dual
    connect by level <= ((select max(dt) from rate_info) – (select min(dt) from rate_info)+1))a

If  a single day contain multiple rate with different version like this:

dt rate Version
01/01/2011 24.50 1
5/01/2011 23.45 1
15/01/2011 20.34 1
25/01/2011 28.22 1
10/02/2011 15.25 1
10/02/2011 13.24 2

Then the rate with maximum version will be picked up and query will be like this:
select a.*,(select rate from rate_info where dt=(select max(dt) from rate_info where dt <=a.dt_new)
and version =(select max(version) from rate_info where dt=(select max(dt) from rate_info where dt<=a.dt_new )
))rate_new from
(select to_char((select min(dt) from rate_info)+(level – 1),’DD-MON-RRRR’)dt_new from dual
connect by level <= ((select max(dt) from rate_info) – (select min(dt) from rate_info)+1))a


Filling blank field with previous row value in PL/SQL

May 14, 2011

Suppose I have Table named emp like this

empno comm
033001 RUET
033002
033003
033004 KUET
033004
033005 CUET

Now I want to fill the blank cells with the previous value. Such as comm of 033002, 033003  will be RUET. comm of 033004 will be KUET. How can I do this? I had googled and found an interesting query.

1. I have to execute following query:

select empno,comm, lag(comm ignore nulls) over (order by empno)prev_comm from emp order by empno.

Then I get a view like this :

empno comm prev_comm
033001 RUET
033002 RUET
033003 RUET
033004 KUET RUET
033004 KUET
033005 CUET KUET
CUET

2. Suppose the previous view is represented by mm.
Then I have to write the following query on mm view.

select empno, case when comm is null then prev_comm else comm end as comm from mm.

Then we will get the desired view :

empno comm
033001 RUET
033002 RUET
033003 RUET
033004 KUET
033004 KUET
033005 CUET

So, the final query will be:

select empno, case when comm is null then prev_comm else comm end as comm from (select empno,comm, lag(comm ignore nulls) over (order by empno)prev_comm from emp order by empno)


I Miss C++ Programming

July 26, 2010

Really, I am missing the C++ programming very much. When I was the programmer at Kento Studios, I was directly involved with c++ programming. Really, I miss the pleasure of innovation. When I have passed whole day to solve even a single problem and found it was solved at evening, I couldn’t express in words the pleasure of that moment. I have left Kento Studios about ten months ago. Later on, I have programed with C#, PHP, Java and Oracle successfully. But, I found, working with C++ is much more interesting. I also miss the team with which I have worked. We were eight programmers working together for application development for Nintendo DS. Writing technical specification, resource estimation(such as: sound, graphics requirement analysis), time estimation, task scheduling and solving our own tasks were regular works of ours. Everyone worked with deep attention, then we used to discuss each other with everyone’s task and if we found any error or exception something, then we tried to solve it together. Really, those moments were much very interesting; I really miss now. I cannot but mentioning the name of one programmer-Mr. Suruz. He could solve any problem any how, but he did not keep in mind the feasibility. Generally he wrote  code of long length though it would be solved with few lines of code. Sometimes he used huge memory for solving a problem. I used to collect all the works from programmers as team leader. I tried to make him understand that you couldn’t use such a huge memory or code, you had to use optimum memory, because the device memory is limited. But it was so hard to make him agree to rewrite the code. Sometimes he became angry. We smiled seeing his angry face. At last he rewrote the code and felt a heaven pleasure when I accepted his code.


One Year of DS Programming

July 22, 2009

NintendoDSAt 1st June 2009, I have completed my one year of DS programming. Just one year ago when I have joined at Kento Studios, my project manager told me that I had to work with ‘Nintendo DS’. Then I had asked him, “What?” He said again, “Nintendo DS” and stared at me. Perhaps my appearance expressed that I had not understood the word. Then he had written the word ‘Nintendo DS’ on a paper. He also said, this platform is completely new in Bangladesh and no one had worked with it still then in Bangladesh.

I, with my colleague, started to learn about the Nintendo DS, its features, what it was, how we could develop applications for it etc. searching at Google. We used to work hard so much, as we both are fresh graduates, our company was completely new with game development and the platform was also new in Bangladesh. All the new made troublesome for ours to work. Anyway, after studying hard, we found that the development resources are highly restricted and there was also a open source library named Palib for homebrew development. We had started to work with palib and said the authority to apply for license at warioworld for Nintendo DS game development. We had made an environment with devkitPro and palib and started to work. We studied various game logic, graphics, game development methodology and various terms related to game. We also implemented them at palib. We developed five demo games with palib. They are
* Abby Mathematicas
* Aymun & the Machon Pirates.
* 20.000 Leguas de Viaje Submarino
* Don Quijote.
* Olimpiadas del Sabar.
These were PC games and we made first level of these games for Nintendo and proposed the publisher to make all these games for Nintendo. It’s really pleasure to say that publisher was satisfied with our works though we were at very initial position of game development and gave the order to us for final production with original NitroSDK.

Meanwhile, we got the license from Nintendo as a developer and again started to study the new SDK and programming manuals. But we found that we had to work at very core level with assembly & C code. We worked hard continuously one month but we found that it would take longer time if we would go this way. We realized that we had to develop a development framework to speed up the development. We discussed it with authority. Company also realized it and managed a framework from Annino Games Inc. It also was not complete framework. We had started to work with it and filled up the lickings of it.

Anyway, the framework helped us more and we developed two games with it AbbyMathDS and OtijocsDS. Working at Kento Studios with Nitro makes us very confident that we can learn any new technology quickly and can work at any environment successfully.


Thanks to Chipmunk Family

July 14, 2009

First of all, I would like to convey thanks to chipmunk famaliy, specially to Scott Lembcke, who is the author of the chipmunk physics engine. It is a 2D physics engine & open source. I have studied about it for one week deeply and found it very interesting. I can emplement any actions related to physics rules to  2D games. I have studied the codes of  the engine and all demos. They are very easy to emplement. As I am working with Nitro environment for nintendo DS, I have tried to use the engine in that environment. I have done some examples easily related with collition path, bounce, gravity, speed etc. The 7 demos reflects most of the physics rules. If anybody can understand all these demos clearly, he can emplement any action easily, I think. More over the engine has a forum. I have found lots of help from this forum and answers of my questions within very short time.

We can learn more about chipmunk here:

http://code.google.com/p/chipmunk-physics/wiki/Documentation

The forum of chipmunk:

http://www.slembcke.net/forums/index.php


Profile

February 21, 2008

I am Md. Tukhrejul Inam Shamim. I have completed my BSc Engineering in CSE from RUET,            Rajshahi. Now I am working as a software engineer at Kento Studios Ltd. since June 01′ 08. It is a spain based multinational company. I am working with C++ to develop Nintendo DS  applications. Our company is a lisenced developer of Nintendo Inc. America. I have taken an  exclusive training on Object Oriented programming with Dot net Framework at BASIS,  Bangladesh. I, with my team members, have also taken training on Lot Check for DS application  at Oxygen Studios, UK and DS programming with ADSE at Annino Games Inc. Phillipines. I am  also doing my MSc Engineering at IICT, BUET.

Md. Tukhrejul Inam

Cell: +8801717450748


Follow

Get every new post delivered to your Inbox.