Checks for any custom cascading saves set up via the mapping DSL and records them within the persistent property.
@param mapping The Mapping.
@param persistentProperties The persistent properties of the domain class.
484514
protected void trackCustomCascadingSaves(Mapping mapping, Iterable<PersistentProperty> persistentProperties) {
        for (PersistentProperty property : persistentProperties) {
            PropertyConfig propConf = mapping.getPropertyConfig(property.getName());

            if (propConf != null && propConf.getCascade() != null) {
                propConf.setExplicitSaveUpdateCascade(isSaveUpdateCascade(propConf.getCascade()));
            }
        }
    }
625942
@Override
     public boolean saveProperties(String servicePid, Dictionary<String, String> properties)
     {
         try {
             if (servicePid != null)
             {
                 ServiceReference caRef = bundleContext.getServiceReference(ConfigurationAdmin.class.getName());
                 if (caRef != null)
                 {
                     ConfigurationAdmin configAdmin = (ConfigurationAdmin)bundleContext.getService(caRef);
                     Configuration config = configAdmin.getConfiguration(servicePid);
    
                     config.update(properties);
                     return true;
                 }
             }
         } catch (IOException e) {
             e.printStackTrace();
         }
         return false;
     }
1351570
public void ensureNavigationProperties(StructuredType entityType) throws ODataException {
        List<String> missingNavigationPropertyNames = new ArrayList<>();

        entityType.getStructuralProperties().stream().filter(property -> (property instanceof NavigationProperty)
                && !property.isNullable()).forEach(property -> {
            LOG.debug("Validating non-nullable NavigationProperty property : {}", property.getName());
            if (!links.containsKey(property.getName())) {
                missingNavigationPropertyNames.add(property.getName());
            }
        });
        if (missingNavigationPropertyNames.size() != 0) {
            StringJoiner joiner = new StringJoiner(",");
            missingNavigationPropertyNames.forEach(joiner::add);
            throw new ODataUnmarshallingException("The request does not specify the navigation links for '"
                    + joiner.toString() + ".");
        }
    }
339509
public void setSubDomainSettings(java.util.Collection<SubDomainSetting> subDomainSettings) {
        if (subDomainSettings == null) {
            this.subDomainSettings = null;
            return;
        }

        this.subDomainSettings = new java.util.ArrayList<SubDomainSetting>(subDomainSettings);
    }
1119488
protected void bindDependentKeyValue(PersistentProperty property, DependantValue key,
                                         InFlightMetadataCollector mappings, String sessionFactoryBeanName) {

        if (LOG.isDebugEnabled()) {
            LOG.debug("[GrailsDomainBinder] binding  [" + property.getName() + "] with dependant key");
        }

        PersistentEntity refDomainClass = property.getOwner();
        final Mapping mapping = getMapping(refDomainClass.getJavaClass());
        boolean hasCompositeIdentifier = hasCompositeIdentifier(mapping);
        if ((shouldCollectionBindWithJoinColumn((ToMany) property) && hasCompositeIdentifier) ||
                (hasCompositeIdentifier && ( property instanceof ManyToMany))) {
            CompositeIdentity ci = (CompositeIdentity) mapping.getIdentity();
            bindCompositeIdentifierToManyToOne((Association) property, key, ci, refDomainClass, EMPTY_PATH, sessionFactoryBeanName);
        }
        else {
            bindSimpleValue(property, null, key, EMPTY_PATH, mappings, sessionFactoryBeanName);
        }
    }
1350380
public static void assignBidirectionalAssociations(Object object, Map source, PersistentEntity persistentEntity) {
        if (source == null) {
            return;
        }

        for (Object key : source.keySet()) {
            String propertyName = key.toString();
            if (propertyName.indexOf('.') > -1) {
                propertyName = propertyName.substring(0, propertyName.indexOf('.'));
            }
            PersistentProperty prop = persistentEntity.getPropertyByName(propertyName);

            if (prop != null && prop instanceof OneToOne && ((OneToOne) prop).isBidirectional()) {
                Object val = source.get(key);
                PersistentProperty otherSide = ((OneToOne) prop).getInverseSide();
                if (val != null && otherSide != null) {
                    MetaClass mc = GroovySystem.getMetaClassRegistry().getMetaClass(val.getClass());
                    try {
                        mc.setProperty(val, otherSide.getName(), object);
                    }
                    catch (Exception e) {
                        // ignore
                    }
                }
            }

        }
    }
