/eidpt/Pin.cpp
C++ | 40 lines | 17 code | 3 blank | 20 comment | 0 complexity | 4fac8cb7f6e4c557f7ad5110e60a8a75 MD5 | raw file
Possible License(s): LGPL-3.0
1/* 2* Portuguese eID Card API .NET Wrapper 3* 4* Written by Fernando Nunes (fernando.nunes@devscope.net) 5* Copyright (c) 2009 DevScope Information Systems 6* 7* This library is free software; you can redistribute it and/or 8* modify it under the terms of the GNU Lesser General Public 9* License as published by the Free Software Foundation; either 10* version 2.1 of the License, or (at your option) any later version. 11* 12* This library is distributed in the hope that it will be useful, 13* but WITHOUT ANY WARRANTY; without even the implied warranty of 14* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 15* Lesser General Public License for more details. 16* 17* You should have received a copy of the GNU Lesser General Public 18* License along with this library; if not, write to the Free Software 19* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA 20*/ 21 22#pragma once 23#include "Stdafx.h" 24#include "Pin.h" 25#include "Interop.h" 26 27using namespace System; 28using namespace DevScope::CartaoDeCidadao; 29 30Pin::Pin(const PTEID_Pin& i) 31{ 32 this->Id = i.id; 33 this->Type = (PinType)i.pinType; 34 this->Usage = (PinUsage)i.usageCode; 35 this->TriesLeft = i.triesLeft; 36 this->Flags = i.flags; 37 this->Label = Interop::CStrToNetStr((char*)i.label); 38 this->ShortUsage = Interop::CStrToNetStr(i.shortUsage); 39 this->LongUsage = Interop::CStrToNetStr(i.longUsage); 40}