<?php

namespace App\Mappers;

use App\Entities\Logsys\Logsys;
use App\Utils\Collections\GeneralCollection;
use App\ViewModels\Logsys\LogsysRegistrationViewModel\LogsysRegistrationViewModel;
use App\ViewModels\Logsys\LogsysRegistrationViewModel\LogsysRegistrationViewModelBuilder;

class LogsysMapper {

	public static function getLogsysRegistrationVMFromArray($endpoint, $method,array $data): LogsysRegistrationViewModel {

		return LogsysRegistrationViewModel::builder()->setId_usuario($data['id_usuario'])
			->setHttp_verb($method)
			->setController($data['controller'])
			->setEndpoint($endpoint)
			->setObservacao($data['observacao'])
			->build();
	}
}

