/*****************************************************************************
 * File:       A_ROW_xformGen.c
 *
 * Description:
 * Transformer action methods implementation for the following object:
 *
 * Object:     row  (ROW)
 * Domain:     A
 * Subsystem:  autosampler
 * Repository: as2.ooa
 *
 * Notice:
 *   (C) Copyright 1999, 2000 ROX Software, Inc.
 *   All rights reserved.
 *
 * Model Compiler:  MC3020 V1.3.0
 *
 * Warnings:
 *   !!! THIS IS AN AUTO-GENERATED FILE. PLEASE DO NOT EDIT. !!!
 ****************************************************************************/

#include "e_mechs.h"
#include "e_events.h"
#include "A_objects.h"
#include "A_ROW_object.h"
#include "A_ROW_events.h"
#include "A_ROW_xform.h"

/*****************************************************************************
 * Transformer: convert_dest
 ****************************************************************************/
int
A_ROW_Xform_convert_dest(
    const int x_next_sampling_position,
    const int x_radius )
{
  A_ROW_s * v2;  /* row */
  int v3;  /* car_dest */

  /* SELECT ANY row FROM INSTANCES OF ROW
     WHERE SELECTED.radius == PARAM.radius  */
  /* MC Spec: (selected.radius == ?) */
  v2 = A_ROW_AnyWhere1( x_radius );

  /* ASSIGN car_dest = (360 * (PARAM.next_sampling_position - 1)) / row.maximum_sampling_positions */
  v3 = (360 * (x_next_sampling_position - 1)) / v2->m_maximum_sampling_positions;

  return v3;

}