]> https://gitweb.dealii.org/ - dealii.git/commitdiff
Add documentation
authorRene Gassmoeller <rene.gassmoeller@mailbox.org>
Fri, 9 Aug 2019 20:24:19 +0000 (14:24 -0600)
committerRene Gassmoeller <rene.gassmoeller@mailbox.org>
Sat, 10 Aug 2019 18:22:24 +0000 (12:22 -0600)
include/deal.II/particles/particle_handler.h

index 75797dd875e34843b93c5103c807fe34450d5245..d7e300d32518fd9486e045790f1bdde4a9625237 100644 (file)
@@ -40,10 +40,26 @@ namespace Particles
 {
   namespace internal
   {
+    /**
+     * This function packs a vector of particles into a vector
+     * of bytes. If there are properties associated with the
+     * particles they are also serialized. The function does
+     * not perform compression, but is faster
+     * than the corresponding function Utilities::pack().
+     */
     template <int dim, int spacedim>
     std::vector<char>
     pack_particles(std::vector<Particle<dim, spacedim>> &particles);
 
+    /**
+     * This function unpacks a vector of bytes into a vector
+     * of particles. It assumes the vector of bytes was created
+     * with the pack_particles() function above. If the particles
+     * had properties when they were serialized this function
+     * requires an additional argument that is a PropertyPool
+     * object with the correct number of properties per particle
+     * to be able to correctly unpack the particles.
+     */
     template <int dim, int spacedim>
     std::vector<Particle<dim, spacedim>>
     unpack_particles(

In the beginning the Universe was created. This has made a lot of people very angry and has been widely regarded as a bad move.

Douglas Adams


Typeset in Trocchi and Trocchi Bold Sans Serif.