Passing Types,as types

I would like to be able to pass a type as a argument in a method, as a type not an instance of an object, so I can make a generalized method that can evaluate instanceof with a type.
Here is a Simple Example
  public interface MyType {
    public void someAction();
  public class SomeClass implements MyType{
     public void someAction(){
  public class Evaluate{
    public static boolean objectMatchesType(Object obj,type typeToMatch){
        return obj instanceof typeToMatch;
   public static void main(String[] args){
    if( objectMatchesType( new SomeClass() , MyType )
      System.out.println("Types Match");
  }I have tryed passing a class rather than an object but that didn't work.
Any Suggestions would be appreciated.

public static boolean objectMatchesType(Object obj, Class cls) {
    return cls.isAssignableFrom(obj.getClass());
if(objectMatchesType(obj, String.class))

Similar Messages

  • How to pass type variable in a procedure as IN parameter

    CREATE OR REPLACE PROCEDURE APPS."QFJS_LMO_TIMESLOT_PROC"
    a_std IN VARCHAR2,
    TYPE str_table IS TABLE OF CLOB INDEX BY BINARY_INTEGER;
    timeStr OUT str_table;
    This is giving error!!
    Please help!!

    This is what you're looking for? (you can also create the type in your database)
    CREATE OR REPLACE PACKAGE APPS.MY_PACKAGE AS
      PRAGMA SERIALLY_REUSABLE;
      TYPE str_table IS TABLE OF CLOB INDEX BY BINARY_INTEGER;
      PROCEDURE "QFJS_LMO_TIMESLOT_PROC"(a_std             IN VARCHAR2,
                                         post_std          IN VARCHAR2,
                                         a_time            IN VARCHAR2,
                                         post_hc           IN NUMBER,
                                         pre_hc            IN NUMBER,
                                         ods_schedule_date IN DATE,
                                         timeStr           IN OUT str_table);
    END MY_PACKAGE;
    CREATE OR REPLACE PACKAGE BODY APPS.MY_PACKAGE IS
      PRAGMA SERIALLY_REUSABLE;
      PROCEDURE "QFJS_LMO_TIMESLOT_PROC"(a_std             IN VARCHAR2,
                                         post_std          IN VARCHAR2,
                                         a_time            IN VARCHAR2,
                                         post_hc           IN NUMBER,
                                         pre_hc            IN NUMBER,
                                         ods_schedule_date IN DATE,
                                         timeStr           IN OUT str_table) IS
    v_clob clob;
      BEGIN
        FOR i IN 1 .. timeStr.COUNT LOOP
          v_clob := timeStr(i);
        END LOOP;
      END "QFJS_LMO_TIMESLOT_PROC";
    BEGIN
      NULL;
    END MY_PACKAGE;
    BEGIN
      APPS.MY_PACKAGE.QFJS_LMO_TIMESLOT_PROC('1','2','3',4,5,sysdate,APPS.MY_PACKAGE.str_table('clob1', 'clob2', 'clob3'));
    END;
    / -- Hugs, Philips

  • Problem in passing select-options to class meathods , type any table

    <h1>how to pass type any table to class meathod</h1>
    <h3>hi all
           i'm trying to build class to validate the selection screen , like select-options and parameters
           while writing meathod to validate the select-options
           its throwing parameter mismath error</h3>
    <h4>i tried like made import parameter in class meathod as 'TYPE ANY TABLE' and tried to pass select-options from my program it is saying type mismatch , how to overcome this problem </h4>
    <h4>and i want to pass any select option , either of type lfa1-lifnr or mara-matnr or any other</h4>
    Moderator message : Don't shout, use proper font size for explaining the question. This has been discussed in ABAP forums before. Search for available information. Thread locked.
    Edited by: Vinod Kumar on Sep 14, 2011 11:20 AM

    hI
    Triggering and Handling events
    At the moment of implementation, a class defines its:
             Instance events (using the EVENTS statement)
            Static events (using the CLASS-EVENTS statement)
    Classes or their instances that receive a message when an event is triggered at runtime and want to react to this event define event handler methods. Statement: METHODS
    CLASS IC1_VEICHLE DEFINATION.
    PUBLIC SECTION.
    METHOD CONSTRUCTOR IMPORTING
    EVENTS VEICHEL_CREATION.
    ENDCLASS
    CLASS LC1_VEICHLE IMPLIMENTATION.
    METHOD CONSTRUCTOR
    RAISE EVENT VEICHLE_CREATION.
    REWARD IF USEFULL

  • How to integrate c# library's function to use F# type expression for function of function?

    i succeed to implement the initial prototype for function structure in c#
    but i do not know how to integrate in F#
    i make c# library's function to accept template T, for F# to pass type expression into it.
    but how to write in c# to make template like type expression, 
    in Addvaluetoeachitem
    hope make function structure depend on left or right, i got twisted in my mind when integrating into F#
    if translate c# into F# , how to write for this class?
    func1(func1(param1, param2), param2) etc
    if i define funcvalue as
    type expr =
    | And of expr * expr
    | Or of expr * expr
    expr[] funcvalues = new expr[] {And, Or, And, Or, And, Or, And}
    int[] values = new int[] { 1, 2, 3, 4, 5, 6, 7 };
    got some error when translate member value and constructor into F#
    // Learn more about F# at http://fsharp.net
    // See the 'F# Tutorial' project for more help.
    open System.Collections.Generic
    type expr =
    | And of expr * expr
    | Or of expr * expr
    | Param1
    type BinaryTree =
    let mutable value = 0
    let left : BinaryTree = null
    let right : BinaryTree = null
    let mutable dict : Dictionary<int, BinaryTree> = new Dictionary<int, BinaryTree>();
    member this.Load(tree : BinaryTree, values : int[], index : int) =
    this.value = values.[index];
    if index * 2 + 1 < values.Length then
    this.left = new BinaryTree(values, index * 2 + 1)
    if index * 2 + 2 < values.Length then
    this.right = new BinaryTree(values, index * 2 + 2)
    new() = BinaryTree(values : int[]) : this(values, 0) { }
    //public BinaryTree(int[] values) : this(values, 0) { }
    new() = BinaryTree(values : int[], index : int)
    let dict = new Dictionary<int, BinaryTree>()
    Load(this, values, index)
    member this.Visit(tree : BinaryTree) =
    dict.Add(dict.Count, tree);
    member this.ChangeToString(m : List<int>) : String =
    let result = "";
    for i in m do
    result = result + i.ToString()
    result
    member this.CopyList(queue : Queue<List<int>>) : Queue<List<int>> =
    let mutable newqueue : Queue<List<int>> = new Queue<List<int>>();
    if queue != null then
    while (queue.Count > 0) do
    let source : List<int> = queue.Dequeue()
    let destination : List<int> = new List<int>();
    for a in source do
    destination.Add(a);
    newqueue.Enqueue(destination)
    for m in newqueue do
    queue.Enqueue(m);
    newqueue
    member this.IsAscending(m : List<int>) : bool =
    let mutable result = true
    let mutable prev : int = 0
    for i in m do
    if prev > i then
    result <- false
    prev <- i
    result
    member this.Addvaluetoeachitem(queue : Queue<List<int>>, value : int, maxlimit : int, ref Dictionary<String , List<int>> allpath, Boolean IsBackUp, T func1, T param1, T param2, Dictionary<T, T> allfunctionstructure, Queue<List<T>> funcqueue, Boolean LeftOrRight) : Queue<List<int>>=
    let newqueue : Queue<List<int>> = new Queue<List<int>>()
    if queue != null then
    while queue.Count > 0 do
    List<int> path = queue.Dequeue();
    //List<T> func = funcqueue.Dequeue();
    let mutable afteradd = false
    if path.Count < maxlimit then
    path.Add(value);
    afteradd <- true
    if path.Count = maxlimit && afteradd = true && IsBackUp = false then
    if IsAscending(path) = true then
    if allpath.ContainsKey(ChangeToString(path)) = false then
    allpath.Add(ChangeToString(path), path)
    newqueue.Enqueue(path);
    if queue = null then
    let mutable path : List<int> = new List<int>();
    let mutable afteradd = false
    if path.Count < maxlimit then
    path.Add(value)
    afteradd <- true
    if path.Count == maxlimit && afteradd == true && IsBackUp = false then
    if IsAscending(path) = true then
    if allpath.ContainsKey(ChangeToString(path)) = false then
    allpath.Add(ChangeToString(path), path)
    newqueue.Enqueue(path)
    else
    if queue.Count = 0 then
    let mutable path : List<int> = new List<int>();
    let mutable afteradd = false
    if path.Count < maxlimit then
    path.Add(value)
    afteradd <- true
    if path.Count = maxlimit && afteradd = true && IsBackUp = false then
    if IsAscending(path) == true then
    if allpath.ContainsKey(ChangeToString(path)) = false then
    allpath.Add(ChangeToString(path), path)
    newqueue.Enqueue(path)
    newqueue
    member this.Deepfirst(tree : BinaryTree, ref queuepath : Queue<List<int>>, backpath : Queue<List<int>>, maxlimit : int, ref allpath : Dictionary<String, List<int>>, func1 : expr, param1 : expr, param2 : expr, allfunctionstructure : Dictionary<expr, expr>, ref queuefunc : Queue<List<expr>>, LeftOrRight : bool) : Queue<List<int>>=
    queuepath = Addvaluetoeachitem(queuepath, tree.value, maxlimit, ref allpath, false, func1, param1, param2, allfunctionstructure, queuefunc, LeftOrRight);
    //path.Add(tree.value);
    Queue<List<int>> newpath = new Queue<List<int>>();
    newpath = CopyList(queuepath);
    Queue<List<int>> newpath2 = new Queue<List<int>>();
    newpath2 = CopyList(queuepath);
    backpath = Addvaluetoeachitem(backpath, tree.value, maxlimit, ref allpath, false, func1, param1, param2, allfunctionstructure, queuefunc, LeftOrRight);
    //Queue<List<int>> backpathx = new Queue<List<int>>();
    Queue<List<int>> backpathx = backpath;//Addvaluetoeachitem(backpathx, tree.value, maxlimit, ref allpath, false);
    Queue<List<int>> newpathx = new Queue<List<int>>();
    newpathx = CopyList(queuepath);
    Queue<List<int>> backpath1 = backpathx;
    if tree.left != null then
    newpathx = Deepfirst(tree.left, ref newpath, newpathx, maxlimit, ref allpath, func1, param1, param2, allfunctionstructure, ref queuefunc, false) // Left
    if tree.value = 1 then
    Console.WriteLine("")
    Visit(tree)
    for m in queuepath do
    newpath2.Enqueue(m)
    let mutable backpath2 : Queue<List<int>> = newpathx
    if tree.right != null then
    newpathx = Deepfirst(tree.right, ref newpath2, newpathx, maxlimit, ref allpath, func1, param1, param2, allfunctionstructure, ref queuefunc, true) // Right
    if tree.value = 1 then
    Console.WriteLine("")
    if newpathx != null then
    return newpathx
    if backpath2 != null then
    return backpath2
    if backpath1 != null then
    return backpath1
    if backpath != null then
    return backpath
    else
    return backpath
    [<EntryPoint>]
    let main argv =
    printfn "%A" argv
    0 // return an integer exit code
    BinaryTree<int> b = new BinaryTree<int>(values);
    Queue<List<int>> queuepath = new Queue<List<int>>();
    Queue<List<int>> backpath = null;
    Queue<List<int>> queuefunc = new Queue<List<int>>();
    Dictionary<String, List<int>> allpath = new Dictionary<String, List<int>>();
    Dictionary<int, int> allfunctionstructure = new Dictionary<int, int>();
    int a3 = 0;
    int b3 = 0;
    int c3 = 0;
    queuepath = b.Deepfirst(b, ref queuepath, backpath, 3, ref allpath, a3, b3, c3, allfunctionstructure, ref queuefunc, false);
    using System;
    using System.Collections.Generic;
    using System.Linq;
    using System.Text;
    using System.Threading.Tasks;
    namespace testTable
    public class BinaryTree<T>
    public int value;
    BinaryTree<T> left;
    BinaryTree<T> right;
    public Dictionary<int, BinaryTree<T>> dict;
    public BinaryTree(int[] values) : this(values, 0) { }
    BinaryTree(int[] values, int index)
    dict = new Dictionary<int, BinaryTree<T>>();
    Load(this, values, index);
    public void Visit(BinaryTree<T> tree)
    dict.Add(dict.Count, tree);
    public String ChangeToString(List<int> m)
    String result = "";
    foreach (int i in m)
    result = result + i.ToString();
    return result;
    public Queue<List<int>> CopyList(Queue<List<int>> queue)
    Queue<List<int>> newqueue = new Queue<List<int>>();
    if (queue != null)
    while (queue.Count > 0)
    List<int> source = queue.Dequeue();
    List<int> destination = new List<int>();
    foreach (int a in source)
    destination.Add(a);
    newqueue.Enqueue(destination);
    foreach (List<int> m in newqueue)
    queue.Enqueue(m);
    return newqueue;
    public Boolean IsAscending(List<int> m)
    Boolean result = true;
    int prev = 0;
    foreach (int i in m)
    if (prev > i)
    result = false;
    prev = i;
    return result;
    public Queue<List<int>> Addvaluetoeachitem<T>(Queue<List<int>> queue, int value, int maxlimit, ref Dictionary<String , List<int>> allpath, Boolean IsBackUp, T func1, T param1, T param2, Dictionary<T, T> allfunctionstructure, Queue<List<T>> funcqueue, Boolean LeftOrRight)
    Queue<List<int>> newqueue = new Queue<List<int>>();
    if (queue != null)
    while (queue.Count > 0)
    List<int> path = queue.Dequeue();
    //List<T> func = funcqueue.Dequeue();
    Boolean afteradd = false;
    if (path.Count < maxlimit)
    path.Add(value);
    afteradd = true;
    if (path.Count == maxlimit && afteradd == true && IsBackUp == false)
    if( IsAscending(path) == true)
    if(allpath.ContainsKey(ChangeToString(path)) == false)
    allpath.Add(ChangeToString(path), path);
    newqueue.Enqueue(path);
    if (queue == null)
    List<int> path = new List<int>();
    Boolean afteradd = false;
    if (path.Count < maxlimit)
    path.Add(value);
    afteradd = true;
    if (path.Count == maxlimit && afteradd == true && IsBackUp == false)
    if (IsAscending(path) == true)
    if (allpath.ContainsKey(ChangeToString(path)) == false)
    allpath.Add(ChangeToString(path), path);
    newqueue.Enqueue(path);
    else
    if (queue.Count == 0)
    List<int> path = new List<int>();
    Boolean afteradd = false;
    if (path.Count < maxlimit)
    path.Add(value);
    afteradd = true;
    if (path.Count == maxlimit && afteradd == true && IsBackUp == false)
    if (IsAscending(path) == true)
    if (allpath.ContainsKey(ChangeToString(path)) == false)
    allpath.Add(ChangeToString(path), path);
    newqueue.Enqueue(path);
    return newqueue;
    public Queue<List<int>> Deepfirst(BinaryTree<T> tree, ref Queue<List<int>> queuepath, Queue<List<int>> backpath, int maxlimit, ref Dictionary<String, List<int>> allpath, T func1, T param1, T param2, Dictionary<T, T> allfunctionstructure, ref Queue<List<T>> queuefunc, Boolean LeftOrRight)
    //if (path.Count < maxlimit)
    queuepath = Addvaluetoeachitem(queuepath, tree.value, maxlimit, ref allpath, false, func1, param1, param2, allfunctionstructure, queuefunc, LeftOrRight);
    //path.Add(tree.value);
    Queue<List<int>> newpath = new Queue<List<int>>();
    newpath = CopyList(queuepath);
    Queue<List<int>> newpath2 = new Queue<List<int>>();
    newpath2 = CopyList(queuepath);
    backpath = Addvaluetoeachitem(backpath, tree.value, maxlimit, ref allpath, false, func1, param1, param2, allfunctionstructure, queuefunc, LeftOrRight);
    //Queue<List<int>> backpathx = new Queue<List<int>>();
    Queue<List<int>> backpathx = backpath;//Addvaluetoeachitem(backpathx, tree.value, maxlimit, ref allpath, false);
    Queue<List<int>> newpathx = new Queue<List<int>>();
    newpathx = CopyList(queuepath);
    Queue<List<int>> backpath1 = backpathx;
    if (tree.left != null)
    newpathx = Deepfirst(tree.left, ref newpath, newpathx, maxlimit, ref allpath, func1, param1, param2, allfunctionstructure, ref queuefunc, false); // Left
    if (tree.value == 1)
    Console.WriteLine("");
    Visit(tree);
    if (backpath1 != null)
    Boolean afteradd = false;
    if (backpath1.Count < maxlimit)
    backpath1.Add(tree.value);
    afteradd = true;
    if (backpath1.Count == maxlimit && afteradd == true)
    allpath.Add(backpath1);
    foreach (List<int> m in queuepath)
    newpath2.Enqueue(m);
    Queue<List<int>> backpath2 = newpathx;
    if (tree.right != null)
    newpathx = Deepfirst(tree.right, ref newpath2, newpathx, maxlimit, ref allpath, func1, param1, param2, allfunctionstructure, ref queuefunc, true); // Right
    if (tree.value == 1)
    Console.WriteLine("");
    //Queue<List<int>> newpath3 = new Queue<List<int>>();
    //newpath3 = CopyList(queuepath); // 2 -> 1 -> 3 1(2,3) difficult case
    //return newpath3;
    if (newpathx != null)
    return newpathx;
    if(backpath2 != null)
    return backpath2;
    if (backpath1 != null)
    return backpath1;
    if (backpath != null)
    return backpath;
    else
    return backpath;
    public void Load(BinaryTree<T> tree, int[] values, int index)
    this.value = values[index];
    if (index * 2 + 1 < values.Length)
    this.left = new BinaryTree<T>(values, index * 2 + 1);
    if (index * 2 + 2 < values.Length)
    this.right = new BinaryTree<T>(values, index * 2 + 2);
    computing nightmare

    This builds, and fixes the most egregious style issues
    open System
    open System.Collections.Generic
    type expr =
    | And of expr * expr
    | Or of expr * expr
    | Param1
    [<AllowNullLiteral>]
    type BinaryTree(values : int[], index : int) =
    let value = values.[index]
    let left = if index * 2 + 1 < values.Length then
    BinaryTree(values, index * 2 + 1)
    else null
    let right = if index * 2 + 2 < values.Length then
    BinaryTree(values, index * 2 + 2)
    else null
    let dict : Dictionary<int, BinaryTree> = new Dictionary<int, BinaryTree>();
    new(values : int[]) = BinaryTree(values, 0)
    member this.Value with get() = value
    member this.Left with get() = left
    member this.Right with get() = right
    member this.Visit(tree : BinaryTree) =
    dict.Add(dict.Count, tree);
    static member ChangeToString(m : List<int>) : String =
    String.Join(String.Empty, m)
    static member CopyList(queue : Queue<List<int>>) : Queue<List<int>> =
    let newqueue = Queue<List<int>>();
    if queue <> null then
    while (queue.Count > 0) do
    let source : List<int> = queue.Dequeue()
    let destination : List<int> = new List<int>();
    for a in source do
    destination.Add(a);
    newqueue.Enqueue(destination)
    for m in newqueue do
    queue.Enqueue(m);
    newqueue
    static member IsAscending(m : List<int>) : bool =
    m
    |> Seq.pairwise
    |> Seq.forall (fun (x,y) -> y > x)
    static member Addvaluetoeachitem(
    queue : Queue<List<int>>,
    value : int,
    maxlimit : int,
    allpath : Dictionary<String , List<int>> byref,
    isBackUp : Boolean,
    func1 : 'T,
    param1 : 'T,
    param2 : 'T,
    allfunctionstructure : Dictionary<'T, 'T>,
    funcqueue : Queue<List<'T>>,
    leftOrRight : Boolean) : Queue<List<int>>=
    let newqueue : Queue<List<int>> = new Queue<List<int>>()
    if queue <> null then
    while queue.Count > 0 do
    let path = queue.Dequeue();
    let afteradd = path.Count < maxlimit
    if afteradd then
    path.Add(value)
    if path.Count = maxlimit && afteradd && (not isBackUp) then
    if BinaryTree.IsAscending(path) then
    if allpath.ContainsKey(BinaryTree.ChangeToString(path)) = false then
    allpath.Add(BinaryTree.ChangeToString(path), path)
    newqueue.Enqueue(path);
    if (queue = null) || (queue.Count = 0) then
    let path = List<int>();
    let afteradd = path.Count < maxlimit
    if afteradd then
    path.Add(value)
    if path.Count = maxlimit && afteradd && (not isBackUp) then
    if BinaryTree.IsAscending(path) then
    if not <| allpath.ContainsKey(BinaryTree.ChangeToString(path)) then
    allpath.Add(BinaryTree.ChangeToString(path), path)
    newqueue.Enqueue(path)
    newqueue
    member this.Deepfirst(tree : BinaryTree,
    queuepath : Queue<List<int>> byref,
    backpath : Queue<List<int>> byref,
    maxlimit : int,
    allpath : Dictionary<String, List<int>> byref,
    func1 : expr, param1 : expr, param2 : expr,
    allfunctionstructure : Dictionary<expr, expr>,
    queuefunc : Queue<List<expr>> byref,
    leftOrRight : bool) : Queue<List<int>>=
    queuepath <- BinaryTree.Addvaluetoeachitem(queuepath, tree.Value, maxlimit, ref allpath, false, func1, param1, param2, allfunctionstructure, queuefunc, leftOrRight);
    let newpath = BinaryTree.CopyList(queuepath);
    let newpath2 = BinaryTree.CopyList(queuepath);
    backpath <- BinaryTree.Addvaluetoeachitem(backpath, tree.Value, maxlimit, ref allpath, false, func1, param1, param2, allfunctionstructure, queuefunc, leftOrRight);
    let backpathx = backpath;
    let mutable newpathx = BinaryTree.CopyList(queuepath);
    let backpath1 = backpathx;
    if tree.Left <> null then
    newpathx <- this.Deepfirst(tree.Left, ref newpath, ref newpathx, maxlimit, ref allpath, func1, param1, param2, allfunctionstructure, ref queuefunc, false) // Left
    if tree.Value = 1 then
    Console.WriteLine("")
    this.Visit(tree)
    for m in queuepath do
    newpath2.Enqueue(m)
    let backpath2 = newpathx
    if tree.Right <> null then
    newpathx <- this.Deepfirst(tree.Right, ref newpath2, ref newpathx, maxlimit, ref allpath, func1, param1, param2, allfunctionstructure, ref queuefunc, true) // Right
    if tree.Value = 1 then
    Console.WriteLine("")
    if newpathx <> null then
    newpathx
    else if backpath2 <> null then
    backpath2
    else if backpath1 <> null then
    backpath1
    else backpath

  • Setting a Type property on a custom object in XAML

    I have the following converter which needs to know the Enum type to parse. 
    public class EnumToStringConverter : IValueConverter
    public Type EnumType { get; set; }
    public object Convert(object value, Type targetType, object parameter, string language)
    public object ConvertBack(object value, Type targetType, object parameter, string language)
    Then I declare the type in XAML using the same syntax used for styles.
    <UserControl x:Class="MyProject.PreferencesPage"
    xmlns="..."
    xmlns:converters="using:MyProject.Converters"
    xmlns:model="using:MyProject.Model">
    <UserControl.Resources>
    <converters:EnumToStringConverter x:Key="EnumToStringConverter" EnumType="model:ResultSize" />
    </UserControl.Resources>
    <!-- ... -->
    </UserControl>
    I don't get any squiggle lines, but I get a parse error at runtime.
    This is the error:
       An exception of type 'Windows.UI.Xaml.Markup.XamlParseException' occurred in BingImageSearch.exe but was not handled in user code
       Additional information: Failed to create a 'Windows.UI.Xaml.Interop.TypeName' from the text 'model:ResultSize'. [Line: 14 Position: 82]
    IIRC, this syntax was restricted to TargetType properties on styles and templates in WPF and Silverlight, is this still the case?

    I just came on here to look for this issue since I ran into the same thing. We absolutely should be able to set a Type-based property in XAML.  We can in WPF and SL.  Please either fix this TypeName error bug or at least provide us with the
    x:Type markup extension so that we can pass types directly to dependency properties in XAML with type checking.
    Can someone from Microsoft respond to this request?
    actiprosoftware.com - Professional WPF, WinRT, Silverlight, and WinForms UI controls and components

  • How to declare a param. of type RANGE OF in a method (or function module)?

    Hello,
    I've got a following problem.
    I want to pass a value of type RANGE OF to a method declared in
    an interface (the interface is built using Class Builder). I don't know
    how to do that and I did not manage to find a solution using both
    SAP help and google.
    Did anybody have the same problem before?
    Best regards
    Pawel

    Ok, I find a workaround. Maybe it will be useful for somebody in the future.
    Declare the parameter type as ANY TABLE and then cast it to the expected type
    in the body of the method.
    So for example.
    Parameter          Type        Typing Method        Associated Type     
    I_RNG_DATUM Importing Type                         ANY TABLE
    In the body of the method.
    TYPES:
        erdat_range TYPE RANGE OF erdat.
      FIELD-SYMBOLS:
        <l_fs_rng_erdat> TYPE erdat_range.
      DATA:
        l_ref_to_range TYPE REF TO data.
      GET REFERENCE OF i_rng_datum INTO l_ref_to_range.
      ASSIGN l_ref_to_range->* TO <l_fs_rng_erdat> CASTING.
    However, if somebody know how to pass type RANGE OF
    explicitely, the right answer is still welcome.
    Best regards
    Pawel

  • Pass filter value to a column

    Hi all,
    I am using oracle bi ee 11g. I am planning to create a report which contains two columns namely "ACTUAL" and "BUDGET"
    ACTUAL:
    FILTER("SUMMARY"."ACTUAL" USING (("SCENARIO"."SCENARIO_NAME" = F_ACT) AND ("CURRENCYH"."CURRENCY_CODE" = 'USD')))
    BUDGET:
    FILTER("SUMMARY"."ACTUAL" USING (("SCENARIO"."SCENARIO_NAME" =*F_BUD*) AND ("CURRENCYH"."CURRENCY_CODE" = 'USD')))
    In my database i have a field called scenario which has a actual and 5 budget values.
    I need to pass that actual value to F_ACT and that 5 budget values to that F_BUD(By using filter).
    Is it possible? If so please guide me? It is very urgent
    Thanks
    Maya

    Probably you may not have understanded my question properly i will explain it below
    name     number      type        count    person number
    james 45 Actual 3 1234
    above mentioned is the format of the report Person Number Column values contains a hyperlink to a another environment and if the user click on COUNT column it navigates to a seperate report and it should pass Person Number and type as filters i am able to pass type but not Person Number since it is in HTML format if we change that to general format the hyperlink doesn't work so i need to keep that in HTML format and i need pass that as filter to next report.

  • Passing HTML column as filter

    Hi All,
    I have a requirement where i wrote go url syntax on the column formula if they click on that value it will navigate them to a real time environment page there in the data format of that column i made it as a HTML content i need to use this same column as a filter but when i am trying to pass this column value as a is prompted filter its not passing is there a work around.
    ex:
    person no ---> Column Name
    1234 ------> all this values are hyper linked need to pass this values to the next report as a is prompted value
    1235
    1236
    1237

    Probably you may not have understanded my question properly i will explain it below
    name     number      type        count    person number
    james 45 Actual 3 1234
    above mentioned is the format of the report Person Number Column values contains a hyperlink to a another environment and if the user click on COUNT column it navigates to a seperate report and it should pass Person Number and type as filters i am able to pass type but not Person Number since it is in HTML format if we change that to general format the hyperlink doesn't work so i need to keep that in HTML format and i need pass that as filter to next report.

  • Can't pass arraylist?

    I am running my webservice that returns a set of values from a database. It will return a value as a string no problem, so I know it is connecting. It is now giving me a "nullpointerexception" error when I try to print out the first value(or any) in my arraylist. I am assuming it won't pass this type. I tried passing type CachedRowSet and it wouldn't even run, it gave a WSDL parsing error.
    Does anyone know how to pass an ArrayList or a CachedRowSet to a client? Or how to populate a ResultSet with more than one value when you have more than one SQL statement bringing info into it? (It was writing over the old value with the new value everytime it went through the loop.)
    Here is my server side code to generate the arraylist...
                ResultSet rs = stmt.executeQuery(query);
                int i = 0;
                Object arrayValue;
                while (rs.next()){
                    arrayValue = rs.getString("end_phrase");
                    returnArray.add(arrayValue);
                conn.close();
                return returnArray;Here is the client side bringing it in...
    resultArray = myProxy.sayHello(rapArray);
                String objectName = (String) resultArray.get(0);
                System.out.println(objectName);         

    Arbitrary classes (user defined or as mentioned 'CatchedRowSet' are allowed if they full fill this criteria :
    To be supported by JAX-RPC, an application class must conform to the follow-ing rules:
    � It must have a public default constructor.
    � It must not implement (either directly or indirectly) the java.rmi.Remote interface.
    � Its fields must be supported JAX-RPC types.
    The class may contain public, private, or protected fields. For its value to be passed (or returned) during a remote call, a field must meet these requirements:
    � A public field cannot be final or transient.
    � A non-public field must have corresponding getter and setter methods.
    Surely ArrayList is supported.
    Check if ArrayList obtained is not null(there are records) and has size >1
    --Ashwani                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                               

  • Last Pass KeePass(x/2/x2)

    So with all of these issues surrounding sites being hacked, databases being stolen, governments doing shady things and the cloud being not nearly as trustworthy as people make it out to be, I'm looking to set up my own pseudo last pass type of a setup.
    I'm running arch linux on my primary desktop, linux mint on my primary laptop, ubuntu on my central media/whatever I want to do server with an unlocked android phone.
    I'm sure my ignorance is going to shine through here, so let me start by saying up to this point I haven't used lastpass or keepass(or any of it's alternative implementations)
    What my dream would be would be to have a central keepass server set up on my server and have keepass clients on all of my devices that either access or constantly sync up with the database on the server. I would really like to have browser plugins (firefox and firefox mobile) that will auto-fill for all the websites that I go to because I'm planning on using very complex randomly generated passwords that would be extremely secure and impossible to remember. I want to be something that I can set up and just point everything at it and forget it. Seamless. What's the best way to do this while being as compatible as possible? Keepassx? Keepassx 2? Keepass 2 using mono? I have my concerns with using Keepass 2 with mono as I'm not sure that it's really intended to be run on linux and it could be left in the dust eventually or something could be done to break compatibility since it's primary goal is to be run on windows, but then Keepassx 2 is in alpha and moving at a snail's pace from what I can see, plus I don't know if it's production ready seeing as how it is alpha. Then there is just regular Keepassx which I'm not sure if that's just antequated and doesn't support the feature set I need.
    Does anyone have any input or ideas? Is this possible or is it all just a pipe dream?

    Keepassc has a server-client mode (I have not tested that aspect of it, however). No browser auto-fill, though...there is a single keypress to copy username, then another to copy the password. I personally prefer to use btsync (or Dropbox in the past) to keep a copy of the password database sync'd between computers.
    Scott

  • Error in creation of Object Type from XML passed

    Hi,
    I am facing a problem creating a appropriate a object type for a XML.
    Below are the details:
    XML Passed
    <mer_offer_action_data>
    <form_id>
    134039588
    </form_id>
    <action_cd>
    OA
    </action_cd>
    <offer_decline_reason_cd>
    </offer_decline_reason_cd>
    <start_dt>
    </start_dt>
    <candidate>
    <ds_prs_id>
    109315
    </ds_prs_id>
    <ds_prs_id>
    110534
    </ds_prs_id>
    <ds_prs_id>
    110059
    </ds_prs_id>
    </candidate>
    </mer_offer_action_data>
    Types Declaration
    +CREATE OR REPLACE type MER_OFF_CANDIDATE
    AS
    OBJECT
    DS_PRS_ID NUMBER
    CREATE OR REPLACE TYPE MER_OFF_CANDIDATE_t
    AS
    TABLE OF MER_OFF_CANDIDATE;
    CREATE OR REPLACE type MER_OFFER_ACT_DATA
    AS
    OBJECT
    FORM_ID NUMBER,
    ACTION_CD VARCHAR2(6),
    OFFER_DECLINE_REASON_CD VARCHAR2(6),
    START_DT VARCHAR2(11),
    CANDIDATE MER_OFF_CANDIDATE_t
    CREATE OR REPLACE TYPE MER_OFFER_ACT_DATA_t
    AS
    TABLE OF MER_OFFER_ACT_DATA;
    CREATE OR REPLACE type MER_OFFER_ACTION_DATA
    AS
    OBJECT
    MER_OFF_ACT_DATA MER_OFFER_ACT_DATA_t
    /+
    My Declaration
    +merOffActDataXML      xmltype;
    merOffActData     MER_OFFER_ACTION_DATA := MER_OFFER_ACTION_DATA(MER_OFFER_ACT_DATA_t());+
    Inside Pl/SQL block
    +-- Converts XML data into user defined type for further processing of data
    xmltype.toobject(merOffActDataXML,merOffActData);+
    when I run the Pl/Sql block it gives me error
    ORA-19031: XML element or attribute FORM_ID does not match any in type ORADBA.MER_OFFER_ACTION_DATA
    which means the object type mapping is wrong
    I would like to know whether the object type I had created is correct or not.
    Thanks for your help
    Beda

    Bedabrata Patel wrote:
    Below are the details:The details except for a description of the problem
    I am facing a problem creating a appropriate a object type for a XML.And which error you are getting
    Error in creation of Object Type http://download.oracle.com/docs/cd/E11882_01/server.112/e10880/toc.htm
    And which version of Oracle you are getting the unknown error creating the unknown problem.

  • Pass String[] (String Array) type to a parameter in "Edit Action Binding"

    Hi
    Hope you are doing fine. This is very important to me, kindly help me in this regad.
    I have a scenario where I need to pass in a parameter of type String[] that has only one value {"Name"} to a webservice that returns some values.
    I've created a WS datacontrol, dragged and dropped the return value on to a jspx, then it asks me to give the input value
    How do I pass it to the Parameter in "Edit Action Binding"?
    When I say new String[]{"Name"}, it gives me the following error
    Cannot create an object of type:[Ljava.lang.String; from type:java.lang.String with value:new String[]{"Name"}
    Similarly, I hardcoded this value in a managedBean, added it to requestScope/applicationScope and queried it using #{applicationScope.AppCreationBean.epsName}
    But this time, it says, the value is null. I guess the value is not getting initialized properly. But if i hardcode the value in the getter method, I'm again getting the error as above.
    Would some one tell me how to pass an array of type String (ie, String[]) with a value "Name" in the "Edit Action Binding" wizard itself?
    Regards
    RaviKiran

    Hi Frank
    Thanks for the reply.
    Issue resolved by initializing it in the ManagedBean.
    For some reason, when I put it in request/application scopes, it was coming as null, but when I registered the Bean in PageFlowScope, it was working!
    Regards
    RaviKiran

  • How can I pass an empty array to a parameter of type PLSQLAssociativeArray

    How can I pass an empty array to a parameter of type PLSQLAssociativeArray in VB? I defined the parameter like this
    Dim myArray() as String = new String() {}
    Dim myPara as new Oracle.DataAccess.Client.OracleCollectionType.PLSQLAssociativeArray
    myPara = 0
    myPara.Value = myArray
    When I execute my stored procedure giving the above parameter, I got error saying OracleParameter.Value is invalid.
    I have tried to give it the DBNull.Value, but it doesn't work either.
    Note: everything works fine as long as myArray has some item in there. I just wonder how I can make it works in case I have nothing.
    Thank you,

    How can I pass an empty array to a parameter of type PLSQLAssociativeArray in VB? I defined the parameter like this
    Dim myArray() as String = new String() {}
    Dim myPara as new Oracle.DataAccess.Client.OracleCollectionType.PLSQLAssociativeArray
    myPara = 0
    myPara.Value = myArray
    When I execute my stored procedure giving the above parameter, I got error saying OracleParameter.Value is invalid.
    I have tried to give it the DBNull.Value, but it doesn't work either.
    Note: everything works fine as long as myArray has some item in there. I just wonder how I can make it works in case I have nothing.
    Thank you,

  • Where do we pass tax condation type and condation value in this bapi: SD_SALESDOCUMENT_CHANGE

    Hi Experts,
    I am using this to change sales order. SD_SALESDOCUMENT_CHANGE
    I am passing condation type and condation values for each line item under table parameter CONDATION_IN.  Here in which fields do i need pass tax condation type and condation value.
    please give me suggestion it is really help ful.
    Thanks
    laxmi

    Hi ,
    Pass condition type and condition value in fields COND_TYPE and COND_VALUE under table parameter CONDATION_IN. Also pass 'X' to above fields in table parameter of CONDITIONS_INX.

  • Passing array to pl/sql procedure - pls-00306 wrong number/types of args

    its oracle 10.2 database;
    I have a procedure with array parameters based on simple sql types.
    eg
    create or replace type vt_attrname is table of varchar2(50);
    Now my call to the procedure works when the array is empty;
    as soon as I bulk collect into my local array, I get a compilation error.
    eg
    declare
    my_array  vt_attrname;
    begin
    select label
      bulk collect
      into my_array
      from table_name
    where 1=1;
    my_proc(p_array=>my_array);  -- syntax error
    end;if I pass null the call works but obviously array is empty.
    I have read something about varray's being incompatible between sqltypes and pl/sql.
    How do I get around this problem?
    The bulk collect is working okay.
    A small example would be appreciated.

    Yep, I spotted the syntax error earlier.
    However even though that seems to compile ok, I still get the problem with my package call.
    heres the actual call from the code
    vt_attrname and vt_attrvalues are types declared on another schema.
    I have redeclared them on the current schema now.
    create or replace type vt_attrname is table of varchar2(50);
    create or replace type vt_attrvalue is table of varchar2(500);
    create procedure <name>
    as
    v_cardapplattrtag   vt_attrname;
    v_cardapplattrvalue vt_attrvalue;
      for cardappl_cur in
        (select cardappl_id 
           from ci_cardappl
          where custcard_id = cur.document_logical_number)
        loop
        select label
          bulk collect
          into v_cardapplattrtag
          from ci_applver_attribute
          where applver_id = v_applver_id;
          v_array_size := v_cardapplattrtag.count;
        -- populate this array
        -- ppt_cardapplattrtag comes from ci_pplver_attribute
        --ppt_cardapplattrvalue -- various
    cci_setcardappl.SetCardApplAttrValue(
              pn_cardappl_id                 =>     cardappl_cur.cardappl_id,
              ppt_cardapplattrtag     =>      v_cardapplattrtag, -- works when null
              ppt_cardapplattrvalue   =>     NULL,
              pn_cardapplattrsize     =>     v_array_size,
              pv_arn                  =>     cur.application_request_id,
              pv_commit               =>    'FALSE');and the procedure protototype is
    PROCEDURE SetCardApplAttrValue(
              pn_cardappl_id           IN     NUMBER,
              ppt_cardapplattrtag     IN     VT_BPATTRNAME DEFAULT NULL,
              ppt_cardapplattrvalue   IN     VT_BPATTRVALUE DEFAULT NULL,
              pn_cardapplattrsize     IN     NUMBER,
              pv_arn                  IN     VARCHAR2,
              pv_commit               IN     VARCHAR2 DEFAULT 'FALSE');Edited by: Keith Jamieson on Sep 23, 2009 10:42 AM

Maybe you are looking for

  • Switching between text SMS messages and iMessage

    When receiving text messages while on a wifi network my message client responds with iMessages.The recipient us not on a wifi network and does not revive the iMessage replies. Why isn't the iPhone smart enough to respond using the protocol that will

  • Text moving when opening a pdf in illustrator

    I opened 2 separate hi res pdfs (the front and back of a postcard) in illustrator 5.1. The type on both sides had been outlined and we just relinked the background image on both sides after we did some color adjustments to it. The only type on the fr

  • EOS character not appended?

    I am attempting to write an application that in part will control an Anritsu MP1570A Sonet Analyzer. This instrument departs from the IEEE standard in that it requires tx or rx messages to be terminated with a carriage return <\n>. In the custom prop

  • SQL Server 2014 Snapshot agent duplicating constraints

    Hello, We are upgrading our server from SQL Server 2008 R2 Std. Ed.  to SQL Server 2014 Std. Ed. Our server works with Merge and Transactional publications. Our current problem happens when trying to generate the first snapshot using the snapshot age

  • Delivery Urgent

    Dear Gurus, By clicking PGI in the delivery screen. I get the error message as "delivery note has not yet put away/picked completely " and "delivery note has not yet completely processed by WM" but before that i went to LT03 to transfer the order to