#include <stdio.h>
Go to the source code of this file.
#define FOPENERROR 3000 |
** (c) Copyright Hewlett-Packard Company, 1988. ** Licensed under the Apache License, Version 2.0 (the "License"); ** you may not use this file except in compliance with the License. ** You may obtain a copy of the License at ** http://www.apache.org/licenses/LICENSE-2.0 ** Unless required by applicable law or agreed to in writing, software ** distributed under the License is distributed on an "AS IS" BASIS, ** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. ** See the License for the specific language governing permissions and ** limitations under the License.
Definition at line 27 of file efio.h.
Referenced by Efopen().
FILE* Efopen | ( | const char * | Name, | |
const char * | Mode | |||
) |
Attempts to open the specified file in the specified mode.
Name | Name of file to be opened | |
Mode | Mode to be used to open file |
Definition at line 45 of file efio.cpp.
References DoError(), FOPENERROR, MAXERRORMESSAGE, and NULL.
Referenced by FillAmbigTable(), GetNormProtos(), InitAdaptiveClassifier(), LearnBlob(), ReadNewCutoffs(), WriteClusteredTrainingSamples(), WriteMergedTrainingSamples(), WriteMicrofeat(), WriteNormProtos(), WritePFFMTable(), and WriteTrainingSamples().
00045 { 00046 FILE *File; 00047 char ErrorMessage[MAXERRORMESSAGE]; 00048 00049 File = fopen (Name, Mode); 00050 if (File == NULL) { 00051 sprintf (ErrorMessage, "Unable to open %s", Name); 00052 DoError(FOPENERROR, ErrorMessage); 00053 return (NULL); 00054 } 00055 else 00056 return (File); 00057 } /* Efopen */