libflame  revision_anchor
Functions
FLA_Apply_G.h File Reference

(r)

Go to the source code of this file.

Functions

FLA_Error FLA_Apply_G (FLA_Side side, FLA_Direct direct, FLA_Obj G, FLA_Obj A)
 
FLA_Error FLA_Apply_G_internal (FLA_Side side, FLA_Direct direct, FLA_Obj G, FLA_Obj A)
 

Function Documentation

◆ FLA_Apply_G()

FLA_Error FLA_Apply_G ( FLA_Side  side,
FLA_Direct  direct,
FLA_Obj  G,
FLA_Obj  A 
)

References FLA_Apply_G_check(), FLA_Apply_G_internal(), FLA_Check_error_level(), and FLA_Obj_has_zero_dim().

14 {
15  FLA_Error r_val;
16 
17  // Check parameters.
18  if ( FLA_Check_error_level() >= FLA_MIN_ERROR_CHECKING )
19  FLA_Apply_G_check( side, direct, G, A );
20 
21  if ( FLA_Obj_has_zero_dim( G ) ) return FLA_SUCCESS;
22 
23  // Invoke FLA_Apply_G_internal() to parse parameters.
24  r_val = FLA_Apply_G_internal( side, direct, G, A );
25 
26  return r_val;
27 }
int FLA_Error
Definition: FLA_type_defs.h:47
FLA_Bool FLA_Obj_has_zero_dim(FLA_Obj A)
Definition: FLA_Query.c:400
FLA_Error FLA_Apply_G_check(FLA_Side side, FLA_Direct direct, FLA_Obj G, FLA_Obj A)
Definition: FLA_Apply_G_check.c:13
FLA_Error FLA_Apply_G_internal(FLA_Side side, FLA_Direct direct, FLA_Obj G, FLA_Obj A)
Definition: FLA_Apply_G_internal.c:13
unsigned int FLA_Check_error_level(void)
Definition: FLA_Check.c:18

◆ FLA_Apply_G_internal()

FLA_Error FLA_Apply_G_internal ( FLA_Side  side,
FLA_Direct  direct,
FLA_Obj  G,
FLA_Obj  A 
)

References FLA_Apply_G_lf_opt_var1(), and FLA_Apply_G_rf_opt_var1().

Referenced by FLA_Apply_G().

14 {
15  FLA_Error r_val = FLA_SUCCESS;
16 
17  if ( side == FLA_LEFT )
18  {
19  if ( direct == FLA_FORWARD )
20  {
21  r_val = FLA_Apply_G_lf_opt_var1( G, A );
22  }
23  else if ( direct == FLA_BACKWARD )
24  {
25  FLA_Check_error_code( FLA_NOT_YET_IMPLEMENTED );
26  //r_val = FLA_Apply_G_lb_opt_var1( G, A );
27  }
28  }
29  else if ( side == FLA_RIGHT )
30  {
31  if ( direct == FLA_FORWARD )
32  {
33  r_val = FLA_Apply_G_rf_opt_var1( G, A );
34  }
35  else if ( direct == FLA_BACKWARD )
36  {
37  FLA_Check_error_code( FLA_NOT_YET_IMPLEMENTED );
38  //r_val = FLA_Apply_G_rb_opt_var1( G, A );
39  }
40  }
41 
42  return r_val;
43 }
FLA_Error FLA_Apply_G_lf_opt_var1(FLA_Obj G, FLA_Obj A)
Definition: FLA_Apply_G_lf_opt_var1.c:13
int FLA_Error
Definition: FLA_type_defs.h:47
FLA_Error FLA_Apply_G_rf_opt_var1(FLA_Obj G, FLA_Obj A)
Definition: FLA_Apply_G_rf_opt_var1.c:13