<commit_before>﻿using System.Collections.Generic;
using System.Diagnostics.CodeAnalysis;
using Microsoft.Office.Server.Search.Administration;

namespace GSoft.Dynamite.Search
{
    /// <summary>
    /// Definition for a managed property
    /// </summary>
    public class ManagedPropertyInfo
    {
        /// <summary>
        /// Default constructor for serialization purposes
        /// </summary>
        public ManagedPropertyInfo()
        {
        }

        /// <summary>
        /// Initializes a new ManagedPropertyInfo
        /// </summary>
        /// <param name="name">The name of the managed property</param>
        /// <param name="type">The type of the managed property</param>
        public ManagedPropertyInfo(string name, ManagedDataType type) : this(name)
        {
            this.DataType = type;
        }

        /// <summary>
        /// Default constructor
        /// </summary>
        /// <param name="name">Name of the managed property</param>
        public ManagedPropertyInfo(string name)
        {
            this.Name = name;
            this.CrawledProperties = new Dictionary<string, int>();

            // Default configuration
            this.Sortable = false;
            this.Queryable = true;
            this.Searchable = true;
            this.Refinable = true;
            this.RespectPriority = false;
            this.HasMultipleValues = false;
            this.FullTextIndex = "Default";
            this.SafeForAnonymous = true;
            this.Context = 2;
            this.OverwriteIfAlreadyExists = true;
        }

        /// <summary>
        /// Name of the managed property<commit_msg>[Search] Make managed properties Retrievale=TRUE by default.<commit_after>﻿using System.Collections.Generic;
using System.Diagnostics.CodeAnalysis;
using Microsoft.Office.Server.Search.Administration;

namespace GSoft.Dynamite.Search
{
    /// <summary>
    /// Definition for a managed property
    /// </summary>
    public class ManagedPropertyInfo
    {
        /// <summary>
        /// Default constructor for serialization purposes
        /// </summary>
        public ManagedPropertyInfo()
        {
        }

        /// <summary>
        /// Initializes a new ManagedPropertyInfo
        /// </summary>
        /// <param name="name">The name of the managed property</param>
        /// <param name="type">The type of the managed property</param>
        public ManagedPropertyInfo(string name, ManagedDataType type) : this(name)
        {
            this.DataType = type;
        }

        /// <summary>
        /// Default constructor
        /// </summary>
        /// <param name="name">Name of the managed property</param>
        public ManagedPropertyInfo(string name)
        {
            this.Name = name;
            this.CrawledProperties = new Dictionary<string, int>();

            // Default configuration
            this.Sortable = false;
            this.Queryable = true;
            this.Searchable = true;
            this.Refinable = true;
            this.Retrievable = true;
            this.RespectPriority = false;
            this.HasMultipleValues = false;
            this.FullTextIndex = "Default";
            this.SafeForAnonymous = true;
            this.Context = 2;
            this.OverwriteIfAlreadyExists = true;
        }

        /// <summary>
        /// Name of the managed property
{'fraction_non_alphanumeric': 0.10813199764289923, 'fraction_numerical': 0.0005892751915144372, 'mean_word_length': 1.769168026101142, 'pattern_counts': {'":': 0, '<': 35, '<?xml version=': 0, '>': 35, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '7385818', 'n_tokens_mistral': 847, 'n_tokens_neox': 833, 'n_words': 211}