// +build !ignore_autogenerated

/*
Copyright 2019 The Jetstack cert-manager contributors.

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.
*/

// Code generated by conversion-gen. DO NOT EDIT.

package v1

import (
	v1 "github.com/jetstack/cert-manager/pkg/apis/meta/v1"
	meta "github.com/jetstack/cert-manager/pkg/internal/apis/meta"
	conversion "k8s.io/apimachinery/pkg/conversion"
	runtime "k8s.io/apimachinery/pkg/runtime"
)

func init() {
	localSchemeBuilder.Register(RegisterConversions)
}

// RegisterConversions adds conversion functions to the given scheme.
// Public to allow building arbitrary schemes.
func RegisterConversions(s *runtime.Scheme) error {
	if err := s.AddGeneratedConversionFunc((*v1.LocalObjectReference)(nil), (*meta.LocalObjectReference)(nil), func(a, b interface{}, scope conversion.Scope) error {
		return Convert_v1_LocalObjectReference_To_meta_LocalObjectReference(a.(*v1.LocalObjectReference), b.(*meta.LocalObjectReference), scope)
	}); err != nil {
		return err
	}
	if err := s.AddGeneratedConversionFunc((*meta.LocalObjectReference)(nil), (*v1.LocalObjectReference)(nil), func(a, b interface{}, scope conversion.Scope) error {
		return Convert_meta_LocalObjectReference_To_v1_LocalObjectReference(a.(*meta.LocalObjectReference), b.(*v1.LocalObjectReference), scope)
	}); err != nil {
		return err
	}
	if err := s.AddGeneratedConversionFunc((*v1.ObjectReference)(nil), (*meta.ObjectReference)(nil), func(a, b interface{}, scope conversion.Scope) error {
		return Convert_v1_ObjectReference_To_meta_ObjectReference(a.(*v1.ObjectReference), b.(*meta.ObjectReference), scope)
	}); err != nil {
		return err
	}
	if err := s.AddGeneratedConversionFunc((*meta.ObjectReference)(nil), (*v1.ObjectReference)(nil), func(a, b interface{}, scope conversion.Scope) error {
		return Convert_meta_ObjectReference_To_v1_ObjectReference(a.(*meta.ObjectReference), b.(*v1.ObjectReference), scope)
	}); err != nil {
		return err
	}
	if err := s.AddGeneratedConversionFunc((*v1.SecretKeySelector)(nil), (*meta.SecretKeySelector)(nil), func(a, b interface{}, scope conversion.Scope) error {
		return Convert_v1_SecretKeySelector_To_meta_SecretKeySelector(a.(*v1.SecretKeySelector), b.(*meta.SecretKeySelector), scope)
	}); err != nil {
		return err
	}
	if err := s.AddGeneratedConversionFunc((*meta.SecretKeySelector)(nil), (*v1.SecretKeySelector)(nil), func(a, b interface{}, scope conversion.Scope) error {
		return Convert_meta_SecretKeySelector_To_v1_SecretKeySelector(a.(*meta.SecretKeySelector), b.(*v1.SecretKeySelector), scope)
	}); err != nil {
		return err
	}
	return nil
}

func autoConvert_v1_LocalObjectReference_To_meta_LocalObjectReference(in *v1.LocalObjectReference, out *meta.LocalObjectReference, s conversion.Scope) error {
	out.Name = in.Name
	return nil
}

// Convert_v1_LocalObjectReference_To_meta_LocalObjectReference is an autogenerated conversion function.
func Convert_v1_LocalObjectReference_To_meta_LocalObjectReference(in *v1.LocalObjectReference, out *meta.LocalObjectReference, s conversion.Scope) error {
	return autoConvert_v1_LocalObjectReference_To_meta_LocalObjectReference(in, out, s)
}

func autoConvert_meta_LocalObjectReference_To_v1_LocalObjectReference(in *meta.LocalObjectReference, out *v1.LocalObjectReference, s conversion.Scope) error {
	out.Name = in.Name
	return nil
}

// Convert_meta_LocalObjectReference_To_v1_LocalObjectReference is an autogenerated conversion function.
func Convert_meta_LocalObjectReference_To_v1_LocalObjectReference(in *meta.LocalObjectReference, out *v1.LocalObjectReference, s conversion.Scope) error {
	return autoConvert_meta_LocalObjectReference_To_v1_LocalObjectReference(in, out, s)
}

func autoConvert_v1_ObjectReference_To_meta_ObjectReference(in *v1.ObjectReference, out *meta.ObjectReference, s conversion.Scope) error {
	out.Name = in.Name
	out.Kind = in.Kind
	out.Group = in.Group
	return nil
}

// Convert_v1_ObjectReference_To_meta_ObjectReference is an autogenerated conversion function.
func Convert_v1_ObjectReference_To_meta_ObjectReference(in *v1.ObjectReference, out *meta.ObjectReference, s conversion.Scope) error {
	return autoConvert_v1_ObjectReference_To_meta_ObjectReference(in, out, s)
}

func autoConvert_meta_ObjectReference_To_v1_ObjectReference(in *meta.ObjectReference, out *v1.ObjectReference, s conversion.Scope) error {
	out.Name = in.Name
	out.Kind = in.Kind
	out.Group = in.Group
	return nil
}

// Convert_meta_ObjectReference_To_v1_ObjectReference is an autogenerated conversion function.
func Convert_meta_ObjectReference_To_v1_ObjectReference(in *meta.ObjectReference, out *v1.ObjectReference, s conversion.Scope) error {
	return autoConvert_meta_ObjectReference_To_v1_ObjectReference(in, out, s)
}

func autoConvert_v1_SecretKeySelector_To_meta_SecretKeySelector(in *v1.SecretKeySelector, out *meta.SecretKeySelector, s conversion.Scope) error {
	if err := Convert_v1_LocalObjectReference_To_meta_LocalObjectReference(&in.LocalObjectReference, &out.LocalObjectReference, s); err != nil {
		return err
	}
	out.Key = in.Key
	return nil
}

// Convert_v1_SecretKeySelector_To_meta_SecretKeySelector is an autogenerated conversion function.
func Convert_v1_SecretKeySelector_To_meta_SecretKeySelector(in *v1.SecretKeySelector, out *meta.SecretKeySelector, s conversion.Scope) error {
	return autoConvert_v1_SecretKeySelector_To_meta_SecretKeySelector(in, out, s)
}

func autoConvert_meta_SecretKeySelector_To_v1_SecretKeySelector(in *meta.SecretKeySelector, out *v1.SecretKeySelector, s conversion.Scope) error {
	if err := Convert_meta_LocalObjectReference_To_v1_LocalObjectReference(&in.LocalObjectReference, &out.LocalObjectReference, s); err != nil {
		return err
	}
	out.Key = in.Key
	return nil
}

// Convert_meta_SecretKeySelector_To_v1_SecretKeySelector is an autogenerated conversion function.
func Convert_meta_SecretKeySelector_To_v1_SecretKeySelector(in *meta.SecretKeySelector, out *v1.SecretKeySelector, s conversion.Scope) error {
	return autoConvert_meta_SecretKeySelector_To_v1_SecretKeySelector(in, out, s)
}
