FrontISTR 5.2.0
Large-scale structural analysis program with finit element method
Loading...
Searching...
No Matches
CNFDB_100.cpp
Go to the documentation of this file.
1/*****************************************************************************
2 * Copyright (c) 2019 FrontISTR Commons
3 * This software is released under the MIT License, see LICENSE.txt
4 *****************************************************************************/
5/*
6 CNFDB_100 Ver.1.0
7 -----------------------------
8 100 Header
9*/
10
11#include "CNFData.h"
12#include "CNFDB_100.h"
13
14// 100 Header
15
17 title[0] = 0;
18 version = -1;
19}
20
22 char buff[256];
23 // #1
24 nfd->ReadLineEx(buff);
25 nfd->ReadStr(buff, title, sizeof(title));
26 // #2
27 nfd->ReadLineEx(buff);
28 nfd->ReadRecord(buff, "F", &version);
29}
30
31void CNFDB_100::WriteData(CNFData *nfd, FILE *fp) {
32 // #1
33 nfd->WriteStr(fp, title);
34 // #2
35 fprintf(fp, "%.1lf,\n", version);
36}
virtual void WriteData(class CNFData *nfd, FILE *fp)
Definition: CNFDB_100.cpp:31
virtual void Read(class CNFData *nfd)
Definition: CNFDB_100.cpp:21
nf_float version
Definition: CNFDB_100.h:29
nf_char title[256]
Definition: CNFDB_100.h:27
void WriteStr(FILE *fp, const char *s)
Definition: CNFData.cpp:452
void ReadStr(char *buff, char *s, int size)
Definition: CNFData.cpp:373
void ReadLineEx(char *buff, int size=255)
Definition: CNFData.cpp:367
void ReadRecord(char *buff, const char *fmt,...)
Definition: CNFData.cpp:308