704444
public void setTypeMap(Map<String, Class<?>> map) throws SQLException {
        if (!changable) {
            throw new SQLException(AdapterUtil.getNLSMessage("WS_INTERNAL_ERROR", new Object[]
            { "ConnectionRequestInfo cannot be modified, doing so may result in corruption: type map, cri", map, this }));
        }

        if (TraceComponent.isAnyTracingEnabled() && tc.isDebugEnabled())
            Tr.debug(this, tc, "Setting the type map on the CRI to: " + map);

        ivTypeMap = map;
    }
371548
public void setPropertyGroupDescriptions(java.util.Collection<PropertyGroup> propertyGroupDescriptions) {
        if (propertyGroupDescriptions == null) {
            this.propertyGroupDescriptions = null;
            return;
        }

        this.propertyGroupDescriptions = new java.util.ArrayList<PropertyGroup>(propertyGroupDescriptions);
    }
805278
public void setMapperProperties(Properties properties) {
        if (this.mapperHelper == null) {
            this.mapperHelper = new MapperHelper();
        }
        this.mapperHelper.setProperties(properties);
    }
597131
protected boolean isUnidirectionalOneToMany(PersistentProperty property) {
        return ((property instanceof org.grails.datastore.mapping.model.types.OneToMany) && !((Association)property).isBidirectional());
    }
197118
public synchronized void persistProperties(Properties properties, File propsFile, String message) {
    Properties toWrite = new Properties();
    for(String key : properties.stringPropertyNames()) {

      if(System.getProperties().containsKey(key) && !properties.getProperty(key).equals(System.getProperty(key))) {

        toWrite.setProperty(key, properties.getProperty(key));
      } 
      else if(System.getenv().containsKey(key) && !properties.getProperty(key).equals(System.getenv(key))) {

        toWrite.setProperty(key, properties.getProperty(key));
      } 
      else if(!System.getProperties().containsKey(key) && !System.getenv().containsKey(key)){

        toWrite.setProperty(key, properties.getProperty(key));
      }
    }
    writer.persistProperties(toWrite, propsFile, message, log);
  }
1114375
protected void saveProperties(CmsPropertyChangeSet changes, AsyncCallback<Void> callback) {

        if (m_propertySaver != null) {
            m_propertySaver.saveProperties(changes, callback);
        } else {
            CmsCoreProvider.getVfsService().saveProperties(changes, callback);
        }
    }
257194
Collection<MappingImpl> build(PropertyMap<S, D> propertyMap) {
    try {
      PROPERTY_MAP_CONFIGURE.invoke(propertyMap, this);
      saveLastMapping();
    } catch (IllegalAccessException e) {
      errors.errorAccessingConfigure(e);
    } catch (InvocationTargetException e) {
      Throwable cause = e.getCause();
      if (cause instanceof ConfigurationException)
        throw (ConfigurationException) cause;
      else
        errors.addMessage(cause, "Failed to configure mappings");
    } catch (NullPointerException e) {
      if (proxyErrors.hasErrors()) {
        throw proxyErrors.toException();
      }
      throw e;
    }

    errors.throwConfigurationExceptionIfErrorsExist();
    return propertyMappings;
  }
929199
@Override
    public void setNonPersistentMapping(String nonPersistentMapping) throws JMSException {
        if (TraceComponent.isAnyTracingEnabled() && tc.isEntryEnabled())
            SibTr.entry(this, tc, "setNonPersistentMapping", nonPersistentMapping);

        if (nonPersistentMapping == null) {
            throw (JMSException) JmsErrorUtils.newThrowable(
                                                            JMSException.class,
                                                            "INVALID_VALUE_CWSIA0261",
                                                            new Object[] { "nonPersistentMapping", null },
                                                            tc
                            );
        }

        if (nonPersistentMapping.equals(ApiJmsConstants.MAPPING_BEST_EFFORT_NONPERSISTENT) ||
            nonPersistentMapping.equals(ApiJmsConstants.MAPPING_EXPRESS_NONPERSISTENT) ||
            nonPersistentMapping.equals(ApiJmsConstants.MAPPING_RELIABLE_NONPERSISTENT) ||
            nonPersistentMapping.equals(ApiJmsConstants.MAPPING_RELIABLE_PERSISTENT) ||
            nonPersistentMapping.equals(ApiJmsConstants.MAPPING_ASSURED_PERSISTENT) ||
            nonPersistentMapping.equals(ApiJmsConstants.MAPPING_NONE)) {
            jcaManagedConnectionFactory.setNonPersistentMapping(nonPersistentMapping);
        }
        else if (nonPersistentMapping.equals(ApiJmsConstants.MAPPING_AS_SIB_DESTINATION)) {
            jcaManagedConnectionFactory.setNonPersistentMapping(ApiJmsConstants.MAPPING_NONE);
        }
        else {
            throw (JMSException) JmsErrorUtils.newThrowable(
                                                            JMSException.class,
                                                            "INVALID_VALUE_CWSIA0261",
                                                            new Object[] { "nonPersistentMapping", nonPersistentMapping },
                                                            tc
                            );
        }

        if (TraceComponent.isAnyTracingEnabled() && tc.isEntryEnabled())
            SibTr.exit(this, tc, "setNonPersistentMapping");
    }
