2 * Copyright (c) 2016 Samsung Electronics Co., Ltd All Rights Reserved
4 * Licensed under the Apache License, Version 2.0 (the License);
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
8 * http://www.apache.org/licenses/LICENSE-2.0
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an AS IS BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
22 /// Place Filter information, used in Place Discovery and Search requests
24 public class PlaceFilter : IDisposable
26 internal Interop.PlaceFilterHandle handle;
29 /// Constructs new place filter.
31 /// <exception cref="System.InvalidOperationException">Thrown when native operation failed to allocate memory.</exception>
34 handle = new Interop.PlaceFilterHandle();
38 /// Gets or sets an free-formed address string for this place filter.
40 /// <remarks>Depending on maps provider which the application has selected,
41 /// it may treat <see cref="PlaceFilter.Name"/>, <see cref="PlaceFilter.Keyword"/> and <see cref="PlaceFilter.Address"/>
42 /// as same kind of strings to search places.</remarks>
47 return handle.PlaceAddress;
51 handle.PlaceAddress = value;
56 /// Gets or sets an instance of <see cref="PlaceCategory"/> object for this place filter.
58 public PlaceCategory Category
62 return new PlaceCategory(handle.Category);
66 handle.Category = value.handle;
71 /// Gets or sets a keyword for this place filter.
73 /// <remarks>Depending on maps provider which the application has selected,
74 /// it may treat <see cref="PlaceFilter.Name"/>, <see cref="PlaceFilter.Keyword"/> and <see cref="PlaceFilter.Address"/>
75 /// as same kind of strings to search places.</remarks>
80 return handle.Keyword;
84 handle.Keyword = value;
89 /// Gets or sets a name for this place filter.
91 /// <remarks>Depending on maps provider which the application has selected,
92 /// it may treat <see cref="PlaceFilter.Name"/>, <see cref="PlaceFilter.Keyword"/> and <see cref="PlaceFilter.Address"/>
93 /// as same kind of strings to search places.</remarks>
98 return handle.PlaceName;
102 handle.PlaceName = value;
106 #region IDisposable Support
107 private bool _disposedValue = false;
109 protected virtual void Dispose(bool disposing)
114 _disposedValue = true;
119 /// Releases all resources used by this object.
121 public void Dispose()
124 GC.SuppressFinalize(this);