1 PACKAGE hz_geocode_pkg AUTHID CURRENT_USER AS
2 /*$Header: ARHGEOCS.pls 120.5 2010/12/14 12:34:50 rgokavar ship $*/
3
4 g_max_rows NUMBER := 20;
5
6 --TYPE loc_array IS VARRAY(20) OF hz_location_v2pub.location_rec_type;
7 TYPE loc_array IS VARRAY(20) OF HZ_ELOCATION_PKG.geo_location_rec_type;
8 TYPE array_t IS TABLE OF VARCHAR2(8000) INDEX BY BINARY_INTEGER;
9
10 --------------------------------------------
11 -- declaration of global variables and types
12 --------------------------------------------
13 g_pkg_name CONSTANT VARCHAR2(30) := 'HZ_GEOCODE_PKG';
14 g_debug_count NUMBER := 0;
15 g_debug BOOLEAN := FALSE;
16 g_good CONSTANT VARCHAR2(30) := 'GOOD';
17 g_dirty CONSTANT VARCHAR2(30) := 'DIRTY';
18 g_error CONSTANT VARCHAR2(30) := 'ERROR';
19 g_multimatch CONSTANT VARCHAR2(30) := 'MULTIMATCH';
20 g_noexactmatch CONSTANT VARCHAR2(30) := 'NOEXACTMATCH';
21 g_processing CONSTANT VARCHAR2(30) := 'PROCESSING';
22
23 -------------------------------------------------------
24 -- RETURN Y if nls_numeric_character = '.,' US standard
25 -- N otherwise
26 -------------------------------------------------------
27 FUNCTION is_nls_num_char_pt_com RETURN VARCHAR2;
28
29 --
30 -- PUBLIC FUNCTION
31 -- remove_whitespace
32 --
33 -- DESCRIPTION
34 -- Remove whitespace from a string
35 --
36 -- EXTERNAL PROCEDURES/FUNCTIONS ACCESSED
37 --
38 -- MODIFICATION HISTORY
39 --
40 -- 02-28-2002 Joe del Callar Created.
41 --
42 FUNCTION remove_whitespace (p_str IN VARCHAR2) RETURN VARCHAR2;
43
44 --
45 -- PUBLIC FUNCTION
46 -- in_bypass_list
47 --
48 -- DESCRIPTION
49 -- Returns 'Y' if the argument p_url_target is in p_exclusion_list, 'N'
50 -- otherwise. Used to determine whether or not to use a proxy. This
51 -- functionality can only be used with fixed-length character set
52 -- exclusion lists and targets, which is okay since these are URLs.
53 --
54 -- EXTERNAL PROCEDURES/FUNCTIONS ACCESSED
55 --
56 -- ARGUMENTS
57 -- IN:
58 -- p_target_url
59 -- p_exclusion_list
60 --
61 -- NOTES
62 --
63 -- MODIFICATION HISTORY
64 --
65 -- 03-27-2002 J. del Callar Created.
66 --
67 FUNCTION in_bypass_list (
68 p_url_target IN VARCHAR2,
69 p_exclusion_list IN VARCHAR2
70 ) RETURN BOOLEAN;
71
72 --
73 -- PUBLIC PROCEDURE
74 -- get_spatial_coords
75 --
76 -- DESCRIPTION
77 -- Build the xml request for n locations
78 -- Post the Xml request
79 -- Split the Response into individual responses
80 -- Parse and update hz_locations with the responses
81 -- If error Then x_return_status = E
82 --
83 -- EXTERNAL PROCEDURES/FUNCTIONS ACCESSED
84 --
85 -- ARGUMENTS
86 -- IN:
87 -- p_name
88 -- p_http_ad
89 -- p_proxy
90 -- p_port
91 -- p_retry
92 -- p_init_msg_list
93 -- IN/OUT:
94 -- p_loc_array
95 -- OUT:
96 -- x_return_status Return status after the call. The status can
97 -- be FND_API.G_RET_STS_SUCCESS (success),
98 -- FND_API.G_RET_STS_ERROR (error),
99 -- FND_API.G_RET_STS_UNEXP_ERROR (unexpected error).
100 -- x_msg_count Number of messages in message stack.
101 -- x_msg_data Message text if x_msg_count is 1.
102 --
103 -- NOTES
104 --
105 -- MODIFICATION HISTORY
106 --
107 -- 01-09-2002 Herve Yu Created.
108 -- 01-28-2002 Joe del Callar Modified to return the geometry in the
109 -- loc_array structure in order to facilitate
110 -- integration with HR.
111 --
112
113 PROCEDURE get_spatial_coords (
114 p_loc_array IN OUT NOCOPY loc_array,
115 p_name IN VARCHAR2 DEFAULT NULL,
116 p_http_ad IN VARCHAR2,
117 p_proxy IN VARCHAR2 DEFAULT NULL,
118 p_port IN NUMBER DEFAULT NULL,
119 p_retry IN NUMBER DEFAULT 3,
120 p_init_msg_list IN VARCHAR2 DEFAULT fnd_api.g_false,
121 x_return_status OUT NOCOPY VARCHAR2,
122 x_msg_count OUT NOCOPY NUMBER,
123 x_msg_data OUT NOCOPY VARCHAR2
124 );
125
126 END hz_geocode_pkg;