This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
"use client"; | |
import { zodResolver } from "@hookform/resolvers/zod"; | |
import { useForm } from "react-hook-form"; | |
import MoneyInput from "src/components/custom/money-input"; | |
import { Button } from "src/components/ui/button"; | |
import { Form } from "src/components/ui/form"; | |
import * as z from "zod"; | |
const schema = z.object({ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@OneToMany unidirectional examplo usint Spring JPA. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<ng-template #conteudoDaLinha > | |
<tr class="{{ classeCss }}" > | |
<!-- percorrer cada coluna --> | |
<td *ngFor="let coluna of colunas; let i = index" class="{{ coluna.classeCss }}" > | |
<div class="conteudo-celula" > | |
<!-- Deve existir um recuo na linha dependendo de cada nível na tabela --> | |
<div *ngIf="i === 0" class="recuo-linha-filha-nivel-{{ nivel }}" ></div> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<table> | |
<thead> | |
<tr> | |
<!-- percorrer cada coluna --> | |
<th *ngFor="let coluna of colunas" class="{{ coluna.classeCssCabecalho }}" > | |
{{ coluna.cabecalho }} | |
</th> | |
</tr> | |
</thead> | |
<tbody> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import { TemplateRef } from '@angular/core'; | |
export interface ColunaTabelaAninhada { | |
/** | |
* Texto que aparece no cabeçalho da coluna | |
*/ | |
cabecalho: string; | |
/** |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<tabela-aninhada | |
[colunas]="colunas" | |
[linhas]="linhas" | |
[extratorDeFilhos]="extratorDeLinhasFilhas" | |
[extratorDeClasseCss]="extratorDeCssClassCustomizadaParaLinha" ></tabela-aninhada> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <stdio.h> | |
#include <mpi.h> | |
#define N 100 | |
#define PRODUCER 0 | |
#define CONSUMER 0 | |
#define MAX_PRODUCERS 5 | |
MPI_Status status; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <stdio.h> | |
#include <mpi.h> | |
#define N 100 | |
void produtor() { | |
int prod, rec; | |
while(1) { | |
MPI_Recv(&rec, 1, MPI_INT, 1, 0, MPI_COMM_WORLD, MPI_STATUS_IGNORE); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <mpi.h> | |
#include <stdio.h> | |
#include <stdlib.h> | |
int main(int argc, char* argv[]) { | |
MPI_Init(NULL, NULL); | |
int rank; | |
MPI_Comm_rank(MPI_COMM_WORLD, &rank); | |
int size; | |
MPI_Comm_size(MPI_COMM_WORLD, &size); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include "stddef.h" | |
#include "mpi.h" | |
#include "stdio.h" | |
#define LIMITE 10 | |
int count = 0; |
NewerOlder