From 19b403f01fc39709b4f9e5add5de16392d35e2f1 Mon Sep 17 00:00:00 2001 From: shina Date: Mon, 18 Jan 2021 04:24:53 -0300 Subject: [PATCH] ajustando entidades --- UserAgentsServices.xml | 7 +++ board.bkp | Bin 24358 -> 22942 bytes src/main/java/sacip/rest/RestTutor.java | 25 ++++----- .../sacip/sti/agents/PedagogicalAgent.java | 8 ++- .../sacip/sti/agents/RecommenderAgent.java | 7 ++- .../sacip/sti/components/DBConnection.java | 13 ++++- .../java/sacip/sti/dataentities/Content.java | 48 +++++++++++++----- 7 files changed, 75 insertions(+), 33 deletions(-) diff --git a/UserAgentsServices.xml b/UserAgentsServices.xml index 138b3dd..a7a60ac 100644 --- a/UserAgentsServices.xml +++ b/UserAgentsServices.xml @@ -38,6 +38,13 @@ mas SACIP + + getTrilha + retorna a trilha atual do aluno + PedagogicalAgent + mas + SACIP + diff --git a/board.bkp b/board.bkp index 4917a585a75b0a82887fa11b8802c462b2b98280..5313074d5361d64f139bf27619e2de0a0c81bf9e 100644 GIT binary patch literal 22942 zcmeHvTg)R_ewU}ar>Eze*`3bp?(EL8v%5(qs~y#^S~k=5RpIxq!7VFBp^bH5c@zL zIOq8Ls_NL^OndeXL`&W3Qg`B2EhGF|;mPeV2n)rp z@o@Hc;q32bv%h;W``hwq!XJ#cg+k#q@b@#3fA{+H7ni;+9lqKq{aihKP$;08o`MZN zyKaMbb9|2Ee`fYq-}%ae!VB%fjqNE~TTw&LkNv_I@14o^)J^bA(g8hu#SM8dG{(RD zr7wMZ{olYGeBn`Wbk(r%?){`dZ@-JZ{k9BV0F(f0uUz}Zw+EhUD3%Xj)qk?|2l9{n zvsWMy{KA*7o&vu6o1gvLU;mZX;xC-ut$x6}jb#A#tA@i!k8};bYxu={x!$@)*VL+U;W`iA=nlEBA6Ne`!bM~ z|9|ZRXb=`Y0yIxoLtPsOx*q_k`kssxx7z*UOaI}w-+SZF|C@(}2bj>ag_lFq*8|hD zwRj6j5B|J*cmn=?3jRI_3y*3=q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LelAI=wx)9JqD zRO!HN29r5_B8AMF%1Q!6WG!cW3gwyNaxv)F#H%S5vGju3Y}zUsbsz{j%7tX76orR5 zd$M-Ku%R#TRSpGS*c7YkJ;VXE8KMjieO3s;h-D?%oT-jfCkYV3_}BU2vDFRH%5S4*D|Z@=RZll2-cNefx&7e9gZ$j6{li74$rP!8&tMVSVQ08ws$(gD;% ziL!jutAP5J(IFj#&LS8dfdMFGMc;Yr3tc<3R5)b zkbZ@&Hmt4JJ$q(Xfe3p^;%Uo1)JevOfOQ19qt8q%rb< grupo, Student aluno, List trilha) { + private Object getConteudosRecomendados(List grupo, Student aluno, List trilha) { List preferenciasAluno = aluno.getPreferencias(); @@ -172,7 +175,7 @@ public int compare(Content o1, Content o2) { //retornando conteudos String exercicio = top10Conteudos.toString(); - return exercicio; + return new ObjectMapper().valueToTree(top10Conteudos); } catch (Exception e) { diff --git a/src/main/java/sacip/sti/components/DBConnection.java b/src/main/java/sacip/sti/components/DBConnection.java index d3b530e..ff61522 100644 --- a/src/main/java/sacip/sti/components/DBConnection.java +++ b/src/main/java/sacip/sti/components/DBConnection.java @@ -123,13 +123,15 @@ private Content instanceContent(Map in) { try { return new Content((String)in.get("name"), + (String)in.get("descricao"), ((Long)in.get("level")).intValue(), (String)in.get("topic"), (String)in.get("complexity"), (boolean)in.get("exercise"), ((Long)in.get("taxonomy")).intValue(), (List) in.get("tags"), - (String)in.get("link")); + (String)in.get("link"), + (String)in.get("imageLink")); } catch (Exception e) { LOG.error("Não foi possível instanciar o conteúdo", e); return null; @@ -665,23 +667,30 @@ private static Map mapaCriacaoConteudo(String[] tags, String[][] Map conteudo = new HashMap<>(); String name = randomString(); + String descricao = randomString(); Random generator = new Random(); int level = generator.nextInt(5) + 1; String topico = topicos[level-1][generator.nextInt(3)]; String complexidade = complexidades[generator.nextInt(4)]; int taxonomia = generator.nextInt(6); boolean exercicio = generator.nextBoolean(); + String[] links = {"https://cdn.discordapp.com/attachments/571157550956019741/800619655366574091/12243585_1694508097447198_1004266710788666891_n.jpg", + "https://cdn.discordapp.com/attachments/571157550956019741/800619703089365002/21077295_1119616784841346_734019202998452151_n.jpg", + "https://cdn.discordapp.com/attachments/571157550956019741/800619727889629264/1521285067403.jpg"}; + String imageLink = links[generator.nextInt(3)]; contentNames.add(name); conteudo.put("name", name); - conteudo.put("level", level); + conteudo.put("descricao", descricao); conteudo.put("topic", topico); conteudo.put("complexity", complexidade); conteudo.put("exercise", exercicio); conteudo.put("taxonomy", taxonomia); conteudo.put("tags", tags); conteudo.put("link", name); + conteudo.put("level", level); + conteudo.put("imageLink", imageLink); return conteudo; } diff --git a/src/main/java/sacip/sti/dataentities/Content.java b/src/main/java/sacip/sti/dataentities/Content.java index 12f59a2..df29b70 100644 --- a/src/main/java/sacip/sti/dataentities/Content.java +++ b/src/main/java/sacip/sti/dataentities/Content.java @@ -2,11 +2,10 @@ import java.util.List; -import org.midas.util.MidasBean; - -public class Content extends MidasBean{ +public class Content{ private String name; + private String descricao; private String topic; private String complexity; private boolean exercise; @@ -14,6 +13,7 @@ public class Content extends MidasBean{ private List tags; private String link; private int level; + private String imageLink; public int pontos = 0; @@ -22,8 +22,9 @@ public Content() { } - public Content(String name, int level, String topic, String complexity, boolean exercise, int taxonomy, List tags, String link) { + public Content(String name, String descricao, int level, String topic, String complexity, boolean exercise, int taxonomy, List tags, String link, String imageLink) { this.name = name; + this.descricao = descricao; this.topic = topic; this.complexity = complexity; this.exercise = exercise; @@ -31,6 +32,7 @@ public Content(String name, int level, String topic, String complexity, boolean this.tags = tags; this.link = link; this.level = level; + this.imageLink = imageLink; } public String getName() { @@ -41,6 +43,14 @@ public void setName(String name) { this.name = name; } + public String getDescricao() { + return descricao; + } + + public void setDescricao(String descricao) { + this.descricao = descricao; + } + public String getTopic() { return this.topic; } @@ -81,7 +91,7 @@ public List getTags() { return this.tags; } - public String getTagsAsString() { + public String buildTagsAsString() { StringBuilder builder = new StringBuilder(); @@ -115,19 +125,29 @@ public void setLevel(int level) { this.level = level; } + public String getImageLink() { + return imageLink; + } + + public void setImageLink(String imageLink) { + this.imageLink = imageLink; + } + @Override public String toString() { return "{" + - " name:'" + getName() + "'" + - ", level:'" + getLevel() + "'" + - ", topic:'" + getTopic() + "'" + - ", complexity:'" + getComplexity() + "'" + - ", exercise:" + isExercise() + "" + - ", taxonomy:'" + getTaxonomy() + "'" + - ", tags:[" + getTagsAsString() + "]" + - ", link:'" + getLink() + "'" + + " name='" + getName() + "'" + + ", descricao='" + getDescricao() + "'" + + ", topic='" + getTopic() + "'" + + ", complexity='" + getComplexity() + "'" + + ", exercise='" + isExercise() + "'" + + ", taxonomy='" + getTaxonomy() + "'" + + ", tags:[" + buildTagsAsString() + "]" + + ", link='" + getLink() + "'" + + ", level='" + getLevel() + "'" + + ", imageLink='" + getImageLink() + "'" + "}"; } - + }