327892
public static void setCustomProperties(Map<String, Object> d) {
        if (TraceComponent.isAnyTracingEnabled() && tc.isEntryEnabled()) {
            Tr.entry(tc, "setCustomProperties");
        }

        String ky;
        String propertyKey;

        // For comparison purposes we need the mixed case key strings coming from metatype.xml and server.xml to be in lower case.
        Set<String> newKeySet = new HashSet<String>();                                                
        for (String key:d.keySet()) {                                                                 
            newKeySet.add(key.toLowerCase());                                                         
        }                                                                                             

        // go through each entry that is in the set of keys that we are getting from metatype.xml and server.xml
        for (Map.Entry<String, Object> entry : d.entrySet()) {
            ky = entry.getKey();
            Object value = entry.getValue();
        
            // using the lower case value of short or long name that was configured
            // see if the string maps to one of the short names in our table.
            // if it matches then get the long name back.  otherwise keep the name as is.
            propertyKey = getStringKey(ky.toLowerCase());
            
            if (!ky.equalsIgnoreCase(propertyKey)) {
                // found in map - check existence of fully qualified prop as well
                // if we mapped to a new long name, see if it is already in the passed in data because
                // configured long names have priority, and if it is in the table elsewhere, then don't use
                // this mapped short name value, because the long name was set in server.xml
                if (newKeySet.contains(propertyKey)) {                                           
                    continue;
                }
            }
            
            // store all values as lower case, so as to read them later in a consistent fashion
            propertyKey =  propertyKey.toLowerCase();
            
            if (value instanceof String) {
                if (TraceComponent.isAnyTracingEnabled() && tc.isDebugEnabled()) {
                    Tr.debug(tc, "Key: " + propertyKey + "  type: String  value: " + value);
                }
                customProps.setProperty(propertyKey, (String) value);

            } else if (value instanceof Boolean) {
                if (TraceComponent.isAnyTracingEnabled() && tc.isDebugEnabled()) {
                    Tr.debug(tc, "Key: " + propertyKey + "  type: Boolean  value: " + ((Boolean) value).toString());
                }
                customProps.setProperty(propertyKey, ((Boolean) value).toString());

            } else if (value instanceof Integer) {
                if (TraceComponent.isAnyTracingEnabled() && tc.isDebugEnabled()) {
                    Tr.debug(tc, "Key: " + propertyKey + "  type: Integer  value: " + ((Integer) value).toString());
                }
                customProps.setProperty(propertyKey, ((Integer) value).toString());
            } else {
                // don't update, not a custom property we care about here
                if (TraceComponent.isAnyTracingEnabled() && tc.isDebugEnabled()) {
                    Tr.debug(tc, "Key not processed due to type, Key: " + propertyKey);
                }
            }
        }

        setCustomPropertyVariables(); //Need to update all the variables.

        setCustomizedDefaultValues(); //Customize default value depending on servlet level, initial size....etc..

        if (TraceComponent.isAnyTracingEnabled() && tc.isEntryEnabled()) {
            Tr.exit(tc, "setCustomProperties");
        }

    }
740619
private void persistCaches() {
		for (Entry<CacheKey, Map<String, String>> cacheEntry : caches.entrySet()) {
			persistCache(cacheEntry.getKey().projectName, cacheEntry.getKey().projectVersion, cacheEntry.getValue());
		}
	}
352417
public void putProperties(Map<String, String> properties) {
		for (Map.Entry<String, String> property : properties.entrySet()) {
			put(property.getKey(), property.getValue());
		}
	}