| 123 | |
| 124 | template<typename FloatType> |
| 125 | bool MatrixMarketReader<FloatType>::MMReadHeader( FILE* mm_file ) |
| 126 | { |
| 127 | int status = MMReadBanner( mm_file ); |
| 128 | if( status != 0 ) |
| 129 | { |
| 130 | printf( "Error Reading Banner in Matrix-Market File !\n" ); |
| 131 | return 1; |
| 132 | } |
| 133 | |
| 134 | if( !mm_is_coordinate( Typecode ) ) |
| 135 | { |
| 136 | printf( "Handling only coordinate format\n" ); return( 1 ); |
| 137 | } |
| 138 | |
| 139 | if( mm_is_complex( Typecode ) ) |
| 140 | { |
| 141 | printf( "Error: cannot handle complex format\n" ); |
| 142 | return ( 1 ); |
| 143 | } |
| 144 | |
| 145 | if( mm_is_symmetric( Typecode ) ) |
| 146 | isSymmetric = 1; |
| 147 | |
| 148 | status = MMReadMtxCrdSize( mm_file ); |
| 149 | if( status != 0 ) |
| 150 | { |
| 151 | printf( "Error reading Matrix Market crd_size %d\n", status ); |
| 152 | return( 1 ); |
| 153 | } |
| 154 | |
| 155 | return 0; |
| 156 | } |
| 157 | |
| 158 | template<typename FloatType> |
| 159 | bool MatrixMarketReader<FloatType>::MMReadHeader( const std::string &filename ) |
no outgoing calls
no test coverage detected