/****************************************************************************
**  SIONLIB     http://www.fz-juelich.de/jsc/sionlib                       **
*****************************************************************************
**  Copyright (c) 2008-2015                                                **
**  Forschungszentrum Juelich, Juelich Supercomputing Centre               **
**                                                                         **
**  See the file COPYRIGHT in the package base directory for details       **
****************************************************************************/
#ifndef SION_SION_DUP_H
#define SION_SION_DUP_H


/* SIONlib defines functions using FILE* parameter */
#include <stdio.h>

#include "sion_platform.h"
#include "sion_datatypes.h"

#ifdef __cplusplus
extern "C" {
#endif

  int _lsion_dup(int sid, int mode, int rank, uint64_t key);
  int _lsion_dedup( int sid );

  /* internal auxiliary  */
  int _lsion_dup_paropen( _sion_filedesc *sion_filedesc, _sion_filedesc *new_filedesc );
  int _lsion_dup_paropenmappedmaster( _sion_filedesc *sion_filedesc, _sion_filedesc *new_filedesc );
  int _lsion_dup_blocksizes( _sion_filedesc *sion_filedesc, _sion_filedesc *new_filedesc );
  int _lsion_dup_all_ds( _sion_filedesc *sion_filedesc, _sion_filedesc *new_filedesc );
  int _lsion_dup_keyvalptr( _sion_filedesc *sion_filedesc, _sion_filedesc *new_filedesc );
  int _lsion_dup_all_keyvalptr( _sion_filedesc *sion_filedesc, _sion_filedesc *new_filedesc );


#ifdef __cplusplus
}
#endif

#endif


