@alfresco/adf-core
Version:
34 lines (33 loc) • 1.89 kB
TypeScript
/*!
* @license
* Copyright © 2005-2025 Hyland Software, Inc. and its affiliates. All rights reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
import { HttpEvent, HttpUploadProgressEvent, HttpResponse, HttpParams, HttpParameterCodec } from '@angular/common/http';
import { Constructor } from '../types';
export declare const isHttpUploadProgressEvent: <T>(val: HttpEvent<T>) => val is HttpUploadProgressEvent;
export declare const isHttpResponseEvent: <T>(val: HttpEvent<T>) => val is HttpResponse<T>;
export declare const isDate: (value: unknown) => value is Date;
export declare const isXML: (value: unknown) => boolean;
export declare const isBlobResponse: (response: HttpResponse<any>, returnType: Constructor<unknown> | "blob") => response is HttpResponse<Blob>;
export declare const isConstructor: <T = unknown>(value: any) => value is Constructor<T>;
export declare const getQueryParamsWithCustomEncoder: (obj: Record<string | number, unknown>, encoder?: HttpParameterCodec) => HttpParams | undefined;
/**
* Removes null and undefined values from an object.
*
* @param obj object to process
* @returns object with updated values
*/
export declare const removeNilValues: (obj: Record<string | number, unknown>) => {};
export declare const convertObjectToFormData: (formParams: Record<string | number, string | Blob | Array<string | Blob>>) => FormData;