Skip to content

Commit cf40654

Browse files
authored
Add files via upload
1 parent aa48c36 commit cf40654

File tree

3 files changed

+34
-0
lines changed

3 files changed

+34
-0
lines changed

scripts/modules/genUser.js

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
module.exports.GenUser = function(nome, key){
2+
console.log({nome: nome,id: key});
3+
return "Nome : "+nome+", ID: "+key;
4+
}

scripts/modules/serial.js

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
function Generate(max){
2+
return Math.floor(Math.random() * max);
3+
}
4+
5+
function Log(text){
6+
console.log(text);
7+
}
8+
9+
module.exports = {
10+
Generate: Generate,
11+
Log: Log
12+
};

scripts/modules/user.js

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
class User{
2+
3+
constructor(name){
4+
this.nome = name;
5+
console.log("Novo usuario : "+ name);
6+
}
7+
8+
getNome(){
9+
return this.nome;
10+
}
11+
12+
getId(){
13+
return Math.floor(Math.random() * 10000);
14+
}
15+
16+
}
17+
18+
exports.CreateUser = User;

0 commit comments

Comments
 (0)