You are an expert in writing code in many different languages. Your goal is to perform code completion for the following code, keeping in mind the rest of the code and the file meta data.
    Metadata details:
    filename: sync_parameters_to_physics.rs
    path of file: ./repos/specs-physics/src/systems
    
    the code of the file until where you have to start completion: use std::marker::PhantomData;

use specs::{Read, System, SystemData, World, WriteExpect};

use crate::{
    nalgebra::RealField,
    parameters::{Gravity, PhysicsIntegrationParameters, PhysicsProfilingEnabled},
    Physics,
};

/// The `SyncParametersToPhysicsSystem` synchronises the simulation parameters
/// with the nphysics `World`.
pub struct SyncParametersToPhysicsSystem<N> {
    n_marker: PhantomData<N>,
}

impl<'s, N: RealField> System<'s> for SyncParametersToPhysicsSystem<N> {
    type SystemData = (
        Option<Read<'s, Gravity<N>>>,
        Option<Read<'s, PhysicsProfilingEnabled>>,
        Option<Read<'s, PhysicsIntegrationParameters<N>>>,
        WriteExpect<'s, Physics<N>>,
    );

    fn run(&mut self, data: Self::SystemData) {
        let (gravity, profiling, integration_params, mut physics) = data;

        // if a Gravity resource exists, synchronise 
    
    fn run(&mut self, data: Self::SystemData) {
        let (gravity, profiling, integration_params, mut physics) = data;

        // if a Gravity resource exists, synchronise its values with the nphysics World
        if let Some(gravity) = gravity {
            if gravity.0 != *physics.gravity() {
                info!(
                    "Global physics gravity modified from {}, updating to {}.",
                    physics.gravity(),
                    gravity.0
                );
                physics.mechanical_world.gravity = gravity.0;
            }
        }

        if let Some(enable_profiling) = profiling {
            if enable_profiling.0 != physics.performance_counters().enabled() {
                if enable_profiling.0 {
                    info!("Physics performance counters enabled.");
                    physics.mechanical_world.counters.enable();
                } else {
                    info!("Physics performance counters disabled.");
                    physics.mechanical_world.counters.disable();
                }
            }
        }

        if let Some(params) = integration_params {
            if *params != *physics.integration_parameters() {
                params.apply(&mut physics.mechanical_world.integration_parameters);
                info!("Integration parameters have been updated.");
            }
        }
    }